-
Notifications
You must be signed in to change notification settings - Fork 96
Break non-crypto dependencies #74
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
Break non-crypto dependencies #74
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two major issues (#74 (comment) and #74 (comment)) and a couple of suggestions.
503e1d6
to
7c36f6a
Compare
Rebased to address review feedback in original commits. More rebasing expected before this is ready to review again. Previous branch at https://github.com/Patater/mbed-crypto/tree/break-non-crypto-dependencies-1 |
7c36f6a
to
bf5082b
Compare
Rebased to ignore |
I'm removing the oid and X.509 detangling commits as well, since we can get those from Mbed TLS development once merged there. |
bf5082b
to
e92caf9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks ok except for inconsistencies about which calls to SSL test scripts are removed and which aren't.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only have a single, minor remark, otherwise, provided that Gilles' remarks will be addressed, I approve the changes.
* function equivalent to the function with the same name | ||
* This only applies to functions whose documentation mentions | ||
* they may return #MBEDTLS_ERR_ECP_IN_PROGRESS (or | ||
* `MBEDTLS_ERR_SSL_CRYPTO_IN_PROGRESS` for functions in the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor: MBEDLTS_ERR_SL_CRYPTO_IN_PROGRESS
is back quoted here, but not elsewhere, e.g. in config.h
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The commit is only to remove the dependency in the ecp module. A later commit that removes SSL options from config.h will take care to update other references.
Windows CI has failed in the "shipped build". I'm investigating and working on a fix. |
e92caf9
to
bb60169
Compare
Rebased to address feedback and hopefully fix the Windows build. |
bb60169
to
27e5907
Compare
Force push to update visualc files... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving 27e5907
This needs a rebase to resolve conflicts, plus CI and re-review. |
This makes it easier to add or remove programs as well as see which programs were added or removed in diffs.
Our default configuration file, include/mbedtls/config.h, should always match configs/config-psa-crypto.h. It had gotten out of sync, so put it back into sync.
Doxygen will fail to build if we have references to files that don't exist. Since we are planning on removing X.509 soon, we even need to remove explicit Doxygen references to X.509 things as those will no longer resolve once the X.509 files are deleted. fixup! asn1: Remove dependency on X.509
As the SSL programs, like ssl_client2 and ssl_server2, are dependent on SSL and therefore about to be removed, the only consumer of query_config is the query_compile_time_config test. As such, it makes sense to move query_config to be next to what uses it.
platform.h should only be used internally by the library implementation itself, not the examples. Remove the dependency on platform.h from all PSA programs.
For Makefiles, enable overriding where includes can come from in order to enable the parent module to set the include path. This allows the parent module to specify that its config.h should be used, even when the submodule when built standalone would use a different config.h. For CMake, always look in the parent's include folder and our own. List the parent's include folder first, so that preference is given to parent include files.
The version test suite is duplicated between Mbed TLS and Mbed Crypto. Use TLS's copy and not Crypto's copy when Crypto is used as a submodule of TLS. The version test is the only test that is tested from both TLS and Crypto, despite being entirely in libmbedcrypto. This is because the test data is code-gen'd from the version updating script and the version between Mbed TLS and Mbed Crypto don't necessarily always agree. The test data must come from the top level module, as only the top level module will have test data that matches the expected version.
Prepend ".crypto" to tests that came from the crypto submodule. This allows, when this project is used as a submodule, for tests with names the same between the parent and this project when used as a submodule to both be built and run.
27e5907
to
b478bb6
Compare
Rebased to latest crypto/development to resolve conflicts. Previous branch at https://github.com/Patater/mbed-crypto/tree/break-non-crypto-dependencies-12.5. No changes other than conflict resolution. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CI failures are due to a test script that calls |
Retested after merging Mbed-TLS/mbedtls-test#56 and all is good. |
This is a portion of #71
The goal is only to break dependencies on TLS and X.509 and NET, without removing those modules yet.