| Constructor and Description |
|---|
HMac(Digest digest)
Base constructor for one of the standard digest algorithms that the
byteLength of the algorithm is know for.
|
| Modifier and Type | Method and Description |
|---|---|
int |
doFinal(byte[] out,
int outOff)
Compute the final stage of the MAC writing the output to the out
parameter.
|
String |
getAlgorithmName()
Return the name of the algorithm the MAC implements.
|
int |
getMacSize()
Return the block size for this MAC (in bytes).
|
Digest |
getUnderlyingDigest() |
void |
init(CipherParameters params)
Initialise the MAC.
|
void |
reset()
Reset the mac generator.
|
void |
update(byte in)
add a single byte to the mac for processing.
|
void |
update(byte[] in,
int inOff,
int len) |
public HMac(Digest digest)
digest - the digest.public String getAlgorithmName()
MacgetAlgorithmName in interface Macpublic Digest getUnderlyingDigest()
public void init(CipherParameters params)
Macpublic int getMacSize()
MacgetMacSize in interface Macpublic void update(byte in)
Macpublic void update(byte[] in,
int inOff,
int len)
public int doFinal(byte[] out,
int outOff)
MacdoFinal leaves the MAC in the same state it was after the last init.
Copyright © 2015. All rights reserved.