-
- Downloads
Pass SSO IdP information to spam checker's registration function (#9626)
Fixes https://github.com/matrix-org/synapse/issues/9572 When a SSO user logs in for the first time, we create a local Matrix user for them. This goes through the register_user flow, which ends up triggering the spam checker. Spam checker modules don't currently have any way to differentiate between a user trying to sign up initially, versus an SSO user (whom has presumably already been approved elsewhere) trying to log in for the first time. This PR passes `auth_provider_id` as an argument to the `check_registration_for_spam` function. This argument will contain an ID of an SSO provider (`"saml"`, `"cas"`, etc.) if one was used, else `None`.
Showing
- changelog.d/9626.feature 1 addition, 0 deletionschangelog.d/9626.feature
- docs/spam_checker.md 7 additions, 1 deletiondocs/spam_checker.md
- synapse/events/spamcheck.py 26 additions, 3 deletionssynapse/events/spamcheck.py
- synapse/handlers/register.py 2 additions, 2 deletionssynapse/handlers/register.py
- tests/handlers/test_register.py 31 additions, 0 deletionstests/handlers/test_register.py
Loading
Please register or sign in to comment