Click or drag to resize

VGSecurityManagerResetPassword Method (String, Boolean)

Note: This API is now obsolete.

Resets a user's password to a new, automatically generated password.

Namespace:  Novalys.VisualGuard.Security
Assembly:  Novalys.VisualGuard.Security (in Novalys.VisualGuard.Security.dll) Version: 2019.1.831.19 (2019.1.0831.19)
Syntax
[ObsoleteAttribute("You need to use ResetPassword or ForcePassword methods in {VGSecurityManager.Runtime.Membership}")]
public static string ResetPassword(
	string name,
	bool ignoreRequiresQuestionAndAnswer
)

Parameters

name
Type: SystemString
The name of the user to reset the password for.
ignoreRequiresQuestionAndAnswer
Type: SystemBoolean
When the value is true ignore the option RequiresQuestionAndAnswer and reset the password.

Return Value

Type: String
The new password for the specified user.
Exceptions
ExceptionCondition
ArgumentNullException

The name is null.

ArgumentException

The name is longer than 64 characters

or

The name is empty.

VGMembershipPasswordException The user account is currently locked out or does not exist.

- or -

The generated password does not pass the password policy validation.
NotSupportedException

RequiresQuestionAndAnswer is set to true and ignoreRequiresQuestionAndAnswer is set to false.

or

EnablePasswordReset is not set to true.

or

the repository does not support Visual Guard authentication mode.

SecurityExceptionignoreRequiresQuestionAndAnswer is true and the current user does not have enough privileges to ignore password answer. The Membership access level of the application must be sufficient to allows this action or the 'Membership Manager' role must be granted to the user by using the Visual Guard console.
See Also