|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.jguard.authentication.CryptUtils
public class CryptUtils
this class is done originally by andy tagish, with his great jaas modules. you can reach it on his website the licence of the code provided by andy tagish is also the LGPL. this class is loaded by the application server classloader.
| Field Summary | |
|---|---|
static java.lang.String |
NONE_ALGORITHM
|
static char[] |
salt
|
| Constructor Summary | |
|---|---|
CryptUtils()
|
|
| Method Summary | |
|---|---|
static char[] |
cryptPassword(char[] pwd)
Perform message digest hashing on the supplied password and return a char array containing the encrypted password as a printable string. |
static java.lang.String |
getDigestAlgorithm()
|
static char[] |
getSalt()
|
static void |
setDigestAlgorithm(java.lang.String algorithm)
set the message digest algorithm. |
static boolean |
setSalt(char[] saltCandidate)
|
static void |
smudge(byte[] pwd)
Zero the contents of the specified array. |
static void |
smudge(char[] pwd)
Zero the contents of the specified array. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String NONE_ALGORITHM
public static char[] salt
| Constructor Detail |
|---|
public CryptUtils()
| Method Detail |
|---|
public static void smudge(char[] pwd)
pwd - the array to zeropublic static void smudge(byte[] pwd)
pwd - the array to zero
public static char[] cryptPassword(char[] pwd)
throws java.security.NoSuchAlgorithmException
pwd - The password to encrypt
java.security.NoSuchAlgorithmExceptionpublic static java.lang.String getDigestAlgorithm()
public static void setDigestAlgorithm(java.lang.String algorithm)
throws java.security.NoSuchAlgorithmException
string -
java.security.NoSuchAlgorithmExceptionpublic static boolean setSalt(char[] saltCandidate)
public static char[] getSalt()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||