Update TROPIC01 integration guide and header file for key slot definitions and datasheet link

pull/8812/head
Maxim Kostin 2025-06-16 21:12:19 +02:00
parent cafb1f5fd7
commit 037ccbaa05
2 changed files with 27 additions and 16 deletions

View File

@ -23,7 +23,7 @@ Integration guide for using Tropic Square's TROPIC01 secure element with wolfSSL
## TROPIC01 Secure Element with an open architecture
The TROPIC01 secure element is built with tamper-proof technology and advanced attack countermeasures to ensure robust asset protection, securing electronic devices against a wide range of potential attacks. It securely supplies and stores the cryptographic keys of embedded solutions.
The TROPIC01 datasheet is available via [this link](https://www.nxp.com/docs/en/application-note/AN12570.pdf)
The TROPIC01 datasheet is available via [this link](https://github.com/tropicsquare/tropic01/blob/main/doc/datasheet/ODD_tropic01_datasheet_revA6.pdf)
## Hardware Overview
@ -71,15 +71,16 @@ Also, for Raspberry PI, there are a few more steps:
2. Install wiringPI:
```sh
$ sudo apt update
$ sudo apt install wiringpi
$ wget https://github.com/WiringPi/WiringPi/releases/download/3.14/wiringpi_3.14_arm64.deb
$ sudo apt install ./wiringpi_3.14_arm64.deb
```
### Keys installation
For the integration with wolfSSL, there are a few pre-defined slots for the secure keys storage (the slots mapping might be changed in tropic01.h):
```sh
TROPIC01_AES_RMEM_SLOT_DEFAULT 1 // slot in R-memory for AES key
TROPIC01_AES_KEY_RMEM_SLOT 0 // slot in R-memory for AES key
TROPIC01_AES_IV_RMEM_SLOT 1 // slot in R-memory for AES IV
TROPIC01_ED25519_PUB_RMEM_SLOT_DEFAULT 2 // slot in R-memory for ED25519 Public key
TROPIC01_ED25519_PRIV_RMEM_SLOT_DEFAULT 3 //slot in R-memory for ED25519 Private key
TROPIC01_ED25519_ECC_SLOT_DEFAULT 1 // slot in ECC keys storage for both public and private keys

View File

@ -50,23 +50,34 @@
#define TROPIC01_AES_MAX_KEY_SIZE 32
/* R-Memory slots allocation */
#define TROPIC01_AES_KEY_RMEM_SLOT 0
#define TROPIC01_AES_IV_RMEM_SLOT 1
#define TROPIC01_ED25519_PUB_RMEM_SLOT_DEFAULT 2
#define TROPIC01_ED25519_PRIV_RMEM_SLOT_DEFAULT 3
#define TROPIC01_PAIRING_KEY_SIZE 32
#define TROPIC01_ED25519_PRIV_KEY_SIZE 32
#define TROPIC01_ED25519_PUB_KEY_SIZE 32
/* R-Memory slots allocation */
#ifndef TROPIC01_AES_KEY_RMEM_SLOT
#define TROPIC01_AES_KEY_RMEM_SLOT 0
#endif /* TROPIC01_AES_KEY_RMEM_SLOT */
#ifndef TROPIC01_AES_IV_RMEM_SLOT
#define TROPIC01_AES_IV_RMEM_SLOT 1
#endif /* TROPIC01_AES_IV_RMEM_SLOT */
#ifndef TROPIC01_ED25519_PUB_RMEM_SLOT_DEFAULT
#define TROPIC01_ED25519_PUB_RMEM_SLOT_DEFAULT 2
#endif /* TROPIC01_ED25519_PUB_RMEM_SLOT_DEFAULT */
#ifndef TROPIC01_ED25519_PRIV_RMEM_SLOT_DEFAULT
#define TROPIC01_ED25519_PRIV_RMEM_SLOT_DEFAULT 3
#endif /* TROPIC01_ED25519_PRIV_RMEM_SLOT_DEFAULT */
#ifndef TROPIC01_ED25519_ECC_SLOT_DEFAULT
#define TROPIC01_ED25519_ECC_SLOT_DEFAULT 1
#endif /* TROPIC01_ED25519_ECC_SLOT_DEFAULT */
#ifndef PAIRING_KEY_SLOT_INDEX_0
#define PAIRING_KEY_SLOT_INDEX_0 0
#define TROPIC01_PAIRING_KEY_SIZE 32
#endif /* PAIRING_KEY_SLOT_INDEX_0 */
typedef struct {
int keySlot; /* Slot ID in TROPIC01 secure memory */
@ -78,7 +89,6 @@ typedef struct {
/* Context for TROPIC01 secure element */
typedef struct {
int initialized;
byte keySlotUsage[8];
} Tropic01CryptoDevCtx;