Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make mbedtls_psa_register_se_key usable with opaque drivers #9255

Open
gilles-peskine-arm opened this issue Jun 13, 2024 · 0 comments
Open
Labels
api-break This issue/PR breaks the API and must wait for a new major version component-psa PSA keystore/dispatch layer (storage, drivers, …) enhancement size-s Estimated task size: small (~2d)

Comments

@gilles-peskine-arm
Copy link
Contributor

The function mbedtls_psa_register_se_key creates a PSA key object that is backed by a secure element. It is currently only implemented only for dynamic secure element drivers (the feature enabled by MBEDTLS_PSA_CRYPTO_SE_C), which are going away in TF-PSA-Crypto 1.0 (i.e. Mbed TLS 4.0). But it would be useful for the new kind of opaque drivers too. It needs a new interface for that, to specify the key material (with dynamic secure elements, that comes from the slot_number parameter in the attributes).

We'll want to fix #9254 while we're at it. Thus the new prototype should probably be:

int mbedtls_psa_register_se_key(
    const psa_key_attributes_t *attributes,
    const uint8_t *data, size_t data_length,
    mbedtls_svc_key_id_t *key_id);
@gilles-peskine-arm gilles-peskine-arm added enhancement component-psa PSA keystore/dispatch layer (storage, drivers, …) api-break This issue/PR breaks the API and must wait for a new major version size-s Estimated task size: small (~2d) labels Jun 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api-break This issue/PR breaks the API and must wait for a new major version component-psa PSA keystore/dispatch layer (storage, drivers, …) enhancement size-s Estimated task size: small (~2d)
Projects
None yet
Development

No branches or pull requests

1 participant