Commit graph

1836 commits

Author SHA1 Message Date
lain
f2f0a0260f ActivityPub: Don't block-filter your own posts
We are filtering out replies to people you block, but that should
not include your own posts.
2020-09-21 16:08:38 +02:00
6c052bd5b6 Merge branch 'media-preview-proxy-nostream' into 'develop'
Media preview proxy

See merge request pleroma/pleroma!3001
2020-09-18 18:38:20 +00:00
Steven Fuchs
f2ef9735c5 Federate data through persistent websocket connections 2020-09-18 11:58:22 +00:00
Ivan Tashkinov
a428800405 Merge remote-tracking branch 'remotes/origin/develop' into media-preview-proxy-nostream
# Conflicts:
#	CHANGELOG.md
2020-09-17 22:22:59 +03:00
Haelwenn (lanodan) Monnier
abf25e5d52 Create MRF.filter_pipeline to inject :object_data when present 2020-09-17 22:07:54 +03:00
Haelwenn (lanodan) Monnier
3a0f99ed35 KeywordPolicy: Still match when fields are absent 2020-09-17 22:07:54 +03:00
Ivan Tashkinov
d9fb5bc08a Merge remote-tracking branch 'remotes/origin/develop' into media-preview-proxy-nostream 2020-09-17 17:14:20 +03:00
rinpatch
eca8d26784 Merge branch 'chores/mrf-loglevel' into 'develop'
Fetcher: Correctly return MRF reject reason

See merge request pleroma/pleroma!2990
2020-09-16 13:37:04 +00:00
rinpatch
adbd0032fa Merge branch 'features/validators-video' into 'develop'
Pipeline Ingestion: Video and Article

See merge request pleroma/pleroma!2908
2020-09-16 13:36:27 +00:00
Ivan Tashkinov
2f155fb89f Merge remote-tracking branch 'remotes/origin/develop' into media-preview-proxy-nostream 2020-09-15 20:29:39 +03:00
eugenijm
3ab59a6f3c Mastodon API: fix the public timeline returning an error when the reply_visibility parameter is set to self for an unauthenticated user 2020-09-15 13:00:56 +03:00
Mark Felder
709723182d Ensure SimplePolicy's tags in string representation don't trip up the object validator 2020-09-14 17:06:42 -05:00
Mark Felder
c0b36621f1 Ensure we only apply NSFW Simple policy on parsable objects 2020-09-11 23:22:14 -05:00
Haelwenn (lanodan) Monnier
f1f44069ae
Fetcher: Correctly return MRF reject reason 2020-09-11 20:00:41 +02:00
Ivan Tashkinov
0bda85857e Merge remote-tracking branch 'remotes/origin/develop' into media-preview-proxy
# Conflicts:
#	lib/pleroma/instances/instance.ex
2020-09-11 17:19:58 +03:00
Haelwenn (lanodan) Monnier
f18178cb09
AttachmentValidator: directly embed url schema and pass it fix_media_type 2020-09-11 01:40:20 +02:00
Haelwenn (lanodan) Monnier
1b3d5956b1
Pipeline Ingestion: Article 2020-09-11 01:40:20 +02:00
Haelwenn (lanodan) Monnier
2132b24a9d
object_validators: likes & announcements as [ObjectID] 2020-09-11 01:39:39 +02:00
Haelwenn (lanodan) Monnier
846b59ccb0
Pipeline Ingestion: Video 2020-09-11 01:39:39 +02:00
Haelwenn (lanodan) Monnier
b73e9ef686
transmogrifier: Call strip_internal_fields on pipeline ingestion 2020-09-11 01:39:38 +02:00
Mark Felder
55562ca936 Merge branch 'develop' into feature/gen-magic 2020-09-10 16:05:22 -05:00
Alexander Strizhakov
357d971a10 expiration for new pipeline 2020-09-10 21:50:41 +03:00
Alexander Strizhakov
93e1c8df9d reject activity creation
if passed expires_at option and expiring activities are not configured
2020-09-10 21:50:41 +03:00
Alexander Strizhakov
9bf1065a06 schedule activity expiration in Oban 2020-09-10 21:50:40 +03:00
rinpatch
541a3eede2 Merge branch 'chores/remove-ostatus-fixtures' into 'develop'
Remove OStatus in testsuite

See merge request pleroma/pleroma!2968
2020-09-10 18:41:00 +00:00
Ivan Tashkinov
148bc24435 [#2497] Removed Hackney-specific code
(no longer needed due to adapter options unification).
2020-09-10 11:54:10 +03:00
Mark Felder
4ee99dafcc Merge branch 'develop' into media-preview-proxy 2020-09-09 11:11:36 -05:00
Haelwenn (lanodan) Monnier
10ef532c63 AP C2S: Restrict character limit on Note 2020-09-08 20:21:34 +03:00
Haelwenn (lanodan) Monnier
ee0e05f930
Drop unused "inReplyToAtomUri" in objects 2020-09-08 18:43:57 +02:00
Mark Felder
21efda2edb Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into unlisted 2020-09-08 09:31:26 -05:00
95688c90ad ForceBotUnlistedPolicy: simplify code 2020-09-08 01:15:15 +02:00
8b695c3eeb ForceBotUnlistedPolicy: format 2020-09-07 22:53:45 +02:00
699224a900 ForceBotUnlistedPolicy: initial add, tiny clean up from my previous version 2020-09-07 22:15:42 +02:00
Alexander Strizhakov
696bf09433
passing adapter options directly without adapter key 2020-09-07 19:59:17 +03:00
Alexander Strizhakov
a83916fdac
adapter options unification
not needed options deletion
2020-09-07 19:59:17 +03:00
Ivan Tashkinov
88a6ee4a59 [#2497] Func defs grouping fix. 2020-09-05 20:23:18 +03:00
Ivan Tashkinov
f170d47130 [#2497] Adjusted media proxy preview invalidation. Allowed client-side caching for media preview. Adjusted prewarmer to fetch only proxiable URIs.
Removed :preview pool in favor of existing :media one. Misc. refactoring.
2020-09-05 20:19:09 +03:00
Mark Felder
85446cc30c Merge branch 'develop' into media-preview-proxy 2020-09-03 10:34:06 -05:00
lain
9433311923 Merge branch 'bugfix/incoming-poll-emoji' into 'develop'
Fix emoji in Question, force generated context/context_id insertion

Closes #1870

See merge request pleroma/pleroma!2915
2020-09-03 11:50:30 +00:00
rinpatch
126461942b User table: ensure bio is always a string
Gets rid of '|| ""' in multiple places and fixes #2067
2020-09-01 10:45:42 +03:00
Haelwenn (lanodan) Monnier
b960cede9a
common_fixes: Force inserting context and context_id 2020-09-01 08:35:00 +02:00
Haelwenn (lanodan) Monnier
a142da3e4f
Add new Emoji Ecto.Type and fix emoji in Question 2020-09-01 08:34:57 +02:00
Haelwenn (lanodan) Monnier
2ecc7d9230
transmogrifier: Remove mastodon emoji-format from emoji field 2020-09-01 08:29:53 +02:00
Mark Felder
479578b148 Merge branch 'develop' into feld-2168-media-preview-proxy 2020-08-25 11:57:23 -05:00
d39abd02ac Merge branch 'relay-fix-admin-fe' into 'develop'
Relay fix for admin-fe

See merge request pleroma/pleroma!2902
2020-08-24 17:03:18 +00:00
Mark Felder
4e6eb22b4a Try to warm the cache with the preview image if preview proxy enabled 2020-08-21 12:19:35 -05:00
Haelwenn (lanodan) Monnier
36c125a071
Pipeline Ingestion: Event 2020-08-20 21:49:26 +02:00
Alexander Strizhakov
7dc275b69b
relay fix for admin-fe 2020-08-19 08:41:39 +03:00
Haelwenn (lanodan) Monnier
5316e231b0
Pipeline Ingestion: Audio (Part 2) 2020-08-19 00:06:31 +02:00
lain
3998ef9d64 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into features/validators-audio 2020-08-18 13:31:42 +02:00
lain
548ca43bcf Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into features/validators_use_ectotypes 2020-08-18 12:38:13 +02:00
Haelwenn (lanodan) Monnier
2f8c3c842d
common_fixes: Remove Utils.make_date call 2020-08-18 02:24:48 +02:00
Haelwenn (lanodan) Monnier
c9d6638461
common_fixes: Get fixes common from Audio and Question 2020-08-18 02:24:48 +02:00
Haelwenn (lanodan) Monnier
2bc08d5573
Pipeline Ingestion: Audio 2020-08-18 02:02:34 +02:00
Haelwenn (lanodan) Monnier
7a273087ed
object_validators: Use ecto_types where available 2020-08-17 23:47:00 +02:00
Ivan Tashkinov
95529ab709 [#2046] Defaulted pleroma/restrict_unauthenticated basing on instance privacy setting (i.e. restrict on private instances only by default). 2020-08-14 20:55:45 +03:00
14a06e63f6 Merge branch 'fix/activity-expirations-again' into 'develop'
Fix activity expirations again

See merge request pleroma/pleroma!2866
2020-08-13 17:38:19 +00:00
Haelwenn (lanodan) Monnier
4f3c955f26
side_effects: Fix typo on notification 2020-08-13 18:10:43 +02:00
lain
2e347e8286 ActivityPub: Remove reject, move everything to the Pipeline. 2020-08-12 15:07:46 +02:00
lain
7224bf309e Transmogrifier: Move Rejects to the Pipeline 2020-08-12 14:48:51 +02:00
lain
500576dcb6 Linting fixes. 2020-08-11 19:22:14 +02:00
lain
25bfee0d12 ActivityPub: Remove ActivityPub.accept
Switch to the pipeline in CommonAPI and SideEffects
2020-08-11 17:43:16 +02:00
lain
f988d82e46 Transmogrifier: Handle accepts with the pipeline 2020-08-11 17:26:01 +02:00
lain
3f6d50111e Linter fixes. 2020-08-11 16:07:42 +02:00
lain
da3f9b9988 Transmogrifier: Remove handling of orphaned accepts
This was a Mastodon 2.3 issue and has been fixed for a long time.
According to fediverse.networks, less than one percent of servers
still run a version this old or older.
2020-08-11 15:41:19 +02:00
lain
8b1e8bec2f AcceptValidation: Codify accept rules. 2020-08-11 15:32:52 +02:00
lain
f1a0c10b17 AcceptValidator: Add basic validator with tests. 2020-08-11 15:13:07 +02:00
lain
8f9fbc86c0 Transmogrifier: Small readability changes. 2020-08-11 14:02:09 +02:00
lain
677abbf0ee Merge branch 'fix/activity-expirations-again' of git.pleroma.social:pleroma/pleroma into fix/activity-expirations-again 2020-08-11 10:55:10 +02:00
lain
7e4932362b SideEffects: Handle strange deletion case. 2020-08-11 10:54:38 +02:00
lain
11fc90744c Transmogrifier: Remove duplicate code. 2020-08-10 15:31:36 +02:00
Alex Gleason
cc196e2cd5
Merge remote-tracking branch 'upstream/develop' into restrict-domain 2020-08-05 13:08:31 -05:00
Alex Gleason
ad9c925efb
Speed up instance timeline query 2020-08-05 13:08:13 -05:00
lain
9d7ce1a6d0 CommonValidations: More refactors. 2020-08-05 17:56:12 +02:00
lain
3655175639 CommonValidations: Refactor same_domain? 2020-08-05 17:36:27 +02:00
lain
9c96fc052a CommonValidations: Extract modification right checker 2020-08-05 17:26:53 +02:00
lain
f889400d05 Questions: Move fixes to validators. 2020-08-05 14:51:33 +02:00
lain
00c4c6a382 CommonValidations: Remove superfluous function
The `is_active` functionality was integrated into the presence
checker.
2020-08-05 12:24:34 +02:00
lain
19c108170e Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into features/poll-validation 2020-08-05 11:12:14 +02:00
rinpatch
b1b6a7dfa8 Merge branch 'deactivated-user-posts' into 'develop'
Deactivated user posts

Closes #2011

See merge request pleroma/pleroma!2845
2020-08-04 19:17:30 +00:00
Egor Kislitsyn
91fbb5b21f
Fix ActivityExpirationPolicy 2020-08-04 18:26:37 +04:00
lain
878c7f3f30 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into features/poll-validation 2020-08-04 15:28:41 +02:00
Haelwenn (lanodan) Monnier
0f088d8ce3
question_validator: Allow content to be an empty-string (blank) 2020-08-04 14:29:16 +02:00
lain
1a00713744 CommonValidations: Treat deactivated users as not present. 2020-08-04 14:17:03 +02:00
lain
56b5b9aa27 Merge branch 'follower-mrf-again' into 'develop'
Follower mrf again

See merge request pleroma/pleroma!2833
2020-08-03 14:22:11 +00:00
lain
10c792110e MRF Object Age Policy: Don't break on messages without cc/to 2020-08-03 14:12:32 +02:00
lain
4b18a07392 Revert "Merge branch 'revert-1ac0969c' into 'develop'"
This reverts merge request !2825
2020-07-31 15:18:04 +00:00
lain
010d77ec85 Revert "Merge branch 'mrf-silence-2' into 'develop'"
This reverts merge request !2820
2020-07-31 15:17:09 +00:00
Haelwenn (lanodan) Monnier
ac2598307d
Merge remote-tracking branch 'pleroma/develop' into features/poll-validation 2020-07-31 13:57:21 +02:00
lain
1dd162a5f7 SimplePolicy: Fix problem with DM leaks. 2020-07-31 09:57:30 +02:00
Alex Gleason
702f0fb822
Merge remote-tracking branch 'upstream/develop' into mrf-silence 2020-07-29 13:01:16 -05:00
Alex Gleason
93638935d7
SimpleMRF: :silence --> :followers_only 2020-07-29 12:58:08 -05:00
lain
edf8b6abfe EnsureRePrepended: Don't break on chat messages. 2020-07-29 10:53:08 +02:00
Alex Gleason
2a99e7df8e
SimpleMRF silence: optimize, work okay with nil values in addressing 2020-07-28 20:32:58 -05:00
Alex Gleason
3c90f7f715
SimpleMRF: Let instances be silenced 2020-07-28 19:06:42 -05:00
lain
9e6f4694dd Pipeline: Unify embedded_object / object_data, move to validator. 2020-07-27 16:39:50 +02:00
Lain Soykaf
3d13fb05f8 Side Effects: On undoing, put information about the undone object. 2020-07-24 14:40:22 +02:00
Lain Soykaf
91f3cf9bc6 Pipeline: Add embedded object federation. 2020-07-24 14:06:41 +02:00
lain
76aa49a0c5 Merge branch '1973-chats-fix-with-restrict-unauthenticated' into 'develop'
[#1973] Fixed accounts rendering in GET /api/v1/pleroma/chats with truish :restrict_unauthenticated setting

Closes #1973

See merge request pleroma/pleroma!2791
2020-07-23 12:52:02 +00:00
Ivan Tashkinov
9ea51a6de5 [#2791] AccountView: renamed :force option to :skip_visibility_check. 2020-07-23 15:08:30 +03:00
lain
b2ba70eec4 Merge branch 'bugfix/mrf-reject-logging' into 'develop'
Fix #783: Make MRF reject log as info level instead of error

Closes #783

See merge request pleroma/pleroma!2758
2020-07-23 11:08:29 +00:00
Ivan Tashkinov
6f5f7af607 [#1973] Fixed accounts rendering in GET /api/v1/pleroma/chats with truish :restrict_unauthenticated.
Made `Pleroma.Web.MastodonAPI.AccountView.render("show.json", _)` demand :for or :force option in order to prevent incorrect rendering of empty map instead of expected user representation with truish :restrict_unauthenticated setting.
2020-07-22 19:06:00 +03:00
Alex Gleason
afa8b469ed
Allow restricting public timeline by instance 2020-07-18 19:35:07 -05:00
rinpatch
0fe36b311c Merge branch 'features/mrf-reasons' into 'develop'
Add rejection reason to our MRFs

See merge request pleroma/pleroma!2759
2020-07-15 14:00:22 +00:00
Haelwenn (lanodan) Monnier
e4beff90f5
Create Question: Add context field to create 2020-07-15 12:32:43 +02:00
Haelwenn (lanodan) Monnier
bfe2dafd39
{Answer,Question}Validator: Keep both actor and attributedTo for now but sync them 2020-07-15 12:32:42 +02:00
Haelwenn (lanodan) Monnier
c19bdc811e
Fix attachments in polls 2020-07-15 12:32:42 +02:00
Haelwenn (lanodan) Monnier
d713930ea7
Fixup for EctoType module move 2020-07-15 11:40:24 +02:00
Haelwenn (lanodan) Monnier
435a65b976
QuestionValidator: Use AttachmentValidator 2020-07-15 11:40:24 +02:00
Haelwenn (lanodan) Monnier
fe6924d00d
CreateGenericValidator: add expires_at 2020-07-15 11:40:24 +02:00
Haelwenn (lanodan) Monnier
82895a4012
SideEffects: port ones from ActivityPub.do_create and ActivityPub.insert 2020-07-15 11:40:23 +02:00
Haelwenn (lanodan) Monnier
4f70fd4105
question_validator: remove conversation field 2020-07-15 11:39:56 +02:00
Haelwenn (lanodan) Monnier
173f69c854
question_validator: fix for mastodon poll expiration
Mastodon activities do not have a "closed" field, this could be seen on
https://pouet.it/users/lanodan_tmp/statuses/104345126997708380
which runs Mastodon 3.1.4 (SDF runs 3.1.2)
2020-07-15 11:39:56 +02:00
Haelwenn (lanodan) Monnier
47ba796f41
create_question_validator: remove validate_recipients_match 2020-07-15 11:39:55 +02:00
Haelwenn (lanodan) Monnier
10bd08ef07
transmogrifier_test: test date, anyOf and oneOf completely 2020-07-15 11:39:54 +02:00
Haelwenn (lanodan) Monnier
89a2433154
QuestionOptionsValidator: inline schema for replies 2020-07-15 11:39:54 +02:00
Haelwenn (lanodan) Monnier
c5efaf6b00
AnswerValidator: Create 2020-07-15 11:39:54 +02:00
Haelwenn (lanodan) Monnier
7bcd7a9595
QuestionValidator: Create 2020-07-15 11:39:53 +02:00
Maksim Pechnikov
1dd767b8c7 Include port in host for signatures 2020-07-14 21:44:08 +03:00
246f49d685 Merge branch '1916-transmogrifier-skipping-oddities-in-address-fields' into 'develop'
Transmogrifier: filtering weirdness in address fields

Closes #1916

See merge request pleroma/pleroma!2762
2020-07-14 15:17:25 +00:00
Haelwenn (lanodan) Monnier
858d9fc7e8
MRF Policies: Return a {:reject, reason} instead of {:reject, nil} 2020-07-14 11:04:16 +02:00
=
b221b640a2 Transmogrifier: filtering weirdness in address fields 2020-07-13 22:43:21 +03:00
Haelwenn (lanodan) Monnier
ce243b107f
Use Logger.info for {:reject, reason} 2020-07-13 15:26:31 +02:00
Haelwenn (lanodan) Monnier
2aac92e9e0
Transmogrifier.fix_in_reply_to/2: Use warn for non-fatal fail to get replied-to post 2020-07-13 15:26:30 +02:00
lain
93e494ec21 ActivityPub: Don't rename a clashing nickname with the same ap id. 2020-07-10 14:10:44 +02:00
lain
b39eb6ecc5 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into chat-federation-information 2020-07-10 12:26:53 +02:00
Mark Felder
d23804f191 Use the Pleroma.Config alias 2020-07-09 10:53:51 -05:00
Haelwenn
68036f5a3b Merge branch 'follow-pipeline' into 'develop'
Handle `Follow` activities with the pipeline

See merge request pleroma/pleroma!2734
2020-07-09 10:32:24 +00:00
lain
00e54f8fe7 ActivityPub: Remove follow and fix issues. 2020-07-08 17:07:24 +02:00
lain
9dda8b5427 CommonAPI: Switch to pipeline for following. 2020-07-08 15:40:56 +02:00
lain
172f4aff8e Transmogrifier: Move following to the pipeline. 2020-07-08 14:30:53 +02:00
lain
7d0e2b3fdd Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into follow-pipeline 2020-07-08 13:23:07 +02:00
lain
cdc153db31 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into issue/1880 2020-07-08 13:21:58 +02:00
Maksim Pechnikov
e341f81785 fixed delete Like activity in remove user 2020-07-08 09:06:23 +03:00
lain
9ad305209a Merge branch 'bugfix/peertube-videos' into 'develop'
Fix getting videos from peertube

See merge request pleroma/pleroma!2728
2020-07-07 09:14:50 +00:00
Haelwenn (lanodan) Monnier
fbb9743a70
Fix getting videos from peertube 2020-07-07 09:38:38 +02:00
lain
a6a12b241f FollowValidator: Add basic validation. 2020-07-06 15:57:19 +02:00
lain
208baf157a ActivityPub: Add new 'capabilities' to user. 2020-07-06 11:38:40 +02:00
Sergey Suprunenko
8277b29790
Restrict thread statuses that contain user's irreversible filters 2020-07-06 09:30:39 +03:00
Sergey Suprunenko
4a8c26654e
Restrict statuses that contain user's irreversible filters 2020-07-06 09:28:21 +03:00
lain
4a7b89e372 ChatMessageValidator: Additional validation. 2020-07-03 15:13:27 +02:00
lain
5c0bf4c472 ActivityPub: Ingest information about chat acceptance. 2020-07-03 13:58:34 +02:00
lain
26a7cc3f00 UserView: Add acceptsChatMessages field 2020-07-03 13:38:59 +02:00
rinpatch
4c044f6225 Merge branch 'fetcher-fixes' into 'develop'
Don't fail fetching when the user in a replied-to message can't be fetched.

See merge request pleroma/pleroma!2711
2020-07-02 10:17:51 +00:00
lain
bad08f34ca Credo fixes. 2020-07-02 09:57:31 +02:00
lain
61fe94d698 SideEffects: Refactor. 2020-07-02 09:33:50 +02:00
lain
fedfe8f7d6 ActivityPub: Handle clashing nicknames for the same ap id
If we get a new user (identified by ap_id) that would have the same
nickname as an existing user, give the existing user a nickname that
is prepended with the user id, as this will never clash.

This can happen when a user switches server software and that soft-
ware generates ap ids in a different way.
2020-07-01 12:26:07 +02:00
lain
ce92e6e5ce Fetcher: Work when we can't get the OP. 2020-07-01 11:48:51 +02:00
lain
577da132da Merge branch '1031-parent-visible' into 'develop'
Resolve "Add `pleroma.parent_visible` to the status view"

Closes #1031

See merge request pleroma/pleroma!2679
2020-06-29 08:39:51 +00:00
Haelwenn
bf1c5e255a Merge branch 'block-handling' into 'develop'
Handle blocks with the pipeline

See merge request pleroma/pleroma!2685
2020-06-26 17:41:00 +00:00