password reset - UpendoVentures/Upendo-Dnn-Prompt GitHub Wiki
password-reset
DNN has a built-in command which is similar, reset-password
. This command is intentionally different, having been built for a specific client project.
In this case, password-reset
does things a bit differently. Both commands allow you to specify user account(s) which you want to mark to force their password to be reset. This command has more options to do this for the entire DNN instance, an entire (but specific) site, by their user ID, or a role ID. In all cases, this command will notify the end-users. The built-in DNN command supplies this as another optional flag.
This command also will log the action to the event log, as seen in the example below.
{0} has chosen to require changed password(s) for: Scope ({1}), UserID ({2}), RoleID ({3}), PortalID ({4}).
Added In Version
Command
Command | Description |
---|---|
password-reset |
Updates the specified user accounts to force them to reset their password the next time they log in. |
Arguments
The flags below can help you determine exactly how to use this prompt.
NOTE: In all cases, you are only meant to use ONE command at a time.
Flag | Type | Default | Description |
---|---|---|---|
--scope |
String | (current |
all ) |
--portalid |
Integer | (no default) | Enter a valid ID number for the site you wish to have all user accounts change their password. |
--roleid |
Integer | (no default) | Enter a valid ID number for the security role you wish to have all user accounts change their password. |
--userid |
Integer | (no default) | Enter a valid ID number for the user account you wish to force to change their password. |
Output
If successful, you should see a message stating so.
Command Success:
Your request to reset the password for the specified user accounts was successful. Each user account will be prompted to change their password the next time they log in.
If you attempt to use a combination of the flags, you'll see the message below.
The scope can only be 'all' or 'current'. If you want to use the other parameters, please choose only one to use at a time (e.g., UserID, RoleID, PortalID).
Invalid Site (Portal) ID:
No website was found matching your query. Please check the PortalID entered for accuracy and try again.
Invalid Security Role ID:
No security role was found matching your query. Please check the RoleID entered for accuracy and try again.
Invalid User ID:
No user account was found matching your query. Please check the UserID entered for accuracy and try again.
Additional Notes
None at this time.