763ffdd2a6
The following shell command (requiring GNU grep) looks for algorithms and key types, as well as IS and GET macros, that lack metadata tests: ``` for x in $(grep -Pho '(?<=^#define )PSA_(ALG|KEY_TYPE)_(?!CATEGORY_|NONE\b|\w+_(BASE|FLAG|MASK|CASE))\w+' include/psa/crypto_values.h include/psa/crypto_extra.h); do grep -qw $x tests/suites/test_suite_psa_crypto_metadata.* || echo $x; done ``` This may have false negatives: it only checks that the constants are mentioned at least once, not that the tests are written correctly. This has false positives: * Types and algorithms that Mbed TLS does not support. * PSA_ALG_ECDSA_IS_DETERMINISTIC, PSA_ALG_DSA_IS_DETERMINISTIC are peculiar auxiliary macros that only apply to very specific algorithms and aren't tested like the other IS macros. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com> |
||
---|---|---|
.. | ||
.jenkins | ||
configs | ||
data_files | ||
docker/bionic | ||
git-scripts | ||
include | ||
opt-testcases | ||
scripts | ||
src | ||
suites | ||
.gitignore | ||
CMakeLists.txt | ||
compat-in-docker.sh | ||
compat.sh | ||
context-info.sh | ||
Descriptions.txt | ||
make-in-docker.sh | ||
Makefile | ||
ssl-opt-in-docker.sh | ||
ssl-opt.sh |