Skip to main content
Version: 1.1.1

isSafePassword

With this method, you can check whether the password is safe or not

Params

isSafePassword(inputPassword,options = {strictMode : false});
  • inputPassword → The password we want to check is safe
  • strictMode The strict mode checks if passwordQuality is 100 or require 3chars from each char type, returned true. - By default, the strict mode value is false

Returns

true | false
  • Boolean → It returns true if the password is secure and false if it is not secure

Usage

isSafePassword("aadfdf"); //false

isSafePassword("78788989sdsdf"); //false

isSafePassword("A5h#3232"); //true

isSafePassword("SA23sa#$"); //true

isSafePassword("Al2#B3k@P-e5",{strictMode : true}); //true

isSafePassword("A5h#3232",{strictMode : true}); //false