Files
synapse/tests
Kegan DougalandClaude Opus 5 c692133ed4 Co-sign MSC4430 linkage information under the state_key entity
An `m.room.member` event in a member key room carries two signatures: the
member key named by `sender` signs the event, and the server named by
`content.domain` co-signs the claim that the key in `state_key` belongs to
`content.localpart` there. That co-signature was made under the signing
server's own name, which leaves a reader unable to tell what is being
asserted: an invite is sent by one member key and co-signed by the
*invitee's* server, so a signature by `example.com` on it could plausibly
stand behind either the sender or the target.

Name the entity for the member the claim is about instead. The constant
`state_key` joins the existing constant `sender`, and a signature under it
is, by construction, an assertion about the member named by the event's
`state_key` whoever sent the event. The key ID stays the signing server's
real key ID, since that is what names the published key a verifier must
check it against; only member keys use the constant `ed25519:1`.

A signature under a server's name is now refused outright rather than
treated as linkage information, so the only entities an event in such a
room may carry are `sender`, `state_key` and the authorising member key of
a restricted join.

Nothing yet verifies a co-signature, so this changes only the events this
server produces, and only in member key rooms.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-10-15 16:05:01 +02:00
..
2026-09-18 12:00:45 +01:00