Support committed generated test data and generate PQCP test data#278
Conversation
bjwtaylor
left a comment
There was a problem hiding this comment.
Not had time to do a full review, however added a couple of initial comments/questions.
|
Since #265 has been merged, you might rebase this PR so that we can get it merged and unlock Mbed-TLS/TF-PSA-Crypto#690 as well ;) |
|
Oh, I hadn't rebased because there was no conflict, but now there is one! Ronald and I simultaneously created a file with the same name... I'll rework this then. |
664d22c to
8b37b49
Compare
Create a directory for scripts that are useful to maintainers, and may be invoked as part of the CI, but are not part of the normal build. These scripts may require a recent Python version and may require additional third-party modules, unlike user-facing scripts where we try to minimize requirements. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
A new utility to give a common interface to committed generated files. For the time being, this module is only intended for committed generated files, and `make_generated_files_common.py` is only intended for non-committed generated files. The two may be unified at some point in the future. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
As part of a long-term unification effort of generation scripts, add an option for test generators to list oudated targets without writing to files. This corresponds to functionality that the new generate_files_helper module offers. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Support check and always-update mode. Update-if-needed mode falls back to always-update mode because test_data_generation.py doesn't support update-if-needed. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Generate some basic test cases for the mldsa-native functions. Uses `dilithium_py` from https://github.com/GiacomoPope/dilithium-py (`pip install dilithium-py`), which requires Python >=3.9. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
8b37b49 to
c88127f
Compare
|
I've rebased on top of the merge of #265. I also renamed |
mpg
left a comment
There was a problem hiding this comment.
(Taking over from Ben as a reviewer while he's away.)
Looking pretty good to me. Just a minor point that can be ignored, and a question that's probably just me missing something but I'd still like it answered before I formally approve.
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Tests using randomized signatures were currently randomized. We need the output of the script to be reproducible, so this won't do. Force randomized signatures to use a specific RNG which is reset before constructing each test case. This way, the script's output is reproducible. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
framework/util, according to the design proposed in Design proposal: split user-invoked from CI-invoked Python scripts #272.Framework part of Mbed-TLS/TF-PSA-Crypto#690.
PR checklist
Please add the numbers (or links) of the associated pull requests for consuming branches. You can omit branches where this pull request is not needed.