Implement MSC4233: Remembering which server a user knocked through#19956
Open
ara4n wants to merge 4 commits into
Open
Implement MSC4233: Remembering which server a user knocked through#19956ara4n wants to merge 4 commits into
ara4n wants to merge 4 commits into
Conversation
Fixes rescinding and denying knocks over federation (#18030): - Remember the server that fulfilled our /send_knock in a new local_knock_via_servers table. - Route a rescission of the knock (make_leave/send_leave) through that server, instead of only rescinding locally. - Send a leave/ban denying a knock to the knocking user's server (the same mechanism as invite rescissions), and accept such an event as an out-of-band retraction on the knocking server when it references the knock in its auth events and comes from the server we knocked through (or the denying user's own server). Gated behind the experimental msc4233_enabled flag. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Uk8aPxHn3BHCe52L226jdG
Outliers never gain replaces_state, so clients could not tell a denied knock (prev_content.membership == knock) from a plain kick. Reflect the replaced knock event in the denial's unsigned ourselves. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Uk8aPxHn3BHCe52L226jdG
MSC2403 gives a ban the same retracting effect as a kick. The sender and receive sides already handled BAN; the storage layer did not — extend the out-of-band membership assertions and the sliding-sync snapshot handling (a ban denying a knock inherits the knock's metadata, like a leave). Adds sender- and receive-side ban unit tests. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Uk8aPxHn3BHCe52L226jdG
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #18030
Pull Request Checklist
EventStoretoEventWorkerStore.".code blocks.