mastodon/app/services
ThibG d19ed18388 Get handle from atom feed's author/email field instead of guessing from URL (#1344)
The goal of this change is to enhance Mastodon's handling of remote domains
for which the APIs reside on a different host (see issue #1032).

Indeed, when a remote user unknown to Mastodon is mentionned, only its profile
URL (e.g. https://social.example.org/users/User) is known, and Mastodon has to
build a @username@domain handle for it. To do so, Mastodon fetches the user's
atom feed (e.g., https://social.example.org/users/User.atom) and uses its
content to get the username part of the handle, and the URL's host part to
build the domain (e.g., @User@social.example.org). This handle is then used
for a Webfinger request.

In the case where example.org serves the Webfinger info for @User@example.org
and all feeds and APIs are hosted at social.example.org, Mastodon will still
build @User@social.example.org and fail at resolving the account's details
through Webfinger.

This patch changes this behaviour by using the author's email address from
the atom feed to build the handle. In Mastodon-generated atom feeds, the
email address is always the handle it expects for federation.
2017-04-09 18:43:48 +02:00
..
concerns
pubsubhubbub
account_search_service.rb
after_block_service.rb
authorize_follow_service.rb
base_service.rb
block_domain_service.rb
block_service.rb
fan_out_on_write_service.rb
favourite_service.rb
fetch_atom_service.rb Shorter timeout on FetchAtomService 2017-03-22 17:41:52 +01:00
fetch_link_card_service.rb
fetch_remote_account_service.rb Get handle from atom feed's author/email field instead of guessing from URL (#1344) 2017-04-09 18:43:48 +02:00
fetch_remote_resource_service.rb
fetch_remote_status_service.rb
follow_remote_account_service.rb
follow_service.rb
mute_service.rb Mute button progress so far. WIP, doesn't entirely work correctly. 2017-03-01 22:31:21 -06:00
notify_service.rb
post_status_service.rb
precompute_feed_service.rb
process_feed_service.rb
process_hashtags_service.rb
process_interaction_service.rb
process_mentions_service.rb
reblog_service.rb Add "direct" visibility level in the backend. Web UI is not yet 2017-03-15 22:55:45 +01:00
reject_follow_service.rb
remove_status_service.rb
search_service.rb
send_interaction_service.rb
subscribe_service.rb
suspend_account_service.rb Domain blocks now have varying severity - auto-suspend vs auto-silence 2017-01-23 17:38:38 +01:00
unblock_service.rb Rewrite Atom generation from stream entries to use Ox instead of Nokogiri (#1124) 2017-04-07 05:56:56 +02:00
unfavourite_service.rb
unfollow_service.rb Rewrite Atom generation from stream entries to use Ox instead of Nokogiri (#1124) 2017-04-07 05:56:56 +02:00
unmute_service.rb
unsubscribe_service.rb
update_remote_profile_service.rb
warm_cache_service.rb