From dd2a09a22bb787a43af8c5ab414ca13b60456aa6 Mon Sep 17 00:00:00 2001 From: Thomas Daubney Date: Wed, 15 Nov 2023 18:18:03 +0000 Subject: [PATCH] Introduce demo script for PSA hash program Signed-off-by: Thomas Daubney --- programs/psa/psa_hash_demo.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 programs/psa/psa_hash_demo.sh diff --git a/programs/psa/psa_hash_demo.sh b/programs/psa/psa_hash_demo.sh new file mode 100755 index 0000000000..a26697cfe6 --- /dev/null +++ b/programs/psa/psa_hash_demo.sh @@ -0,0 +1,20 @@ +#!/bin/sh +# +# Copyright The Mbed TLS Contributors +# SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later + +. "${0%/*}/../demo_common.sh" + +msg <<'EOF' +This program demonstrates the use of the PSA cryptography interface to +compute a SHA-256 hash of a test string using the one-shot API call +and also using the multi-part operation API. +EOF + +depends_on MBEDTLS_PSA_CRYPTO_C PSA_WANT_ALG_SHA_256 + +program="${0%/*}"/psa_hash + +"$program" + +cleanup