md_psa.h 657 B

1234567891011121314151617181920212223242526
  1. /**
  2. * Translation between MD and PSA identifiers (algorithms, errors).
  3. *
  4. * Note: this internal module will go away when everything becomes based on
  5. * PSA Crypto; it is a helper for the transition period.
  6. *
  7. * Copyright The Mbed TLS Contributors
  8. * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
  9. */
  10. #ifndef MBEDTLS_MD_PSA_H
  11. #define MBEDTLS_MD_PSA_H
  12. #include "common.h"
  13. #include "mbedtls/md.h"
  14. #include "psa/crypto.h"
  15. /** Convert PSA status to MD error code.
  16. *
  17. * \param status PSA status.
  18. *
  19. * \return The corresponding MD error code,
  20. */
  21. int mbedtls_md_error_from_psa(psa_status_t status);
  22. #endif /* MBEDTLS_MD_PSA_H */