This flow is used in setups where a user logs in with a username different to their email address.
The user must then enter their email address and will receive their username in an email.
The plugin must first be configured with an email provider in its settings:
The entry point to the forgot username flow is shown below.
The page is invoked via a GET request to a URL such as /authn/authentication/forgot-account-id
:
The input is only accepted if the value entered is a valid email regular expression.
Non-existing and existing values are both accepted, as a best security practice.
The following screen is rendered:
An email will then be received that provides the username:
The Request Handler provides the plugin logic for this flow.
This class is injected with the following SDK objects, which implement its main behavior:
SDK Object | Usage |
---|---|
AccountManager | Used to find the account for the username or email entered |
UserPreferenceManager | Used to default the username to the previously saved value |
EmailSender | Used to send the forgot username email |
The following resources can be customized as required: