|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.resoa.util.PasswordUtil
public class PasswordUtil
Some helper stuff around password management
| Nested Class Summary | |
|---|---|
static class |
PasswordUtil.PasswordStrength
Enumeration of different password strength |
| Field Summary | |
|---|---|
static int |
LENGTH_MIN
The default password minimum length |
| Constructor Summary | |
|---|---|
PasswordUtil()
|
|
| Method Summary | |
|---|---|
static PasswordUtil.PasswordStrength |
checkNewPassword(java.lang.String password)
Checks a password |
static PasswordUtil.PasswordStrength |
checkNewPassword(java.lang.String password,
int minLength)
Checks a password |
static boolean |
compareSecrets(java.lang.String secret,
java.lang.String md5Hash)
Compares a secret with an existing md5Hash value |
static java.lang.String |
getMD5(java.lang.String secret)
Generates a MD5 Hash |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static int LENGTH_MIN
| Constructor Detail |
|---|
public PasswordUtil()
| Method Detail |
|---|
public static PasswordUtil.PasswordStrength checkNewPassword(java.lang.String password,
int minLength)
password - the password to checkminLength - minimum lenght
public static PasswordUtil.PasswordStrength checkNewPassword(java.lang.String password)
password -
public static java.lang.String getMD5(java.lang.String secret)
throws java.security.NoSuchAlgorithmException
secret -
java.security.NoSuchAlgorithmException
public static boolean compareSecrets(java.lang.String secret,
java.lang.String md5Hash)
throws java.security.NoSuchAlgorithmException
secret - the secret to checkmd5Hash - the existing md5
java.security.NoSuchAlgorithmException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||