Commit graph

158 commits

Author SHA1 Message Date
silverpill 01f56d9ef7 Use re-exported tokio_postgres::GenericClient trait 2023-01-18 01:01:45 +00:00
silverpill 0e68ea263c Increase max emoji size to 250 kB 2023-01-17 20:47:34 +00:00
silverpill fcb6554ebb Don't download HTML pages attached by GNU Social 2023-01-17 19:16:46 +00:00
silverpill 56e75895bd Download custom emojis contained in remote posts 2023-01-17 16:47:09 +00:00
silverpill 7b8a56dd8f Support "Public" audience identifier 2023-01-17 00:51:35 +00:00
silverpill 5064afd766 Change max actor image size to 5 MB 2023-01-16 20:34:24 +00:00
silverpill 4d29c83365 Validate emoji tags 2023-01-15 02:14:02 +00:00
silverpill 143879caf9 Ignore deserialization errors when parsing object tags 2023-01-15 02:07:52 +00:00
silverpill 41fdb8abb0 Rename activitypub::activity module to activitypub::types 2023-01-14 23:31:38 +00:00
silverpill 53138ea1c7 Don't fetch HTML pages attached by GNU Social 2023-01-14 19:38:28 +00:00
silverpill 7c07cd79bc Use "mediaType" property value to determine file extension when saving downloaded media 2023-01-14 02:10:06 +00:00
silverpill 85dbb6f392 Save downloaded media as "unknown" if its media type is not supported 2023-01-14 02:08:28 +00:00
silverpill 51cb72d142 Add test for get_note_author_id 2023-01-13 01:31:45 +00:00
silverpill cbc78f9532 Support "as:Public" audience identifier 2023-01-13 01:31:45 +00:00
silverpill 7218864563 Don't stop activity processing on invalid local mentions 2023-01-11 21:55:40 +00:00
silverpill 2385601e12 Create get_or_import_profile_by_actor_address helper function 2023-01-11 21:55:35 +00:00
silverpill fe395480eb Set limit on number of media files that can be attached to post 2023-01-06 16:55:38 +00:00
silverpill 5c9aa0f148 Always put outgoing activities in a queue 2023-01-04 19:36:57 +00:00
silverpill 30857868a0 Write tag value to log if tag type is Emoji 2023-01-04 17:40:17 +00:00
silverpill bf92cebe5c Write activity ID to log if repost already exists in database 2022-12-21 19:21:21 +00:00
silverpill a14c719d25 Ignore Announce(Dislike) activities 2022-12-14 16:34:30 +00:00
silverpill fcab5b000a Ignore Announce() activity if repost already exists but with a different object ID 2022-12-13 19:42:57 +00:00
silverpill 1b588a86e0 Handle non-nested Undo(Follow) activities 2022-12-13 01:12:42 +00:00
silverpill f2037c9516 Save activity ID when processing remote follow request 2022-12-13 00:54:38 +00:00
silverpill 50b8ad9de4 Create type for deserializing Undo() activities and remove Activity type 2022-12-12 21:15:08 +00:00
silverpill bb033e11df Create type for deserializing Delete() activities 2022-12-12 21:04:18 +00:00
silverpill 73e0b10a10 Create types for deserializing Add() and Remove() activities 2022-12-12 20:58:23 +00:00
silverpill f50609e4e5 Create type for deserializing Update(Person) activities 2022-12-12 20:58:23 +00:00
silverpill 72eabce15b Create types for deserializing Follow(), Accept() and Reject() activities 2022-12-12 20:58:20 +00:00
silverpill 7498fc9dba Move create_remote_profile() and update_remote_profile() to actors::helpers module 2022-12-11 14:57:57 +00:00
silverpill 5307a28111 Create type for deserializing Like() activities 2022-12-10 20:51:21 +00:00
silverpill 212db48d75 Add find_aliases() helper function 2022-12-10 20:51:16 +00:00
silverpill 64dbd8ff26 Accept attachments with type Video
Video attachments are used in PixelFed.
2022-12-10 19:01:11 +00:00
silverpill f21f72b96e Create type for deserializing Move() activities 2022-12-10 19:01:04 +00:00
silverpill b7a1803715 Create type for deserializing Announce() activities 2022-12-09 23:07:19 +00:00
silverpill 04ee3e5106 Move activity parsing to handlers 2022-12-09 21:16:53 +00:00
silverpill e247941695 Reorganize handlers and remove unneeded modules 2022-12-09 20:22:48 +00:00
silverpill e6be1cde2d Refactor handle_undo_follow() function 2022-12-08 22:58:48 +00:00
silverpill 84c93fecf1 Refactor receive_activity() function 2022-12-08 22:11:15 +00:00
silverpill d3db42ec9e Rename modules 2022-12-07 21:00:54 +00:00
silverpill e0053f19c7 Add handler function for Create() activity 2022-12-07 19:46:49 +00:00
silverpill 67313dbac7 Create unified handler for Undo() activities 2022-12-06 23:53:30 +00:00
silverpill 648a217971 Create unified handler for Update() activities 2022-12-06 23:48:24 +00:00
silverpill e5c1be2f93 Transform incoming events into posts
Support for Event objects from Rebased.
2022-12-06 19:54:44 +00:00
silverpill d1939b10d5 Move DatabaseError to database module 2022-12-03 22:57:09 +00:00
silverpill 7d204ab150 Remove unknown classes during HTML sanitization 2022-11-29 16:46:00 +00:00
silverpill a3ec1e7b58 Verify that actor alias exists before moving local followers 2022-11-27 22:04:53 +00:00
silverpill ff7c6724a0 Accept Move() activities where object is local actor 2022-11-27 19:54:07 +00:00
silverpill df8c206cf0 Accept Move() activities coming from "target" actor 2022-11-27 19:53:57 +00:00
silverpill 73ef78f021 Search for aliases by DID when processing Move(Person) activity 2022-11-27 13:47:52 +00:00
silverpill 262b910638 Rename instance.host() to instance.hostname() 2022-11-24 13:27:10 +00:00
silverpill 1edcefee6d Accept Create() activities with object type Article and Video 2022-11-21 23:24:40 +00:00
silverpill 3b470a04f7 Allow alsoKnownAs attribute value to be string 2022-11-17 22:49:31 +00:00
silverpill 09cb15297a Ignore Announce(Undo) activities 2022-11-14 18:56:42 +00:00
silverpill a67a7b9b17 Remove character limit check 2022-10-25 19:49:48 +00:00
silverpill 256e225742 Rename ImportError to HandlerError 2022-10-23 23:51:51 +00:00
silverpill 0063a14264 Send notifications when actor moves to another instance 2022-10-23 17:56:32 +00:00
silverpill 9b31395853 Handle Move(Person) activity
https://codeberg.org/silverpill/mitra/issues/10
2022-10-23 17:56:23 +00:00
silverpill 65661698c7 Pass instance as ref to activity builders 2022-10-22 11:33:23 +00:00
silverpill f92428e509 Add support for SOCKS proxy 2022-10-19 20:29:24 +00:00
silverpill 36730be03b Replace actor image fetchers with a single function 2022-10-19 19:47:06 +00:00
silverpill 22d4695614 Add get_post_by_object_id helper 2022-10-15 14:20:45 +00:00
silverpill a74736d29f Ignore Update(Note) if it tries to update local post 2022-10-15 14:13:12 +00:00
silverpill 0ce634564b Rename some functions 2022-10-15 13:08:50 +00:00
silverpill 03ebf75da2 Wrap markdown in remote object content in <p> tag 2022-10-13 16:52:06 +00:00
silverpill 0a62fdac2b Remove target="_blank" and add rel="noopener" during HTML cleaning 2022-10-09 13:06:57 +00:00
silverpill 448b5afa88 Add line break before inline-quote block 2022-10-06 22:50:34 +00:00
silverpill c7499cb0dc Fix creation date in reposts 2022-10-04 23:29:29 +00:00
silverpill 429f530a71 Refactor ActorAddress type 2022-10-03 21:21:20 +00:00
silverpill a685829472 Implement FEP-e232 and allow to add quotes to posts 2022-10-02 21:23:16 +00:00
silverpill f9465693a3 Allow remote posts without content 2022-09-29 15:37:26 +00:00
silverpill b53a1298a2 Limit number of attachments in remote posts 2022-09-27 23:40:24 +00:00
silverpill c488d5b5d4 Log attachment fetching errors 2022-09-19 18:39:56 +00:00
silverpill 4bc4a5c2f8 Ignore Announce(Update) activities 2022-09-17 17:29:31 +00:00
silverpill 24303f00d0 Allow tag property value to be an object 2022-09-17 16:35:23 +00:00
silverpill 6a5bf06d74 Ignore Announce(Like) activities 2022-09-15 21:40:24 +00:00
silverpill 7600efccb5 Add subscribers_count field to Account object 2022-09-13 19:15:58 +00:00
silverpill 5e8a95c646 Ignore Announce(Create) activities 2022-09-13 13:38:02 +00:00
silverpill 9aafe0eaf4 Ignore Accept(Follow) if follow request is already accepted 2022-09-12 23:39:08 +00:00
silverpill f4d1e756d4 Fetch object referenced by quoteUrl property and create a link between posts 2022-08-21 23:45:49 +00:00
silverpill d9def75b32 Create post_link table to store links between posts 2022-08-21 22:36:31 +00:00
silverpill fcf7db97cb Rename posts::tags module to posts::hashtags 2022-08-21 21:35:12 +00:00
silverpill 272ee9997b Don't return error after receiving Add() or Remove() with "featured" collection as target 2022-08-04 12:34:30 +00:00
silverpill ecc4afe568 Append object URL to post content if object type is not Note 2022-07-28 22:04:14 +00:00
silverpill 33a711b91c Attach subscription page link to actor object 2022-07-25 21:39:06 +00:00
silverpill e573ecb27b Add payment_options field to actor profile 2022-07-25 17:44:36 +00:00
silverpill a00b704cf4 Rename actor module to actors::types 2022-07-23 21:41:49 +00:00
silverpill 5b0cfe1f6b Ignore errors when fetching avatar or banner of remote actor 2022-07-22 23:02:46 +00:00
silverpill 672ff5f0ac Handle incoming Add(Person) and Remove(Person) activities 2022-07-17 02:01:11 +00:00
silverpill dcb5736d74 Use tokio::spawn instead of actix_rt::spawn 2022-07-17 00:03:43 +00:00
silverpill 9a38fb25bf Move AP ID parsers to activitypub::identifiers module 2022-07-16 14:10:56 +00:00
silverpill d2ba86315c Move AP ID helpers to activitypub::identifiers module 2022-07-16 01:49:48 +00:00
silverpill b89bd7e570 Move Accept(Follow) builder function to builders::accept_follow module 2022-07-14 08:14:24 +00:00
silverpill c78af51398 Increase max size of profile field name 2022-07-12 19:03:44 +00:00
silverpill cedc6667bd Try to find profile by acct if couldn't find it by actor ID
This should prevent violation of unique constraint on "acct" column
when importing profile by actor ID.
2022-07-10 21:26:44 +00:00
silverpill 48331382c3 Remove duplicate tags when processing remote posts 2022-07-10 20:58:28 +00:00
silverpill 803e73b4da Improve logging of mention parsing errors 2022-07-10 13:05:37 +00:00
silverpill 145622e805 Move fetch_profile_by_actor_id to fetcher::helpers module 2022-07-10 13:05:30 +00:00
silverpill 5d3e5dc693 Re-fetch remote profiles automatically 2022-07-09 21:25:11 +00:00
silverpill ab2aa5f197 Detect incoming subscriber-only posts 2022-06-14 23:49:20 +00:00