Valerio Setti | 1a58e9a | 2024-02-29 16:14:29 +0100 | [diff] [blame] | 1 | /** \file psa_crypto_stubs.c |
| 2 | * |
| 3 | * \brief Stub functions when MBEDTLS_PSA_CRYPTO_CLIENT is enabled but |
| 4 | * MBEDTLS_PSA_CRYPTO_C is disabled. |
| 5 | */ |
| 6 | |
| 7 | /* |
| 8 | * Copyright The Mbed TLS Contributors |
| 9 | * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later |
| 10 | */ |
| 11 | |
| 12 | #include <psa/crypto.h> |
| 13 | |
| 14 | #if defined(MBEDTLS_PSA_CRYPTO_CLIENT) && !defined(MBEDTLS_PSA_CRYPTO_C) |
| 15 | |
| 16 | psa_status_t psa_generate_random(uint8_t *output, |
| 17 | size_t output_size) |
| 18 | { |
| 19 | (void) output; |
| 20 | (void) output_size; |
| 21 | |
| 22 | return PSA_ERROR_COMMUNICATION_FAILURE; |
| 23 | } |
| 24 | |
Valerio Setti | ada2ec3 | 2024-03-01 18:04:14 +0100 | [diff] [blame^] | 25 | #endif /* MBEDTLS_PSA_CRYPTO_CLIENT && !MBEDTLS_PSA_CRYPTO_C */ |