Files
Guardian/dist/passpolicy.d.ts
T
2024-02-03 00:39:27 +01:00

27 lines
644 B
TypeScript

export default class PassPolicy {
private options;
constructor(options: {
minLength: number;
maxLength: number;
minLower: number;
minUpper: number;
minNum: number;
minSpecial: number;
specialChars: string;
});
validate(password: string): {
valid: boolean;
message: string;
} | {
valid: boolean;
message?: undefined;
};
CheckDifference(newPassword: string, oldPassword: string, neededDifference?: number): {
valid: boolean;
message: string;
} | {
valid: boolean;
message?: undefined;
};
}