mirror of
https://github.com/bitwarden/mobile
synced 2025-12-28 06:03:40 +00:00
Enforce Passphrase Policy (#772)
* Enforce passphrase policy * Update multi-line conditional formatting * Updated formatting round 2 Co-authored-by: Vincent Salucci <vsalucci@bitwarden.com>
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
{
|
||||
public class PasswordGeneratorPolicyOptions
|
||||
{
|
||||
public string DefaultType { get; set; }
|
||||
public int MinLength { get; set; }
|
||||
public bool UseUppercase { get; set; }
|
||||
public bool UseLowercase { get; set; }
|
||||
@@ -9,5 +10,23 @@
|
||||
public int NumberCount { get; set; }
|
||||
public bool UseSpecial { get; set; }
|
||||
public int SpecialCount { get; set; }
|
||||
public int MinNumberOfWords { get; set; }
|
||||
public bool Capitalize { get; set; }
|
||||
public bool IncludeNumber { get; set; }
|
||||
|
||||
public bool InEffect()
|
||||
{
|
||||
return DefaultType != "" ||
|
||||
MinLength > 0 ||
|
||||
NumberCount > 0 ||
|
||||
SpecialCount > 0 ||
|
||||
UseUppercase ||
|
||||
UseLowercase ||
|
||||
UseNumbers ||
|
||||
UseSpecial ||
|
||||
MinNumberOfWords > 0 ||
|
||||
Capitalize ||
|
||||
IncludeNumber;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user