Class BCMessageDigest
- java.lang.Object
-
- java.security.MessageDigestSpi
-
- java.security.MessageDigest
-
- org.bouncycastle.jcajce.provider.digest.BCMessageDigest
-
- Direct Known Subclasses:
MD5.Digest,SHA1.Digest,SHA224.Digest,SHA256.Digest,SHA384.Digest,SHA512.Digest
public class BCMessageDigest extends MessageDigest
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedBCMessageDigest(Digest digest)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]engineDigest()Computes and returns the final hash value for thisMessageDigestSpi.voidengineReset()Puts thisMessageDigestSpiback in an initial state, such that it is ready to compute a one way hash value.voidengineUpdate(byte input)Updates thisMessageDigestSpiusing the givenbyte.voidengineUpdate(byte[] input, int offset, int len)Updates thisMessageDigestSpiusing the givenbyte[].-
Methods inherited from class java.security.MessageDigest
digest, digest, digest, getAlgorithm, getDigestLength, getInstance, getInstance, getInstance, getProvider, isEqual, reset, toString, update, update, update, update
-
Methods inherited from class java.security.MessageDigestSpi
clone, engineDigest, engineGetDigestLength, engineUpdate
-
-
-
-
Field Detail
-
digest
protected Digest digest
-
-
Constructor Detail
-
BCMessageDigest
protected BCMessageDigest(Digest digest)
-
-
Method Detail
-
engineReset
public void engineReset()
Description copied from class:MessageDigestSpiPuts thisMessageDigestSpiback in an initial state, such that it is ready to compute a one way hash value.- Specified by:
engineResetin classMessageDigestSpi
-
engineUpdate
public void engineUpdate(byte input)
Description copied from class:MessageDigestSpiUpdates thisMessageDigestSpiusing the givenbyte.- Specified by:
engineUpdatein classMessageDigestSpi- Parameters:
input- thebyteto update thisMessageDigestSpiwith.- See Also:
MessageDigestSpi.engineReset()
-
engineUpdate
public void engineUpdate(byte[] input, int offset, int len)Description copied from class:MessageDigestSpiUpdates thisMessageDigestSpiusing the givenbyte[].- Specified by:
engineUpdatein classMessageDigestSpi- Parameters:
input- thebytearray.offset- the index of the first byte ininputto update from.len- the number of bytes ininputto update from.
-
engineDigest
public byte[] engineDigest()
Description copied from class:MessageDigestSpiComputes and returns the final hash value for thisMessageDigestSpi. After the digest is computed the receiver is reset.- Specified by:
engineDigestin classMessageDigestSpi- Returns:
- the computed one way hash value.
- See Also:
MessageDigestSpi.engineReset()
-
-