This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
Room and group names should be limited to a sensible length #8151
Labels
O-Uncommon
Most users are unlikely to come across this or unexpected workflow
S-Minor
Blocks non-critical functionality, workarounds exist.
T-Defect
Bugs, crashes, hangs, security vulnerabilities, or other reported issues.
Z-Help-Wanted
We know exactly how to fix this issue, and would be grateful for any contribution
Description
You can set room names and topics to absurdly long strings, which don't fit in a matrix state event. As a result, when you create a room in Element doing so, you get a room with no name/topic as the state event failed to send.
Synapse should fail the
/createRoom
call instead immediately instead of creating a room with no name/topic.There's a similar issue with groups, though while the group is created successfully, being able to create groups with unlimited-length names is not ideal.
We already limit the size of usernames to 512 characters, returning a 400
M_UNKNOWN
. We can do this again for now, but it'd be nice to get an appropriate error code to return so that clients can show a helpful reason as to why creating the room failed. Related spec issue: https://github.com/matrix-org/matrix-doc/issues/1646Steps to reproduce
/createRoom
call fails with a 500Version information
v1.19.0
The text was updated successfully, but these errors were encountered: