Skip to content

Add a new top level config.h for mbedtls #2716

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

Merged
merged 1 commit into from
Sep 27, 2016

Conversation

andresag01
Copy link

@andresag01 andresag01 commented Sep 15, 2016

Description

This PR enables the possibility to use a new configuration file config-no-entropy.h recently added to mbed TLS (Mbed-TLS/mbedtls#615) that allows the subset of the library to be used when the target MCU does not implement an entropy source. To do so, a ENTROPY_SOURCE value is added to the targets that have entropy source in the target.json file. Also, the mbed TLS importer script is modified to copy a config-no-entropy.h into the mbedtls include folder.

I have assumed that all targets that define MBEDTLS_ENTROPY_HARDWARE_ALT implement an entropy source, so I have added ENTROPY_SOURCE to all of these.

Status

IN DEVELOPMENT

Migrations

NO

Related PRs

This is related to the PR Mbed-TLS/mbedtls#615 in mbed TLS.

Steps to test or reproduce

  • Update the feature mbedtls by navigating to the feature/mbedtls/importer and running the following sequence of commands:
make clean
make update
make
  • Run the tests as usual or use this version of mbed OS to build any application. Applications that use mbed TLS features that require an entropy source, but the target MCU does not offer one will fail to compile. Otherwise, the applications should work as normal.

@andresag01
Copy link
Author

@sbutcher-arm @yanesca

@sg-
Copy link
Contributor

sg- commented Sep 16, 2016

@0xc0170 we should have a hal and device attribute for RNG coming shortly. I'd suggest we then use RNG and later STORAGE to infer there is MBEDTLS_ENTROPY_HARDWARE_ALT capabilities in a device

@andresag01 andresag01 force-pushed the mbedtls_entropy_config branch from 8094dc8 to 7e814a5 Compare September 19, 2016 15:24
@andresag01 andresag01 mentioned this pull request Sep 21, 2016
2 tasks
@andresag01 andresag01 force-pushed the mbedtls_entropy_config branch 4 times, most recently from bb89793 to fe42054 Compare September 26, 2016 16:17
@andresag01 andresag01 changed the title DRAFT: Add a new top level config.h for mbedtls Add a new top level config.h for mbedtls Sep 26, 2016
@andresag01 andresag01 force-pushed the mbedtls_entropy_config branch from fe42054 to c1d5ee9 Compare September 26, 2016 16:26
@andresag01
Copy link
Author

This PR is dependent on #2765

@andresag01 andresag01 force-pushed the mbedtls_entropy_config branch from c1d5ee9 to ae6383f Compare September 27, 2016 10:29
@yanesca
Copy link
Contributor

yanesca commented Sep 27, 2016

+1

@0xc0170
Copy link
Contributor

0xc0170 commented Sep 27, 2016

Code looks good.

TRNG should land soon, this will be rebased, and will be ready for integration

@simonbutcher
Copy link
Contributor

Looks good to me.

@sg-
Copy link
Contributor

sg- commented Sep 27, 2016

@andresag01 Looks like a conflict needs to be resolved and then CI run

@andresag01 andresag01 force-pushed the mbedtls_entropy_config branch from ae6383f to 21a7b1d Compare September 27, 2016 15:19
@andresag01
Copy link
Author

@sg- @0xc0170: Rebased changes on top of master

@mazimkhan
Copy link

retest uvisor

@0xc0170
Copy link
Contributor

0xc0170 commented Sep 27, 2016

/morph test

@mazimkhan
Copy link

retest uvisor

1 similar comment
@mazimkhan
Copy link

retest uvisor

@sg- sg- added the needs: CI label Sep 27, 2016
@sg- sg- removed the needs: work label Sep 27, 2016
@mbed-bot
Copy link

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph test

Output

mbed Build Number: 965

All builds and test passed!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants