settings_comp.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. /* settings_comp.h
  2. *
  3. * Copyright (C) 2006-2020 wolfSSL Inc.
  4. *
  5. * This file is part of wolfSSL.
  6. *
  7. * wolfSSL is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License as published by
  9. * the Free Software Foundation; either version 2 of the License, or
  10. * (at your option) any later version.
  11. *
  12. * wolfSSL is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with this program; if not, write to the Free Software
  19. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
  20. */
  21. #ifndef CTAO_CRYPT_SETTINGS_C_H
  22. #define CTAO_CRYPT_SETTINGS_C_H
  23. /* since fips overrides rsa.h map compatibility here */
  24. #if !defined(NO_RSA)
  25. #ifdef WOLFSSL_KEY_GEN
  26. #define RsaKeyToDer wc_RsaKeyToDer
  27. #endif
  28. #define RsaPrivateKeyDecode wc_RsaPrivateKeyDecode
  29. #define RsaPublicKeyDecode wc_RsaPublicKeyDecode
  30. #define RsaPublicKeyDecodeRaw wc_RsaPublicKeyDecodeRaw
  31. #endif /* have rsa and HAVE_FIPS */
  32. /* Macro redefinitions for compatibility */
  33. #ifdef HAVE_NTRU
  34. #define MakeNtruCert wc_MakeNtruCert
  35. #endif
  36. #if defined(WOLFSSL_SHA512) && !defined(CYASSL_SHA512)
  37. #define CYASSL_SHA512
  38. #endif
  39. #if defined(WOLFSSL_SHA384) && !defined(CYASSL_SHA384)
  40. #define CYASSL_SHA384
  41. #endif
  42. #if defined(WOLFSSL_LEANPSK) && !defined(CYASSL_LEANPSK)
  43. #define CYASSL_LEANPSK
  44. #endif
  45. #if defined(NO_WOLFSSL_MEMORY) && !defined(NO_CYASSL_MEMORY)
  46. #define NO_CYASSL_MEMORY
  47. #endif
  48. #if defined(WOLFSSL_KEY_GEN) && !defined(CYASSL_KEY_GEN)
  49. #define CYASSL_KEY_GEN
  50. #endif
  51. /* AES */
  52. #if defined(WOLFSSL_AES_DIRECT) && !defined(CYASSL_AES_DIRECT)
  53. #define CYASSL_AES_DIRECT
  54. #endif
  55. #if defined(WOLFSSL_AES_COUNTER) && !defined(CYASSL_AES_COUNTER)
  56. #define CYASSL_AES_COUNTER
  57. #endif
  58. /* DES */
  59. #if defined(WOLFSSL_DES_ECB) && !defined(CYASSL_DES_ECB)
  60. #define CYASSL_DES_ECB
  61. #endif
  62. #endif /* CTAO_CRYPT_SETTINGS_C_H */