diff options
author | multiple creatures <dev@multiple-creature.party> | 2020-02-21 02:04:25 -0600 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2020-02-21 02:06:11 -0600 |
commit | 8caf9e4ede78b434443cc2cd65aeaae4412b288f (patch) | |
tree | 8843021088d03f34b9a50f66359fd5ef9b5ceca6 /app/services/activitypub | |
parent | 8a60792b01780b4741d1c6de0048bccd9887cb01 (diff) |
remove autoreject implementation, superseded by monsterfork graylisting + upstream privacy improvements
Diffstat (limited to 'app/services/activitypub')
-rw-r--r-- | app/services/activitypub/fetch_remote_account_service.rb | 2 | ||||
-rw-r--r-- | app/services/activitypub/fetch_remote_status_service.rb | 2 | ||||
-rw-r--r-- | app/services/activitypub/fetch_replies_service.rb | 2 |
3 files changed, 1 insertions, 5 deletions
diff --git a/app/services/activitypub/fetch_remote_account_service.rb b/app/services/activitypub/fetch_remote_account_service.rb index 381726c35..36a327731 100644 --- a/app/services/activitypub/fetch_remote_account_service.rb +++ b/app/services/activitypub/fetch_remote_account_service.rb @@ -12,7 +12,6 @@ class ActivityPub::FetchRemoteAccountService < BaseService return if domain_not_allowed?(uri) return ActivityPub::TagManager.instance.uri_to_resource(uri, Account) if ActivityPub::TagManager.instance.local_uri?(uri) - return if autoreject?(uri) @json = begin if prefetched_body.nil? fetch_resource(uri, id) @@ -21,7 +20,6 @@ class ActivityPub::FetchRemoteAccountService < BaseService end end - return if autoreject? return if !supported_context? || !expected_type? || (break_on_redirect && @json['movedTo'].present?) @uri = @json['id'] diff --git a/app/services/activitypub/fetch_remote_status_service.rb b/app/services/activitypub/fetch_remote_status_service.rb index 9795cf651..0779f13cc 100644 --- a/app/services/activitypub/fetch_remote_status_service.rb +++ b/app/services/activitypub/fetch_remote_status_service.rb @@ -6,7 +6,6 @@ class ActivityPub::FetchRemoteStatusService < BaseService # Should be called when uri has already been checked for locality def call(uri, id: true, prefetched_body: nil, on_behalf_of: nil, announced_by: nil, requested: false) - return if autoreject?(uri) @json = begin if prefetched_body.nil? fetch_resource(uri, id, on_behalf_of) @@ -15,7 +14,6 @@ class ActivityPub::FetchRemoteStatusService < BaseService end end - return if autoreject? return if !(supported_context? && expected_type?) || actor_id.nil? || !trustworthy_attribution?(@json['id'], actor_id) actor = ActivityPub::TagManager.instance.uri_to_resource(actor_id, Account) diff --git a/app/services/activitypub/fetch_replies_service.rb b/app/services/activitypub/fetch_replies_service.rb index 3e9a2f02a..6aae16dc1 100644 --- a/app/services/activitypub/fetch_replies_service.rb +++ b/app/services/activitypub/fetch_replies_service.rb @@ -45,7 +45,7 @@ class ActivityPub::FetchRepliesService < BaseService # amplification attacks. # Also limit to 5 fetched replies to limit potential for DoS. - @items.map { |item| value_or_id(item) }.reject { |uri| autoreject?(uri) || invalid_origin?(uri) }.take(5) + @items.map { |item| value_or_id(item) }.reject { |uri| invalid_origin?(uri) }.take(5) end def object_uri |