|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfr.paris.lutece.util.password.PasswordUtil
public final class PasswordUtil
Utility class used to generate random passwords
Method Summary | |
---|---|
static boolean |
checkPasswordFormat(String strPassword)
Check whether a password contains upper and lower case letters, special characters and numbers. |
static boolean |
checkPasswordFormat(String strPassword,
boolean bUpperAndLowerCase,
boolean bNumero,
boolean bSpecialCaracters)
Check whether a password contains upper and lower case letters, special characters and numbers. |
static Timestamp |
getPasswordMaxValidDate(int nNumberDay)
Get the maximum valid date of a password starting from now with the given number of days. |
static String |
makePassword()
Generate a new random password |
static String |
makePassword(int nPasswordSize,
boolean bUpperAndLowerCase,
boolean bNumero,
boolean bSpecialCaracters)
Generate a new random password |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static String makePassword()
public static String makePassword(int nPasswordSize, boolean bUpperAndLowerCase, boolean bNumero, boolean bSpecialCaracters)
nPasswordSize
- the password sizebUpperAndLowerCase
- true if the password must contain upper and lower casebNumero
- if the password must contain numerobSpecialCaracters
- if the password must contain special characters
public static boolean checkPasswordFormat(String strPassword)
strPassword
- The password to check
public static boolean checkPasswordFormat(String strPassword, boolean bUpperAndLowerCase, boolean bNumero, boolean bSpecialCaracters)
strPassword
- The password to checkbUpperAndLowerCase
- true if the password must contain upper and lower casebNumero
- if the password must contain numerobSpecialCaracters
- if the password must contain special characters
public static Timestamp getPasswordMaxValidDate(int nNumberDay)
nNumberDay
- The number of days the password is valid
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |