-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
ModuleAPI to provide alternative registration flows #11797
Comments
I wonder if this is already possible (or close to being possible)? It seems like modules can already specify kind of login they want to handle — what would happen if you invented a login type #11743 is somewhat involved with 'don't let the user choose a user ID, just give them one and they'll have to live with it'. EDIT: Here's a reference: https://matrix-org.github.io/synapse/latest/modules/password_auth_provider_callbacks.html#auth_checkers EDIT: |
It's not anymore.
Modules can already define custom authentication flows: https://matrix-org.github.io/synapse/latest/modules/password_auth_provider_callbacks.html As an aside, #11790 is a thing that's coming up, which allow modules to arbitrary assign a username to new users, which might also be worth looking into. It doesn't interact with custom UIA steps at all though (only allows the module to override the username once the flow completes), so might not entirely be what you need. I'd be curious to hear about what you think is missing from the password auth provider callbacks to allow for your use case. |
I think I am just a little confused on password auth providers vs registration. When I read the docs I could only see ways to interact with authentication, rather than registration. I suppose I could invent a login type that autogenerates an account, but I did want to craft something around /register. This might be better off in a chat than on GitHub :)
This would possibly cover it, though there may be some complexity that we would only want this for one registration flow (guest-like) so I think we'd still need a flow. |
Okay, so @babolivier confirmed to me OOB that Modules can hook into UIA and it's probably sensible for the Module API to document them. I'll rephrase the issue. |
From chat, it sounds like password auth providers might work, but the documentation is confusingly saying that they're for auth. While it's correct (since registration uses UIA), it could use some spelling out in the docs. I've opened #11800 to track this, in the meantime I'll close this - @Half-Shot feel free to reopen if you find out that the current module interface is missing things. |
Oh huh, it looks like we clashed here :/ |
EDIT: After discussions with the team, this a documentation omission rather than a feature request.
We'd like the ability to provide an alternative registration system by way of module. In particular our requirements are that we'd like users to hit register and instantly be granted an account with a randomized userId (but not be nerfed like Guests). This would presumably be quite a simple module, so it would be good to have hooks for that.
The text was updated successfully, but these errors were encountered: