de.flexiprovider.core.md
Class SHA384_512
java.lang.Object
|
+--java.security.MessageDigestSpi
|
+--de.flexiprovider.api.MessageDigest
|
+--de.flexiprovider.core.md.SHA384_512
- Direct Known Subclasses:
- SHA384, SHA512
- public abstract class SHA384_512
- extends MessageDigest
Abstract class for SHA message digests operating on 64 bit words (SHA-384 and
SHA-512).
- Author:
- Ralf-P. Weinmann
|
Constructor Summary |
protected |
SHA384_512(int digestLength)
Constructor. |
|
Method Summary |
byte[] |
digest()
Completes the hash computation by performing final operations such as
padding. |
int |
getDigestLength()
|
protected void |
initMessageDigest(long[] initialState)
Initialize the message digest with an initial state. |
void |
update(byte input)
Update the digest using the specified input byte. |
void |
update(byte[] input,
int inOff,
int inLen)
Update the digest using the specified input byte array. |
| Methods inherited from class java.security.MessageDigestSpi |
clone, engineDigest |
| Methods inherited from class java.lang.Object |
, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SHA384_512
protected SHA384_512(int digestLength)
- Constructor.
- Parameters:
digestLength - the digest length
initMessageDigest
protected void initMessageDigest(long[] initialState)
- Initialize the message digest with an initial state.
- Parameters:
initialState - the initial state
getDigestLength
public int getDigestLength()
- Overrides:
getDigestLength in class MessageDigest
- Returns:
- the digest length in bytes
update
public void update(byte input)
- Update the digest using the specified input byte.
- Overrides:
update in class MessageDigest
- Parameters:
input - the input byte
update
public void update(byte[] input,
int inOff,
int inLen)
- Update the digest using the specified input byte array.
- Overrides:
update in class MessageDigest
- Parameters:
input - the inputinOff - the offset where the input startsinLen - the input length
digest
public byte[] digest()
- Completes the hash computation by performing final operations such as
padding.
- Overrides:
digest in class MessageDigest
- Returns:
- the digest value