|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.aselect.authspserver.authsp.db.MD5Crypt
public class MD5Crypt
A Java Implementation of the MD5Crypt function Modified from the GANYMEDE network directory management system released under the GNU General Public License by the University of Texas at Austin http://tools.arlut.utexas.edu/gash2/ Original version from :Jonathan Abbey, jonabbey@arlut.utexas.edu Modified by: Vladimir Silva, vladimir_silva@yahoo.com Modification history: 9/2005 - Removed dependencies on a MD5 private implementation - Added built-in java.security.MessageDigest (MD5) support - Code cleanup
Constructor Summary | |
---|---|
MD5Crypt()
|
Method Summary | |
---|---|
static java.lang.String |
crypt(java.lang.String password)
LINUX/BSD MD5Crypt function |
static java.lang.String |
crypt(java.lang.String password,
java.lang.String salt)
LINUX/BSD MD5Crypt function |
static java.lang.String |
crypt(java.lang.String password,
java.lang.String salt,
java.lang.String magic)
Linux/BSD MD5Crypt function |
static void |
main(java.lang.String[] args)
|
static boolean |
matches(java.lang.String encryptedPassword,
java.lang.String enteredPassword)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MD5Crypt()
Method Detail |
---|
public static final java.lang.String crypt(java.lang.String password)
password
- Password to be encrypted
public static final java.lang.String crypt(java.lang.String password, java.lang.String salt)
salt
- Random string used to initialize the MD5 enginepassword
- Password to be encrypted
public static final java.lang.String crypt(java.lang.String password, java.lang.String salt, java.lang.String magic)
magic
- $1$ for Linux/BSB, $apr1$ for Apache cryptsalt
- 8 byte permutation stringpassword
- user password
java.lang.Exception
public static final boolean matches(java.lang.String encryptedPassword, java.lang.String enteredPassword)
public static void main(java.lang.String[] args)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |