element-hq / element-hq/synapse

Federation 'send_join' is insufficiently pedantic (SYN-507)

Open
#1,407 0 comments 0 reactions 0 assignees View on GitHub
A-Federated-Join A-Spec-Compliance A-Validation O-Uncommon S-Minor T-Defect Z-Cleanup
Dominant language
Python
Stars
4.6k
Forks
600
Avg merge
5d 6h
Merged PRs (30d)
46

Description

This issue has been migrated from [#1407](https://github.com/matrix-org/synapse/issues/1407).

---

In the process of writing a wire-level federation test in sytest to check the room join dance of synapse, I have ended up with a "minimal viable case" test (https://github.com/matrix-org/sytest/blob/paul/federation/tests/50federation/30room-join.pl).

This test appears to be too small in places, and is missing things that we feel synapse ought to require. This bug exists to track those things it should be checking, that this test demonstrates it currently does not.

synapse does not notice any of the following mistakes:

* missing `m.room.member` event for the room creator.
* missing `m.room.power_levels` event.
* `m.room.member` event of joining user has `depth` of 1.
* all `auth_events` have a depth of 0.
* joining server does not hash or sign the event submitted to `send_join`.
* the `state` key returned by `send_join` can be an empty object, or an empty list.

(Imported from https://matrix.org/jira/browse/SYN-507)

(Reported by @leonerd)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.