feat: Improve inbound federated membership handling #1952
No reviewers
Labels
No labels
Abandoned
Blocked
Bug
Changelog
Added
Changelog
Missing
Changelog
None
Cherry-picking
Database
Dependencies
Dependencies/Renovate
Difficulty
Easy
Difficulty
Hard
Difficulty
Medium
Documentation
Enhancement
Good first issue
Help wanted
Inherited
Matrix/Administration
Matrix/Appservices
Matrix/Auth
Matrix/Client
Matrix/Core
Matrix/E2EE
Matrix/Federation
Matrix/Hydra
Matrix/MSC
Matrix/Media
Matrix/T&S
Merge
Merge/Manual
Merge/Squash
Meta
Meta/CI
Meta/Packaging
Priority
Blocking
Priority
High
Priority
Low
Security
Status
Confirmed
Status
Duplicate
Status
Invalid
Status
Needs Investigation
Support
bob the builder
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Depends on
#1944 feat: PDU handler refresh
continuwuation/continuwuity
Reference
continuwuation/continuwuity!1952
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "nex/fix/incoming-federated-invites"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This pull request:
Depends on: #1944Backwards incompatibility
The additional validation introduced by this PR will break receiving invites from any continuwuity version prior to this PRs' merge. This is because there is a bug in prior code that causes us to send absolute garbage in the invite and knock states, which wouldn't even pass more relaxed validation.
Pull request checklist:
mainbranch, and the branch is named something other thanmain.myself, if applicable. This includes ensuring code compiles.
state_before_incomingb90ceee9f0build_local_dagto remove refmap hacksparse_incoming_pdu_with_known_room367a747344pdu_format_check_1feat: Improve inbound federated invite handlingto feat: Improve inbound federated membership handlingNeeds testing
c901caa2c086e05ee627create_hash_and_sign_eventis itself signed e6ac446200c22ef698b47f104097d5@ -24,3 +23,3 @@use crate::Ruma;use crate::{Ruma, server::utils::validate_any_membership_event};/// helper method for /send_join v1 and v2unhelpful docstring
@ -122,0 +109,4 @@.await.unwrap_or(RoomVersionId::V1).rules().unwrap(),this will panic with no error message if the room ID doesn't exist
It'll panic if the room version isn't recognised, although that should probably be an expect instead of an unwrap anyway
cee0482b67b4a09a0ad0b4a09a0ad0235a063338