thunderbird_accounts.authentication.utils
Functions
|
Can a user register with this username. |
|
Create a url for a user to start a keycloak flow. |
|
Create an authorization URL that prefills the username on Keycloak's login page. |
|
Delete a user from Keycloak, Stalwart, and the local DB. |
|
Return a user whose recovery email or account email matches the given address. |
|
If USE_ALLOW_LIST is enabled check the email for an existing User or an AllowListEntry. |
|
Classes
|
Required actions, they're defined in the server's provider info. |
- class thunderbird_accounts.authentication.utils.KeycloakRequiredAction(*values)[source]
Bases:
StrEnumRequired actions, they’re defined in the server’s provider info.
Yes these are case sensitive… CONFIGURE_TOTP webauthn-register-passwordless UPDATE_PASSWORD TERMS_AND_CONDITIONS update_user_locale idp_link VERIFY_EMAIL delete_account webauthn-register VERIFY_PROFILE delete_credential CONFIGURE_RECOVERY_AUTHN_CODES UPDATE_PROFILE
- thunderbird_accounts.authentication.utils.is_email_in_allow_list(email: str) bool[source]
If USE_ALLOW_LIST is enabled check the email for an existing User or an AllowListEntry.
- thunderbird_accounts.authentication.utils.get_user_by_contact_email(email: str)[source]
Return a user whose recovery email or account email matches the given address.
- thunderbird_accounts.authentication.utils.can_register_with_username(username: str)[source]
Can a user register with this username. This checks primary username and any mirrored aliases for our allowed domains
This does not check is_email_reserved, as we generally use a different error for that check.
- thunderbird_accounts.authentication.utils.create_aia_url(action: KeycloakRequiredAction)[source]
Create a url for a user to start a keycloak flow. These flows are defined as actions in KeycloakRequiredAction.