1
0

user_settings_all.h 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230
  1. /* user_settings_all.h
  2. *
  3. * Copyright (C) 2006-2022 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. /* should be renamed to user_settings.h for customer use
  22. * generated from configure options ./configure --enable-all
  23. *
  24. * Cleaned up by David Garske
  25. */
  26. #ifndef WOLFSSL_USER_SETTINGS_H
  27. #define WOLFSSL_USER_SETTINGS_H
  28. #ifdef __cplusplus
  29. extern "C" {
  30. #endif
  31. /* Features */
  32. #define WOLFSSL_PUBLIC_MP /* Make math API's public */
  33. #define KEEP_PEER_CERT /* Retain peer's certificate */
  34. #define KEEP_OUR_CERT /* Keep our certificate */
  35. #define WOLFSSL_ALWAYS_VERIFY_CB /* Always call verify callback (configured via wolfSSL_CTX_set_verify API) */
  36. #define WOLFSSL_VERIFY_CB_ALL_CERTS /* Call verify callback for all intermediate certs */
  37. #define WOLFSSL_ALWAYS_KEEP_SNI
  38. #define WOLFSSL_EXTRA_ALERTS /* Allow sending other TLS alerts */
  39. #define HAVE_EX_DATA /* Enable "extra" EX data API's for user information in CTX/WOLFSSL */
  40. #define HAVE_EXT_CACHE
  41. #define ATOMIC_USER /* Enable Atomic Record Layer callbacks */
  42. #define HAVE_PK_CALLBACKS /* Enable public key callbacks */
  43. #define WOLFSSL_ALT_NAMES /* Allow alternate cert chain validation to any trusted cert (not entire chain presented by peer) */
  44. #define HAVE_NULL_CIPHER /* Enable use of TLS cipher suites without cipher (clear text / no encryption) */
  45. #define WOLFSSL_HAVE_CERT_SERVICE
  46. #define WOLFSSL_JNI
  47. #define WOLFSSL_SEP
  48. #define WOLFCRYPT_HAVE_SRP
  49. #define WOLFSSL_HAVE_WOLFSCEP
  50. #define WOLFSSL_ENCRYPTED_KEYS /* Support for encrypted keys PKCS8 */
  51. #define HAVE_PKCS7
  52. #define WOLFSSL_MULTI_ATTRIB
  53. #define WOLFSSL_DER_LOAD
  54. #define ASN_BER_TO_DER /* BER to DER support */
  55. #define WOLFSSL_SIGNER_DER_CERT
  56. //#define HAVE_THREAD_LS /* DG Commented: Thread local storage - may not be portable */
  57. //#define WOLFSSL_AEAD_ONLY /* automatically set if TLS v1.3 only, but can be enabled for TLS v1.2 manually */
  58. /* TLS Features */
  59. #define WOLFSSL_DTLS
  60. #define WOLFSSL_TLS13
  61. #define WOLFSSL_EITHER_SIDE /* allow generic server/client method for WOLFSSL_CTX new */
  62. /* DG Disabled SSLv3 and TLSv1.0 - should avoid using */
  63. //#define WOLFSSL_ALLOW_SSLV3
  64. //#define WOLFSSL_ALLOW_TLSV10
  65. /* TLS Extensions */
  66. #define HAVE_TLS_EXTENSIONS
  67. #define HAVE_SUPPORTED_CURVES
  68. #define HAVE_ONE_TIME_AUTH
  69. #define HAVE_SNI
  70. #define HAVE_ALPN
  71. #define HAVE_MAX_FRAGMENT
  72. #define HAVE_TRUNCATED_HMAC
  73. #define HAVE_SESSION_TICKET
  74. #define HAVE_EXTENDED_MASTER
  75. #define HAVE_TRUSTED_CA
  76. #define HAVE_ENCRYPT_THEN_MAC
  77. /* TLS Session Cache */
  78. #define SESSION_CERTS
  79. #define PERSIST_SESSION_CACHE
  80. #define PERSIST_CERT_CACHE
  81. /* Key and Certificate Generation */
  82. #define WOLFSSL_KEY_GEN
  83. #define WOLFSSL_CERT_GEN
  84. #define WOLFSSL_CERT_REQ
  85. #define WOLFSSL_CERT_EXT
  86. /* Certificate Revocation */
  87. #define HAVE_OCSP
  88. #define HAVE_CERTIFICATE_STATUS_REQUEST
  89. #define HAVE_CERTIFICATE_STATUS_REQUEST_V2
  90. #define HAVE_CRL
  91. #define HAVE_CRL_IO
  92. #define HAVE_IO_TIMEOUT
  93. //#define HAVE_CRL_MONITOR /* DG Disabled (Monitors CRL files on filesystem) - not portable feature */
  94. /* Fast math key size 4096-bit max */
  95. #define USE_FAST_MATH
  96. #define FP_MAX_BITS 8192
  97. //#define HAVE___UINT128_T 1 /* DG commented: May not be portable */
  98. /* Timing Resistance */
  99. #define TFM_TIMING_RESISTANT
  100. #define ECC_TIMING_RESISTANT
  101. #define WC_RSA_BLINDING
  102. /* DH Key Sizes */
  103. #define HAVE_FFDHE_2048
  104. #define HAVE_FFDHE_3072
  105. /* ECC Features */
  106. #define HAVE_ECC
  107. #define TFM_ECC256
  108. #define ECC_SHAMIR
  109. #define WOLFSSL_CUSTOM_CURVES /* enable other curves (not just prime) */
  110. #define HAVE_ECC_SECPR2
  111. #define HAVE_ECC_SECPR3
  112. #define HAVE_ECC_BRAINPOOL
  113. #define HAVE_ECC_KOBLITZ
  114. #define HAVE_ECC_CDH /* Co-factor */
  115. #define HAVE_COMP_KEY /* Compressed key support */
  116. #define FP_ECC /* Fixed point caching - speed repeated operations against same key */
  117. #define HAVE_ECC_ENCRYPT
  118. /* RSA */
  119. #define WC_RSA_PSS
  120. /* AES */
  121. #define HAVE_AES_DECRYPT
  122. #define HAVE_AES_ECB
  123. #define WOLFSSL_AES_DIRECT
  124. #define WOLFSSL_AES_COUNTER
  125. #define HAVE_AESGCM
  126. #define HAVE_AESCCM
  127. #define WOLFSSL_AES_OFB
  128. #define WOLFSSL_AES_CFB
  129. #define WOLFSSL_AES_XTS
  130. #define HAVE_AES_KEYWRAP
  131. /* Hashing */
  132. #define WOLFSSL_SHA224
  133. #define WOLFSSL_SHA512
  134. #define WOLFSSL_SHA384
  135. #define WOLFSSL_SHAKE256
  136. #define WOLFSSL_SHA3
  137. #define WOLFSSL_HASH_FLAGS /* enable hash flag API's */
  138. /* Additional Algorithms */
  139. #define HAVE_HASHDRBG
  140. #define HAVE_CURVE25519
  141. #define HAVE_ED25519
  142. #define CURVED25519_SMALL
  143. #define HAVE_CURVE448
  144. #define HAVE_POLY1305
  145. #define HAVE_CHACHA
  146. #define HAVE_HKDF
  147. #define HAVE_X963_KDF
  148. #define WOLFSSL_CMAC
  149. #define WOLFSSL_DES_ECB
  150. /* Non-Standard Algorithms (DG disabled) */
  151. //#define HAVE_CAMELLIA
  152. //#define WOLFSSL_RIPEMD
  153. //#define HAVE_SCRYPT
  154. /* Encoding */
  155. #define WOLFSSL_BASE16
  156. #define WOLFSSL_BASE64_ENCODE
  157. /* Openssl compatibility */
  158. #if 0 /* DG Disabled */
  159. /* Openssl compatibility API's */
  160. #define OPENSSL_EXTRA
  161. #define OPENSSL_ALL
  162. #define HAVE_OPENSSL_CMD
  163. #define SSL_TXT_TLSV1_2
  164. #define SSL_TXT_TLSV1_1
  165. #define OPENSSL_NO_SSL2
  166. #define OPENSSL_NO_SSL3
  167. #define NO_OLD_RNGNAME
  168. #define NO_OLD_WC_NAMES
  169. #define NO_OLD_SSL_NAMES
  170. #define NO_OLD_SHA_NAMES
  171. /* Openssl compatibility application specific */
  172. #define WOLFSSL_LIBWEBSOCKETS
  173. #define WOLFSSL_OPENSSH
  174. #define WOLFSSL_QT
  175. #define FORTRESS
  176. #define HAVE_WEBSERVER
  177. #define HAVE_LIGHTY
  178. #define WOLFSSL_NGINX
  179. #define WOLFSSL_HAPROXY
  180. #define HAVE_STUNNEL
  181. #define WOLFSSL_ASIO
  182. #define ASIO_USE_WOLFSSL
  183. #define BOOST_ASIO_USE_WOLFSSL
  184. #endif
  185. /* TLS static cipher support - off by default */
  186. #if 0
  187. #define WOLFSSL_STATIC_RSA
  188. #define WOLFSSL_STATIC_DH
  189. #define WOLFSSL_STATIC_PSK
  190. #endif
  191. /* TLS sniffer support - off by default */
  192. #if 0
  193. #define WOLFSSL_STATIC_EPHEMERAL
  194. #define WOLFSSL_SNIFFER
  195. #endif
  196. #ifdef __cplusplus
  197. }
  198. #endif
  199. #endif /* WOLFSSL_USER_SETTINGS_H */