EasyManua.ls Logo

Semtech LR1110 - LR1110 Crypto Commands; LR1110 CryptoSetKey Command

Semtech LR1110
130 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
LR1110
User Manual Rev.1.0
UM.LR1110.W.APP March 2020
107 of 130
Semtech
www.semtech.com
12.3 Commands
12.3.1 CEStatus
The Crypto Status Byte CEStatus indicates the state Crypto Engine. It is returned after each command invoking the Crypto
Engine.
CEStatus:
0: CRYP_API_SUCCESS. The previous command was successful.
1: CRYP_API_FAIL_CMAC. MIC (first 4 bytes of the CMAC) comparison failed.
2: RFU.
3: CRYP_API_INV_KEY_ID. Key/Param Source or Destination ID error
4: RFU.
5: CRYP_API_BUF_SIZE. Data buffer size is invalid. For the CryptoAesEncrypt( ), the command the buffer size must be
multiple of 16 Bytes.
6: CRYP_API_ERROR. Any other error.
12.3.2 CryptoSetKey
The command CryptoSetKey( ) sets a specific Key identified by KeyID into the Crypto Engine:
KeyID goes from 1 to 27, as defined in Table 12-1: Cryptographic Keys Usage and Derivation. KeyID 0 is blocked by
device internal firmware to avoid overwriting the pre-provisioned keys.
Key is an array of bytes as defined in the FIPS-197. With the key K (2b7e1516 28aed2a6abf71588 09cf4f3c) provided in
test vectors of the rfc4493 we then have Key1 = 0x2b, Key2 = 0x7e, Key3 = 0x15, Key4 = 0x16 , ... , Key16 = 0x3c.
CEStatus is defined in section CEStatus on page 107.
Table 12-2: CryptoSetKey Command
Byte 0 1 2 3 4 5 18
Data from Host 0x05 0x02 KeyID (7:0) Key1 Key2 Key3 Key16
Data to Host Stat1 Stat2
IrqStatus
(31:24)
IrqStatus
(23:16)
IrqStatus
(15:8)
IrqStatus
(7:0)
0x00
Table 12-3: CryptoSetKey Response
Byte 0 1
Data from Host 0x00 0x00
Data to Host Stat1 CEStatus

Table of Contents