org.promotego.logic
Class Sha1Hash

java.lang.Object
  extended by org.promotego.logic.Sha1Hash
All Implemented Interfaces:
PasswordHashTool

public class Sha1Hash
extends java.lang.Object
implements PasswordHashTool


Constructor Summary
Sha1Hash()
           
 
Method Summary
 java.lang.String hash(java.lang.String password)
          Hashes the password provided.
 boolean match(java.lang.String cryptedPassword, java.lang.String password)
          Compares the hashed password with the plain text password provided.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Sha1Hash

public Sha1Hash()
Method Detail

match

public boolean match(java.lang.String cryptedPassword,
                     java.lang.String password)
Description copied from interface: PasswordHashTool
Compares the hashed password with the plain text password provided.

Specified by:
match in interface PasswordHashTool
Parameters:
cryptedPassword - A password hashed using this mechanism.
password - A plaintext password to compare to the hashedPassword.
Returns:
True if the password matches the hashed password.

hash

public java.lang.String hash(java.lang.String password)
Description copied from interface: PasswordHashTool
Hashes the password provided.

Specified by:
hash in interface PasswordHashTool
Parameters:
password - The plaintext password to be hashed.


Copyright © 2007. All Rights Reserved.