From 6c51207602ecb9482988c0b7829e4ff8f8550df5 Mon Sep 17 00:00:00 2001 From: David Horstmann Date: Mon, 23 Oct 2023 20:25:14 +0100 Subject: [PATCH] Add notes about configuration of poisoning tests Signed-off-by: David Horstmann --- docs/architecture/psa-shared-memory.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/architecture/psa-shared-memory.md b/docs/architecture/psa-shared-memory.md index dd2f87f2a8..874621b10d 100644 --- a/docs/architecture/psa-shared-memory.md +++ b/docs/architecture/psa-shared-memory.md @@ -539,5 +539,8 @@ psa_status_t mem_poison_psa_aead_update(psa_aead_operation_t *operation, #### Memory poisoning functions and a new testsuite +#### Configuration of poisoning tests + +Since the memory poisoning tests will require the use of interfaces specific to the sanitizers used to poison memory, they must be guarded by new config options, for example `PSA_TEST_COPYING_ASAN` and `PSA_TEST_COPYING_VALGRIND`, as well as `MBEDTLS_TEST_HOOKS`. These would be analogous to the existing `MBEDTLS_TEST_CONSTANT_FLOW_MEMSAN` and `MBEDTLS_TEST_CONSTANT_FLOW_VALGRIND`. Since they require special tooling, these options should not be enabled in either the `default` or `full` configurations. Instead, as with the constant flow testing options, they should be enabled in a new component in `all.sh` that performs the copy testing with Valgrind or ASan. ### Validation of protection by careful access