You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -9,7 +9,9 @@ Support for the STM32 PKA on WB55, H7, MP13 and other devices with on-board
9
9
public-key acceleration:
10
10
- ECC192/ECC224/ECC256/ECC384
11
11
12
-
Support for the STSAFE-A100 crypto hardware accelerator co-processor via I2C for ECC supporting NIST or Brainpool 256-bit and 384-bit curves. It requires the ST-Safe SDK including wolfSSL's `stsafe_interface.c/.h` files. Please contact us at support@wolfssl.com to get this code.
12
+
Support for the STSAFE-A secure element family via I2C for ECC supporting NIST P-256/P-384 and Brainpool 256/384-bit curves:
13
+
-**STSAFE-A100/A110**: Uses ST's proprietary STSAFE-A1xx middleware. Contact us at support@wolfssl.com for integration assistance.
For details see our [wolfSSL ST](https://www.wolfssl.com/docs/stm32/) page.
@@ -65,50 +67,201 @@ To enable support define the following
65
67
66
68
When the support is enabled, the ECC operations will be accelerated using the PKA crypto co-processor.
67
69
68
-
## STSAFE-A100 ECC Acceleration
70
+
## STSAFE-A ECC Acceleration
69
71
70
-
Using the wolfSSL PK callbacks and the reference ST Safe reference API's we support an ECC only cipher suite such as ECDHE-ECDSA-AES128-SHA256 for TLS client or server.
72
+
Using the wolfSSL PK callbacks or Crypto callbacks with the ST-Safe reference API's we support ECC operations for TLS client/server:
73
+
-**ECDSA Sign/Verify**: P-256 and P-384 (NIST and Brainpool curves)
74
+
-**ECDH Key Agreement**: For TLS key exchange
75
+
-**ECC Key Generation**: Ephemeral keys for TLS
71
76
72
-
At the wolfCrypt level we also support ECC native API's for `wc_ecc_*` using the ST-Safe.
77
+
At the wolfCrypt level we also support ECC native API's for `wc_ecc_*` using the ST-Safe via Crypto Callbacks.
78
+
79
+
### Supported Hardware
80
+
81
+
| Model | Macro | SDK |
82
+
|-------|-------|-----|
83
+
| STSAFE-A100/A110 |`WOLFSSL_STSAFEA100`| ST STSAFE-A1xx Middleware (proprietary) |
84
+
| STSAFE-A120 |`WOLFSSL_STSAFEA120`|[STSELib](https://github.com/STMicroelectronics/STSELib) (BSD-3, open source) |
The STSAFE support is self-contained in `wolfcrypt/src/port/st/stsafe.c` with SDK-specific implementations selected at compile time:
172
+
173
+
| Macro | SDK | Description |
174
+
|-------|-----|-------------|
175
+
|`WOLFSSL_STSAFEA100`| STSAFE-A1xx Middleware | ST's proprietary SDK for A100/A110 |
176
+
|`WOLFSSL_STSAFEA120`|[STSELib](https://github.com/STMicroelectronics/STSELib)| ST's open-source SDK for A120 (BSD-3) |
177
+
178
+
#### External Interface (Backwards Compatibility)
179
+
180
+
For customers with existing custom implementations, define `WOLFSSL_STSAFE_INTERFACE_EXTERNAL` to use an external `stsafe_interface.h` file instead of the built-in implementation:
181
+
182
+
```c
183
+
#defineWOLFSSL_STSAFEA100 /* or WOLFSSL_STSAFEA120 */
184
+
#define WOLFSSL_STSAFE_INTERFACE_EXTERNAL
185
+
```
186
+
187
+
When `WOLFSSL_STSAFE_INTERFACE_EXTERNAL` is defined, the customer must provide a `stsafe_interface.h` header that defines:
188
+
189
+
| Item | Type | Description |
190
+
|------|------|-------------|
191
+
| `stsafe_curve_id_t` | typedef | Curve identifier type |
192
+
| `stsafe_slot_t` | typedef | Key slot identifier type |
193
+
| `STSAFE_ECC_CURVE_P256` | macro | P-256 curve ID value |
194
+
| `STSAFE_ECC_CURVE_P384` | macro | P-384 curve ID value |
0 commit comments