akkoma/lib/pleroma/web/activity_pub
Oneric a80444041c federation: always prefer the shared inbox
In theory a pedantic reading of the spec indeed suggests
DMs must only be delivered to personal inboxes. However,
in practice the normative force of real-world implementations
disagrees. Mastodon, Iceshrimp.NET and GtS (the latter notably has a
config option to never use sharedInboxes) all unconditionally prefer
sharedInbox for everything without ill effect. This saves on duplicate
deliveries on the sending and processing on the receiving end.
(Typically the receiving side ends up rejecting
 all but the first copy as duplicates)

Furthermore current determine_inbox logic also actually needs up
forcing personal inboxes for follower-only posts, unless they
additionally explicitly address at least one specific actor.
This is even much wasteful and directly contradicts
the explicit intent of the spec.

There’s one part where the use of sharedInbox falls apart,
namely spec-compliant bcc and bto addressing. AP spec requires
bcc/bto fields to be stripped before delivery and then implicitly
reconstructed by the receiver based on the addressed personal inbox.
In practice however, this addressing mode is almost unused. Neither of
the three implementations brought up above supports it and while *oma
does use bcc for list addressing, it does not use it in a spec-compliant
way and even copies same-host recipients into cc before delivery.
Messages with bcc addressing are handled in another function clause,
always force personal inboxes for every recipient and not affected by
this commit.
In theory it would be beneficial to use sharedInbox there too for all
but bcc recipients. But in practice list addressing has been broken for
quite some time already and is not actually exposed in any frontend,
as discussed in https://akkoma.dev/AkkomaGang/akkoma/issues/812.
Therefore any changes here have virtually no effect anyway
and all code concerning it may just be outright removed.
2025-05-06 17:38:24 +02:00
..
activity_pub Remove deps from Streaming/Persisting behaviors 2021-06-01 13:55:07 -05:00
mrf elixir 1.18 formatting 2025-03-02 11:54:00 +00:00
object_validator Bump Copyright to 2021 2021-01-13 07:49:50 +01:00
object_validators elixir 1.18 formatting 2025-03-02 11:54:00 +00:00
side_effects Refactor ES on top of search behaviour 2022-06-30 16:28:31 +01:00
views standardise local key id generation 2024-10-30 12:44:01 +00:00
activity_pub.ex Don't return garbage on failed collection fetches 2025-02-14 18:49:51 +01:00
activity_pub_controller.ex Fix http signature plug tests 2024-10-26 05:05:48 +01:00
builder.ex Migrate to phoenix 1.7 (#626) 2023-08-15 10:22:18 +00:00
internal_fetch_actor.ex Bump Copyright to 2021 2021-01-13 07:49:50 +01:00
mrf.ex cosmetic: fix elixir 1.17 compiler warnings in main application 2024-06-19 01:49:59 +02:00
object_validator.ex federation/incoming: improve link_resolve retry decision 2025-01-07 20:27:28 +01:00
pipeline.ex Refactor ES on top of search behaviour 2022-06-30 16:28:31 +01:00
publisher.ex federation: always prefer the shared inbox 2025-05-06 17:38:24 +02:00
relay.ex Bump Copyright to 2021 2021-01-13 07:49:50 +01:00
side_effects.ex RichMedia refactor 2024-06-09 17:33:48 +01:00
transmogrifier.ex federation/in: always copy object addressing into its Create activity 2025-03-17 23:08:27 +01:00
utils.ex Migrate to phoenix 1.7 (#626) 2023-08-15 10:22:18 +00:00
visibility.ex local-only-fixed (#138) 2022-08-02 14:46:46 +00:00