RM0082
AS_Cryptographic co-processor (C3)
Doc ID 018672 Rev 1
399/844
Bits 15 to 0 in the first instruction word (cccc in
) represent the Count in Bytes of
the input message.
Note:
The state of the HASH channel should be saved after an HMAC-APPEND instruction, if a
consecutive HMAC-APPEND instruction is to be executed. The consecutive APPEND
instruction should be executed after restoring the previously saved state of the channel. If
this process is not followed, the HASH channel will not respond to any further instructions as
it will become non-operational.
21.11.15 END
The HMAC [MD5/SHA1] END instruction is 3 words long. This instruction is used to set the
Source Address Register for the HMAC key and the Destination Address Register for the
HMAC and to end the computation of the HMAC.
The second word represents the Source Address for the key, while the third word represents
the Destination Address for the HMAC.
Bits ‘aa’ in the above table are used to set the algorithm to use and have the same encoding
as in the INIT instruction (
Bits 15 to 0 in the first instruction word (cccc in
) represent the length in Bytes of
the key.
Bit ‘t’ in the above table is used to truncate the result to 96 bits.
21.11.16 HMAC CONTEXT instruction
The HMAC CONTEXT instruction is composed by 2 sub-instructions:
●
SAVE
●
RESTORE
21.11.17 SAVE
The HMAC CONTEXT SAVE instruction is 2 words long. This instruction is used to set the
Destination Address Register for the context and to save the full context.
The second word represents the Destination Address for the context.
Table 340.
HMAC END Instruction bit encoding
W#
Bit Encoding
1
xxxx 101a a10tx xxxx cccc cccc cccc cccc
2
32 bit Source Address for the key
3
32 bit Destination Address for the message
Bit 20
t
Truncate
1’b0
Full HMAC
1’b1
Truncated 96 bit HMAC