Skip to content

Update to Mbed Crypto v2.0.0 #38

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

Closed
ionut-arm opened this issue Oct 11, 2019 · 3 comments · Fixed by #56
Closed

Update to Mbed Crypto v2.0.0 #38

ionut-arm opened this issue Oct 11, 2019 · 3 comments · Fixed by #56
Assignees
Labels
enhancement New feature or request

Comments

@ionut-arm
Copy link
Member

We're currently using Mbed Crypto 1.1.0 which exposed an old version of PSA Crypto API.

After the interface work is done, we should update the version of mbed we pull to 2.0.0 and modify the way we create and handle keys (where necessary).

Changes that will probably be needed:

  • Updating the way Mbed Provider handles key creation (as per the new PSA spec)
  • Updating the way we deal with key lifetimes (deciding how this will be handled is WIP)
  • Adding permit_copy as a flag for key attributes

If providers will be forced to only support one key lifetime, a new issue shall be raised.

@ionut-arm ionut-arm added the enhancement New feature or request label Oct 11, 2019
@ionut-arm
Copy link
Member Author

This will also open up the possibility of changing the storage path of keys by defining PSA_ITS_STORAGE_PREFIX at compile time: https://github.com/ARMmbed/mbed-crypto/blob/development/library/psa_its_file.c#L48

@ionut-arm
Copy link
Member Author

Based on the work done in #52, there is no intention to make the current mbed provider work with volatile keys.

A new/joint provider that will only work with such keys will be created at some point, but we'll have a new issue for that.

@ionut-arm
Copy link
Member Author

We're going to find a workaround for a shortcoming in bindgen: rust-lang/rust-bindgen#1344

Most of the functions for populating key attributes structures are defined as static inline. So we either have to populate things by hand or write our own FFI wrappers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants