user_settings.h 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. #ifndef _WIN_USER_SETTINGS_H_
  2. #define _WIN_USER_SETTINGS_H_
  3. /* Set the following to 1 for WCv5.0-RC12 build. */
  4. #if 0
  5. #undef HAVE_FIPS
  6. #define HAVE_FIPS
  7. #undef HAVE_FIPS_VERSION
  8. #define HAVE_FIPS_VERSION 5
  9. #undef HAVE_FIPS_VERSION_MINOR
  10. #define HAVE_FIPS_VERSION_MINOR 2
  11. #endif
  12. /* For FIPS Ready, uncomment the following: */
  13. /* #define WOLFSSL_FIPS_READY */
  14. #ifdef WOLFSSL_FIPS_READY
  15. #undef HAVE_FIPS
  16. #define HAVE_FIPS
  17. #undef HAVE_FIPS_VERSION
  18. #define HAVE_FIPS_VERSION 5
  19. #undef HAVE_FIPS_VERSION_MINOR
  20. #define HAVE_FIPS_VERSION_MINOR 3
  21. #endif
  22. /* Verify this is Windows */
  23. #ifndef _WIN32
  24. #error This user_settings.h header is only designed for Windows
  25. #endif
  26. /* Configurations */
  27. #if defined(HAVE_FIPS)
  28. /* FIPS */
  29. #define OPENSSL_EXTRA
  30. #define HAVE_THREAD_LS
  31. #define WOLFSSL_KEY_GEN
  32. #define HAVE_AESGCM
  33. #define HAVE_HASHDRBG
  34. #define WOLFSSL_SHA384
  35. #define WOLFSSL_SHA512
  36. #define NO_PSK
  37. #define NO_RC4
  38. #define NO_DSA
  39. #define NO_MD4
  40. #if defined(HAVE_FIPS_VERSION) && (HAVE_FIPS_VERSION >= 2)
  41. #define WOLFSSL_SHA224
  42. #define WOLFSSL_SHA3
  43. #define WC_RSA_PSS
  44. #define WC_RSA_NO_PADDING
  45. #define HAVE_ECC
  46. #define HAVE_ECC384
  47. #define HAVE_ECC521
  48. #define HAVE_SUPPORTED_CURVES
  49. #define HAVE_TLS_EXTENSIONS
  50. #define ECC_SHAMIR
  51. #define HAVE_ECC_CDH
  52. #define ECC_TIMING_RESISTANT
  53. #define TFM_TIMING_RESISTANT
  54. #define WOLFSSL_AES_COUNTER
  55. #define WOLFSSL_AES_DIRECT
  56. #define HAVE_AES_ECB
  57. #define HAVE_AESCCM
  58. #define WOLFSSL_CMAC
  59. #define HAVE_HKDF
  60. #define WOLFSSL_VALIDATE_ECC_IMPORT
  61. #define WOLFSSL_VALIDATE_FFC_IMPORT
  62. #define HAVE_FFDHE_Q
  63. #define HAVE_PUBLIC_FFDHE
  64. #define WOLFSSL_AESNI
  65. #define HAVE_INTEL_RDSEED
  66. #define FORCE_FAILURE_RDSEED
  67. #endif /* FIPS v2 */
  68. #if defined(HAVE_FIPS_VERSION) && (HAVE_FIPS_VERSION >= 5)
  69. #undef WOLFSSL_AESNI /* Comment out if using PAA */
  70. #undef HAVE_INTEL_RDSEED
  71. #undef FORCE_FAILURE_RDSEED
  72. #undef HAVE_PUBLIC_FFDHE
  73. #define NO_DES
  74. #define NO_DES3
  75. #define NO_MD5
  76. #define NO_OLD_TLS
  77. #define WOLFSSL_TLS13
  78. #define HAVE_TLS_EXTENSIONS
  79. #define HAVE_SUPPORTED_CURVES
  80. #define GCM_TABLE_4BIT
  81. #define WOLFSSL_NO_SHAKE256
  82. #define WOLFSSL_VALIDATE_ECC_KEYGEN
  83. #define WOLFSSL_ECDSA_SET_K
  84. #define WOLFSSL_WOLFSSH
  85. #define WOLFSSL_PUBLIC_MP
  86. #define WC_RNG_SEED_CB
  87. #define TFM_ECC256
  88. #define ECC_USER_CURVES
  89. #define HAVE_ECC192
  90. #define HAVE_ECC224
  91. #define HAVE_ECC256
  92. #define HAVE_ECC384
  93. #define HAVE_ECC521
  94. #define HAVE_FFDHE_2048
  95. #define HAVE_FFDHE_3072
  96. #define HAVE_FFDHE_4096
  97. #define HAVE_FFDHE_6144
  98. #define HAVE_FFDHE_8192
  99. #define WOLFSSL_AES_OFB
  100. #define FP_MAX_BITS 16384
  101. #endif /* FIPS v5 */
  102. #else
  103. /* Enables blinding mode, to prevent timing attacks */
  104. #define WC_RSA_BLINDING
  105. #if defined(WOLFSSL_LIB)
  106. /* The lib */
  107. #define OPENSSL_EXTRA
  108. #define WOLFSSL_RIPEMD
  109. #define NO_PSK
  110. #define HAVE_EXTENDED_MASTER
  111. #define WOLFSSL_SNIFFER
  112. #define HAVE_SECURE_RENEGOTIATION
  113. #define HAVE_AESGCM
  114. #define WOLFSSL_SHA384
  115. #define WOLFSSL_SHA512
  116. #define HAVE_SUPPORTED_CURVES
  117. #define HAVE_TLS_EXTENSIONS
  118. #define HAVE_ECC
  119. #define ECC_SHAMIR
  120. #define ECC_TIMING_RESISTANT
  121. #else
  122. /* The servers and clients */
  123. #define OPENSSL_EXTRA
  124. #define NO_PSK
  125. #endif
  126. #endif /* HAVE_FIPS */
  127. #endif /* _WIN_USER_SETTINGS_H_ */