API Reference
Rockets Core API
nestjs-password
classes
PasswordValidationService

Class: PasswordValidationService

Service with functions related to password validation

Implements

Constructors

new PasswordValidationService()

new PasswordValidationService(): PasswordValidationService

Returns

PasswordValidationService

Methods

validate()

validate(options): Promise<boolean>

Validate if password matches and its valid.

Parameters

ParameterTypeDescription
optionsPasswordValidateOptionsInterfaceValidation options

Returns

Promise<boolean>

Implementation of

PasswordValidationServiceInterface.validate

Defined in

packages/nestjs-password/src/services/password-validation.service.ts:17 (opens in a new tab)


validateObject()

validateObject<T>(password, object): Promise<boolean>

Validate password on an object.

Type Parameters

Type Parameter
T extends PasswordStorageInterface

Parameters

ParameterTypeDescription
passwordstringPlain text password
objectTThe object on which the password and salt are stored

Returns

Promise<boolean>

Implementation of

PasswordValidationServiceInterface.validateObject

Defined in

packages/nestjs-password/src/services/password-validation.service.ts:28 (opens in a new tab)