对密码策略实施的约束
签名:
export interface CustomStrengthOptionsConfig
特性
财产 | 类型 | 描述 |
---|---|---|
最长长度 | 数字 | 最大密码长度。无默认最大长度 |
最小长度 | 数字 | 最小密码长度。有效值为 6 到 30 |
要求小写 | 布尔值 | 密码必须包含小写字符 |
要求非字母数字 | 布尔值 | 密码必须包含非字母数字字符 |
需要数字 | 布尔值 | 密码必须包含数字 |
要求大写 | 布尔值 | 密码必须包含大写字符 |
CustomStrengthOptionsConfig.maxLength
最大密码长度。无默认最大长度
签名:
maxLength?: number;
CustomStrengthOptionsConfig.minLength
最小密码长度。有效值为 6 到 30
签名:
minLength?: number;
CustomStrengthOptionsConfig.requireLowercase
密码必须包含小写字符
签名:
requireLowercase?: boolean;
CustomStrengthOptionsConfig.requireNonAlphanumeric
密码必须包含非字母数字字符
签名:
requireNonAlphanumeric?: boolean;
CustomStrengthOptionsConfig.requireNumeric
密码必须包含数字
签名:
requireNumeric?: boolean;
CustomStrengthOptionsConfig.requireUppercase
密码必须包含大写字符
签名:
requireUppercase?: boolean;