31-8 |
RESERVED |
R |
0x0 |
|
7 |
HMAC_OUTER_HASH |
R/W |
0x0 |
HMAC Outer Hash Processing Enable.
This bit is written to indicate that the outer hash should be performed on the hash digest when the inner hash has finished.
The inner hash finishes when the length of hash has been processed the final inner hash is performed (if CLOSE_HASH was set to 1).
This bit should normally be set together with CLOSE_HASH to finish the inner hash first, or immediately when block length is zero (HMAC continue with the just outer hash to be done).
This bit is auto-cleared when outer hash is finished.
0x0 = No operation
0x1 = Enable HMAC processing of outer hash.This bit self-clears when outer hash is finished.
|
6 |
RESERVED |
R |
0x0 |
|
5 |
HMAC_KEY_PROC |
R/W |
0x0 |
HMAC Key Processing Enable.
This bit enables HMAC key processing on the
512-bit HMAC key loaded into the SHA_IDIGEST_A through SHA_IDIGEST_H registers and the SHA_ODIGEST_A through SHA_ODIGEST_H register block.
Once HMAC key processing is finished, this bit is automatically cleared and the resulting Inner and Outer digest is available in the SHA_IDIGEST_x and SHA_ODIGEST_x respectively.
After key processing is complete, regular hash processing begins until the block length is exhausted.
0x0 = No operation
0x1 = Enable HMAC key processing. This bit is automatically cleared once HMAC key processing is finished.
|
4 |
CLOSE_HASH |
R/W |
0x0 |
Performs the padding, the Hash/HMAC will be 'closed' at the end of the block, as per MD5/SHA-1/SHA-2 specification (that is, appropriate padding is added), or no padding is done, allowing the hash to be continued later.
However, if the Hash/HMAC is not closed, then the Block Length must be a multiple of 64 bytes to ensure correct operation.
Auto cleared internally when hash closed.
0x0 = No padding, hash computation can be continued.
0x1 = Last packet will be padded.
|
3 |
ALGO_CONSTANT |
R/W |
0x0 |
The initial digest register will be overwritten with the algorithm constants for the selected algorithm when hashing and the initial digest count register will be reset to 0.
This will start a normal hash operation.
When continuing an existing hash or when performing an HMAC operation, this register must be set to 0 and the intermediate/inner digest or HMAC key and digest count need to be written to the context input registers prior to writing SHA_MODE.
Auto cleared internally after first block processed.
0x0 = Use precalculated digest (from another operation)
0x1 = Use constants of the selected algorithm
|
2-0 |
ALGO |
R/W |
0x0 |
Hash Algorithm
0x0 = MD5
0x1 = reserved
0x2 = SHA-1
0x3 = reserved
0x4 = SHA-224
0x5 = reserved
0x6 = SHA-256
0x7 = reserved
|