summaryrefslogtreecommitdiff
path: root/test/tpm_test/subcmd.py
diff options
context:
space:
mode:
authorVadim Sukhomlinov <sukhomlinov@google.com>2019-11-12 11:20:12 -0800
committerCommit Bot <commit-bot@chromium.org>2019-11-21 19:24:22 +0000
commit3bc0a6b273fdd8bdc5ad34e5a0c1ecc88754cfa1 (patch)
tree16808c89fb37dd2b5206edde0d2eba6aeccd4c98 /test/tpm_test/subcmd.py
parent052ed9c30e9fca104ac151920de92f8a8f76fc07 (diff)
downloadchrome-ec-3bc0a6b273fdd8bdc5ad34e5a0c1ecc88754cfa1.tar.gz
cr50: Add support for ACVP tests of HMAC SHA-256 DRBG
HMAC DRBG is used for U2F key generation, and as such is subject for ACVP tests. Expose DRBG Init, Generate and Seed commands for automated testing with externally provided test vectors. BUG=b:138578319 BRANCH=cr50 TEST=make CRYPTO_TEST=1 BOARD=cr50 -j && test/tpm_test/tpmtest.py Change-Id: I50a6750864d3cd9a304a9b8a8524ef29cec04410 Signed-off-by: Vadim Sukhomlinov <sukhomlinov@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1912662 Reviewed-by: Vadim Sukhomlinov <sukhomlinov@chromium.org> Reviewed-by: Vadim Bendebury <vbendeb@chromium.org> Tested-by: Vadim Sukhomlinov <sukhomlinov@chromium.org> Commit-Queue: Vadim Sukhomlinov <sukhomlinov@chromium.org> Auto-Submit: Vadim Sukhomlinov <sukhomlinov@chromium.org>
Diffstat (limited to 'test/tpm_test/subcmd.py')
-rw-r--r--test/tpm_test/subcmd.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/tpm_test/subcmd.py b/test/tpm_test/subcmd.py
index d6aeb6722f..7260df0dd5 100644
--- a/test/tpm_test/subcmd.py
+++ b/test/tpm_test/subcmd.py
@@ -5,7 +5,7 @@
"""Subcommand codes that specify the crypto module."""
-# Keep these codes in sync with include/extension.h.
+# Keep these codes in sync with include/tpm_vendor_cmds.h
AES = 0
HASH = 1
RSA = 2
@@ -13,7 +13,7 @@ ECC = 3
FW_UPGRADE = 4
HKDF = 5
ECIES = 6
-
+DRBG_TEST = 50
# The same exception class used by all tpmtest modules.
class TpmTestError(Exception):
pass