CBC-MAC-DES-FIPS113 | MAC |
CBC-MAC(cipher) | MAC Construction |
String cipher
[creation/read, no default] - the name
of the block cipher on which this MAC is to be based. The algorithm
must be available as a cipher.
XCBC-MAC(cipher) | MAC Construction |
String cipher
[creation/read, no default] - the name
of the block cipher on which this MAC is to be based. The algorithm
must be available as a cipher.
HMAC(digest) | MAC Construction |
String digest
[creation/read, no default] - the name
of the Block MessageDigest on which this MAC is to be based.
MD5-MAC | MAC |
RIPEMD-128-MAC | MAC |
RIPEMD-160-MAC | MAC |
? SSL3-MAC(digest) | MAC Construction |
String digest
[creation/read, no default] - the name
of the message digest on which this MAC is to be based. Not all message
digests can necessarily be used, but at least MD5 and SHA-1 MUST be
implemented.
? Two-Track-MAC | MAC |
? UMAC16[(signedFlag,preferredEndian, l1KeyLen,outputLen,cipher)] | MAC Construction |
Note that the signed default is different from UMAC32.
String signedFlag
[creation/read, default "S"] -
"S" for signed, or "U" for unsigned.
String preferredEndian
[creation/read, default "LE"] -
"LE" for little-endian, or "BE" for big-endian.
Integer l1KeyLen
[creation/read, default 1024] - the length
of the seed (or counter) value, in bytes.
Integer outputLen
[creation/read, default 8] - the length
of the MAC output in bytes. (Note that unlike most SCAN MACs, the
output is not just a prefix of a fixed-length result.)
String cipher
[creation/read, default "Rijndael"] - the name
of the cipher on which this MAC is to be based, which MUST be
an available block cipher.
? UMAC32[(signedFlag,preferredEndian, l1KeyLen,outputLen,cipher)] | MAC Construction |
Note that the unsigned default is different from UMAC16.
String signedFlag
[creation/read, default "U"] -
"S" for signed, or "U" for unsigned.
String preferredEndian
[creation/read, default "LE"] -
"LE" for little-endian, or "BE" for big-endian.
Integer l1KeyLen
[creation/read, default 1024] - the length
of the seed (or counter) value, in bytes.
Integer outputLen
[creation/read, default 8] - the length
of the MAC output in bytes. (Note that unlike most SCAN MACs, the
output is not just a prefix of a fixed-length result.)
String cipher
[creation/read, default "Rijndael"] - the name
of the cipher on which this MAC is to be based, which MUST be
an available block cipher.
× XMACWithDigest(digest[,seedLength]) | MAC Construction |
String digest
[creation/read, no default] - the name
of the message digest on which this MAC is to be based, which MUST be
a Block MessageDigest from either the same provider, or an installed
provider.
Integer seedLength
[creation/read, default 8] - the length
of the seed (or counter) value, in bytes.
Long counter
[read/write, default null] - the current counter
value, if the XMACC variant is being used.
The index starts with its most significant bit set to 1, and all other
bits zero; it is incremented for every block. If the index reaches the
all-ones value, it wraps to 1 (i.e. missing out zero). If it exhausts all
possible values except zero, attempting to update more data will cause
an IllegalStateException
to be thrown.
Note that the index or seed is encoded in big-endian order, before converting to the internal byte order used by the hash function. I.e. if the hash function interprets words as little-endian, the effect is to always reverse the byte order of these values.
Padding of the last block is performed in the same way as for the underlying message digest.
counter
parameter to a non-null value will reset the Mac
object, and
cause the given value to be used for the current message, then incremented
for each subsequent message (i.e. in the Java mapping, the counter
parameter is incremented whenever any of the doFinal
methods
is called). If the counter reaches 2seedLength, the
Mac
object becomes invalid, and always throws an
IllegalStateException
.
When counter
is null, the seed is generated as a random
value of length seedLength
bytes.
In this case the counter
parameter remains null, and is not
incremented after a call to a doFinal
method.
Mac
object that implements this algorithm is cloned,
the cloning process MUST automatically set the counter
parameter of the clone to null.
seedLength
bytes in big-endian
order, and prepended to the MAC output.
javax.crypto.Mac
appears to work only for deterministic
MAC algorithms, which needs to be fixed by separating MAC computation from
verification, and by providing a way to initialise the seed before using
update
.
Mac
object; another is to
avoid re-using keys entirely.
× PCSWithDigest(digest) | MAC Construction |
String digest
[creation/read, no default] - the name
of the message digest on which this MAC is to be based, which MUST be
an available Block MessageDigest.
Padding of the last block is performed in the same way as for the underlying message digest.
Copyright and trademarks |