Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Appservices cannot create rooms with a large invite list #9952

Closed
Half-Shot opened this issue May 7, 2021 · 1 comment · Fixed by #9968
Closed

Appservices cannot create rooms with a large invite list #9952

Half-Shot opened this issue May 7, 2021 · 1 comment · Fixed by #9968
Labels
A-Application-Service Related to AS support S-Major Major functionality / product severely impaired, no satisfactory workaround. T-Defect Bugs, crashes, hangs, security vulnerabilities, or other reported issues. X-Release-Blocker Must be resolved before making a release

Comments

@Half-Shot
Copy link
Collaborator

I thought this was fixed in #9663 but it's still a bug as of v1.33.0. Trying to create a room while inviting 7 users caused the homeserver to respond with { errcode: 'M_UNKNOWN', error: 'Cannot invite so many users at once' }

@babolivier
Copy link
Contributor

The issue seems to come from this code within the create_room function:

if len(invite_list) + len(invite_3pid_list) > self._invite_burst_count:
raise SynapseError(400, "Cannot invite so many users at once")

It looks like this is because this code isn't using the RateLimiter class, probably due to the fact that we don't want to check if the user can invite just one user but potentially many of them. So either we should add this kind of capability to the RateLimiter and use it there, or tweak this code path to look up overrides from the database and appservice configs, which sounds like more faff to me.

@babolivier babolivier added T-Defect Bugs, crashes, hangs, security vulnerabilities, or other reported issues. P1 S-Major Major functionality / product severely impaired, no satisfactory workaround. X-Release-Blocker Must be resolved before making a release labels May 7, 2021
@kittykat kittykat added the z-p1 label Sep 6, 2022
@MadLittleMods MadLittleMods added the A-Application-Service Related to AS support label Dec 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Application-Service Related to AS support S-Major Major functionality / product severely impaired, no satisfactory workaround. T-Defect Bugs, crashes, hangs, security vulnerabilities, or other reported issues. X-Release-Blocker Must be resolved before making a release
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants