org.apache.shiro.crypto.hash
Class Sha384Hash

java.lang.Object
  extended by org.apache.shiro.codec.CodecSupport
      extended by org.apache.shiro.crypto.hash.AbstractHash
          extended by org.apache.shiro.crypto.hash.Sha384Hash
All Implemented Interfaces:
Serializable, Hash

public class Sha384Hash
extends AbstractHash

Generates an SHA-384 Hash from a given input source with an optional salt and hash iterations.

See the AbstractHash parent class JavaDoc for a detailed explanation of Hashing techniques and how the overloaded constructors function.

JDK Version Note - Attempting to instantiate this class on JREs prior to version 1.4.0 will throw an IllegalStateException

Since:
0.9
Author:
Les Hazlewood
See Also:
Serialized Form

Field Summary
static String ALGORITHM_NAME
           
 
Fields inherited from class org.apache.shiro.codec.CodecSupport
PREFERRED_ENCODING
 
Constructor Summary
Sha384Hash()
           
Sha384Hash(Object source)
           
Sha384Hash(Object source, Object salt)
           
Sha384Hash(Object source, Object salt, int hashIterations)
           
 
Method Summary
static Sha384Hash fromBase64String(String base64)
           
static Sha384Hash fromHexString(String hex)
           
protected  String getAlgorithmName()
          Implemented by subclasses, this specifies the name of the MessageDigest algorithm to use when performing the hash.
 
Methods inherited from class org.apache.shiro.crypto.hash.AbstractHash
equals, getBytes, getDigest, hash, hash, hash, hashCode, setBytes, toBase64, toHex, toString
 
Methods inherited from class org.apache.shiro.codec.CodecSupport
isByteSource, objectToBytes, objectToString, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toChars, toChars, toString, toString, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ALGORITHM_NAME

public static final String ALGORITHM_NAME
See Also:
Constant Field Values
Constructor Detail

Sha384Hash

public Sha384Hash()

Sha384Hash

public Sha384Hash(Object source)

Sha384Hash

public Sha384Hash(Object source,
                  Object salt)

Sha384Hash

public Sha384Hash(Object source,
                  Object salt,
                  int hashIterations)
Method Detail

getAlgorithmName

protected String getAlgorithmName()
Description copied from class: AbstractHash
Implemented by subclasses, this specifies the name of the MessageDigest algorithm to use when performing the hash.

Specified by:
getAlgorithmName in class AbstractHash
Returns:
the MessageDigest algorithm to use when performing the hash.

fromHexString

public static Sha384Hash fromHexString(String hex)

fromBase64String

public static Sha384Hash fromBase64String(String base64)


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.