Register Password

Registers password credentials for password authentication

Description

This step is used to register password credentials for a user. Once registered, the credentials can be used to authenticate using the Password Authentication step. If needed, a temporary password can be generated for the user using the Register Temporary Password step.

This step can be used in various scenarios. For example:

  • To register password credentials for a new user upon sign up
  • To reset a password when the user forgets their password
  • To set a new password when the old one expires
  • To set a new password after the user logs in using a temporary password

Password credentials consist of a username and password, where the username corresponds to the user's identifier. The username may be provided implicitly by the journey if the user is already authenticated; otherwise, a user identifier must be specified in the step configuration. The username and password are often collected from the user, for example, using a registration form (see Get Information From User).

The password must adhere to certain complexity requirements, which are configured in the Password settings for the application. These settings also contain other relevant configuration like password expiration, password reuse policy, and failure lockout rules.

Once triggered, the step registers the password for the specified user. If the user already has a password registered, then this step will replace it with the new password. If the registration is successful, the journey continues to the next step. If it fails, the journey proceeds to the failure branch (if configured); otherwise, the journey is aborted and an error is sent to the client.

Configuration

Field Description
User Auth State Indicates if the user has authenticated in this journey.
- If set to The user is authenticated (default), the user context is provided implicitly by the journey.
- If set to The user is not authenticated, a user identifier must be provided. Note that, if the identifier doesn’t exist, a Mosaic user record is automatically created.
User Identifier Expression that yields a user identifier. Only configured if the journey doesn't authenticate the user before invoking this step.
Password Expression that yields the password to register for the user.
Error Output Variable Name of the variable that stores any errors returned by step
Failure Behavior Determines the behavior in case of failure, which either aborts the journey or proceeds to a failure branch of the control flow (default).

Example

Consider a registration form that allows the user to choose a username and password, which is created using the Get information From Client step. In our example, the step ID is regForm, the schema contains username and password, and the information will be stored in a variable named regData. In the Register Password step, both the user identifier and password are obtained from the form output (using regForm.username and regForm.password).