default_conf.ftl 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627
  1. [#ftl]
  2. /**
  3. ******************************************************************************
  4. * File Name : ${name}
  5. * Description : This file provides code for the configuration
  6. * of the ${name} instances.
  7. ******************************************************************************
  8. [@common.optinclude name=mxTmpFolder+"/license.tmp"/][#--include License text --]
  9. ******************************************************************************
  10. */
  11. [#assign s = name]
  12. [#assign toto = s?replace(".","_")]
  13. [#assign toto = toto?replace("/","")]
  14. [#assign toto = toto?replace("-","_")]
  15. [#assign inclusion_protection = toto?upper_case]
  16. /* Define to prevent recursive inclusion -------------------------------------*/
  17. #ifndef __${inclusion_protection}__
  18. #define __${inclusion_protection}__
  19. #ifdef __cplusplus
  20. extern "C" {
  21. #endif
  22. /* Includes ------------------------------------------------------------------*/
  23. [#if includes??]
  24. [#list includes as include]
  25. #include "${include}"
  26. [/#list]
  27. [/#if]
  28. [#-- SWIPdatas is a list of SWIPconfigModel --]
  29. [#list SWIPdatas as SWIP]
  30. [#-- Global variables --]
  31. [#if SWIP.variables??]
  32. [#list SWIP.variables as variable]
  33. extern ${variable.value} ${variable.name};
  34. [/#list]
  35. [/#if]
  36. [#-- Global variables --]
  37. [#assign instName = SWIP.ipName]
  38. [#assign fileName = SWIP.fileName]
  39. [#assign version = SWIP.version]
  40. /**
  41. MiddleWare name : ${instName}
  42. MiddleWare fileName : ${fileName}
  43. MiddleWare version : ${version}
  44. */
  45. [#if SWIP.defines??]
  46. [#list SWIP.defines as definition]
  47. /*---------- [#if definition.comments??]${definition.comments}[/#if] -----------*/
  48. #define ${definition.name} #t#t ${definition.value}
  49. [#if definition.description??]${definition.description} [/#if]
  50. [/#list]
  51. [/#if]
  52. [/#list]
  53. /* ------------------------------------------------------------------------- */
  54. /* Hardware platform */
  55. /* ------------------------------------------------------------------------- */
  56. /* Setup default (No crypto hardware acceleration or TLS UART test).
  57. * Use undef in platform section to enable it.
  58. */
  59. #define NO_STM32_HASH
  60. #define NO_STM32_CRYPTO
  61. #define NO_TLS_UART_TEST
  62. #if defined(STM32WB55xx)
  63. #define WOLFSSL_STM32WB
  64. #define WOLFSSL_STM32_PKA
  65. #undef NO_STM32_CRYPTO
  66. #define HAL_CONSOLE_UART huart1
  67. #elif defined(STM32WL55xx)
  68. #define WOLFSSL_STM32WL
  69. #define WOLFSSL_STM32_PKA
  70. #undef NO_STM32_CRYPTO
  71. #define HAL_CONSOLE_UART huart2
  72. #elif defined(STM32F407xx)
  73. #define WOLFSSL_STM32F4
  74. #define HAL_CONSOLE_UART huart2
  75. #elif defined(STM32F437xx)
  76. #define WOLFSSL_STM32F4
  77. #undef NO_STM32_HASH
  78. #undef NO_STM32_CRYPTO
  79. #define STM32_HAL_V2
  80. #define HAL_CONSOLE_UART huart4
  81. #elif defined(STM32F777xx)
  82. #define WOLFSSL_STM32F7
  83. #undef NO_STM32_HASH
  84. #undef NO_STM32_CRYPTO
  85. #define STM32_HAL_V2
  86. #define HAL_CONSOLE_UART huart2
  87. #elif defined(STM32F756xx)
  88. #define WOLFSSL_STM32F7
  89. #undef NO_STM32_HASH
  90. #undef NO_STM32_CRYPTO
  91. #define STM32_HAL_V2
  92. #define HAL_CONSOLE_UART huart3
  93. #elif defined(STM32H753xx)
  94. #define WOLFSSL_STM32H7
  95. #undef NO_STM32_HASH
  96. #undef NO_STM32_CRYPTO
  97. #define HAL_CONSOLE_UART huart3
  98. #elif defined(STM32H723xx) || defined(STM32H725xx)
  99. #define WOLFSSL_STM32H7
  100. #define HAL_CONSOLE_UART huart3
  101. #elif defined(STM32L4A6xx)
  102. #define WOLFSSL_STM32L4
  103. #undef NO_STM32_HASH
  104. #undef NO_STM32_CRYPTO
  105. #define HAL_CONSOLE_UART hlpuart1
  106. #elif defined(STM32L475xx)
  107. #define WOLFSSL_STM32L4
  108. #define HAL_CONSOLE_UART huart1
  109. #elif defined(STM32L562xx)
  110. #define WOLFSSL_STM32L5
  111. #define WOLFSSL_STM32_PKA
  112. #undef NO_STM32_HASH
  113. #undef NO_STM32_CRYPTO
  114. #define HAL_CONSOLE_UART huart1
  115. #elif defined(STM32L552xx)
  116. #define WOLFSSL_STM32L5
  117. #undef NO_STM32_HASH
  118. #define HAL_CONSOLE_UART hlpuart1
  119. #elif defined(STM32F207xx)
  120. #define WOLFSSL_STM32F2
  121. #define HAL_CONSOLE_UART huart3
  122. #elif defined(STM32F217xx)
  123. #define WOLFSSL_STM32F2
  124. #define HAL_CONSOLE_UART huart2
  125. #elif defined(STM32F107xC)
  126. #define WOLFSSL_STM32F1
  127. #define HAL_CONSOLE_UART huart4
  128. #define NO_STM32_RNG
  129. #elif defined(STM32F401xE)
  130. #define WOLFSSL_STM32F4
  131. #define HAL_CONSOLE_UART huart2
  132. #define NO_STM32_RNG
  133. #define WOLFSSL_GENSEED_FORTEST /* no HW RNG is available use test seed */
  134. #elif defined(STM32G071xx)
  135. #define WOLFSSL_STM32G0
  136. #define HAL_CONSOLE_UART huart2
  137. #define NO_STM32_RNG
  138. #define WOLFSSL_GENSEED_FORTEST /* no HW RNG is available use test seed */
  139. #elif defined(STM32U575xx) || defined(STM32U585xx)
  140. #define HAL_CONSOLE_UART huart1
  141. #define WOLFSSL_STM32U5
  142. #define STM32_HAL_V2
  143. #ifdef STM32U585xx
  144. #undef NO_STM32_HASH
  145. #undef NO_STM32_CRYPTO
  146. #define WOLFSSL_STM32_PKA
  147. #endif
  148. #elif defined(STM32H563xx)
  149. #define WOLFSSL_STM32H5
  150. #define HAL_CONSOLE_UART huart3
  151. #define STM32_HAL_V2
  152. #undef NO_STM32_HASH
  153. #else
  154. #warning Please define a hardware platform!
  155. /* This means there is not a pre-defined platform for your board/CPU */
  156. /* You need to define a CPU type, HW crypto and debug UART */
  157. /* CPU Type: WOLFSSL_STM32F1, WOLFSSL_STM32F2, WOLFSSL_STM32F4,
  158. WOLFSSL_STM32F7, WOLFSSL_STM32H7, WOLFSSL_STM32L4, WOLFSSL_STM32L5,
  159. WOLFSSL_STM32G0, WOLFSSL_STM32WB and WOLFSSL_STM32U5 */
  160. #define WOLFSSL_STM32F4
  161. /* Debug UART used for printf */
  162. /* The UART interface number varies for each board/CPU */
  163. /* Typically this is the UART attached to the ST-Link USB CDC UART port */
  164. #define HAL_CONSOLE_UART huart4
  165. /* Hardware Crypto - uncomment as available on hardware */
  166. //#define WOLFSSL_STM32_PKA
  167. //#define NO_STM32_RNG
  168. //#undef NO_STM32_HASH
  169. //#undef NO_STM32_CRYPTO
  170. /* if no HW RNG is available use test seed */
  171. //#define WOLFSSL_GENSEED_FORTEST
  172. //#define STM32_HAL_V2
  173. #endif
  174. /* ------------------------------------------------------------------------- */
  175. /* Platform */
  176. /* ------------------------------------------------------------------------- */
  177. #define SIZEOF_LONG_LONG 8
  178. #define WOLFSSL_GENERAL_ALIGNMENT 4
  179. #define WOLFSSL_STM32_CUBEMX
  180. #define WOLFSSL_SMALL_STACK
  181. #define WOLFSSL_USER_IO
  182. #define WOLFSSL_NO_SOCK
  183. #define WOLFSSL_IGNORE_FILE_WARN
  184. /* ------------------------------------------------------------------------- */
  185. /* Operating System */
  186. /* ------------------------------------------------------------------------- */
  187. #if defined(WOLF_CONF_RTOS) && WOLF_CONF_RTOS == 2
  188. #define FREERTOS
  189. #else
  190. #define SINGLE_THREADED
  191. #endif
  192. /* ------------------------------------------------------------------------- */
  193. /* Math Configuration */
  194. /* ------------------------------------------------------------------------- */
  195. /* 1=Fast (stack)
  196. * 2=Normal (heap)
  197. * 3=Single Precision C (only common curves/key sizes)
  198. * 4=Single Precision ASM Cortex-M3+
  199. * 5=Single Precision ASM Cortex-M0 (Generic Thumb)
  200. * 6=Single Precision C all small
  201. * 7=Single Precision C all big
  202. */
  203. #if defined(WOLF_CONF_MATH) && WOLF_CONF_MATH == 1
  204. /* fast (stack) math - tfm.c */
  205. #define USE_FAST_MATH
  206. #define TFM_TIMING_RESISTANT
  207. /* Optimizations (TFM_ARM, TFM_ASM or none) */
  208. //#define TFM_NO_ASM
  209. //#define TFM_ASM
  210. #elif defined(WOLF_CONF_MATH) && WOLF_CONF_MATH == 2
  211. /* heap math - integer.c */
  212. #define USE_INTEGER_HEAP_MATH
  213. #elif defined(WOLF_CONF_MATH) && (WOLF_CONF_MATH >= 3)
  214. /* single precision only */
  215. #define WOLFSSL_SP
  216. #if WOLF_CONF_MATH != 7
  217. #define WOLFSSL_SP_SMALL /* use smaller version of code */
  218. #endif
  219. #if defined(WOLF_CONF_RSA) && WOLF_CONF_RSA == 1
  220. #define WOLFSSL_HAVE_SP_RSA
  221. #endif
  222. #if defined(WOLF_CONF_DH) && WOLF_CONF_DH == 1
  223. #define WOLFSSL_HAVE_SP_DH
  224. #endif
  225. #if defined(WOLF_CONF_ECC) && WOLF_CONF_ECC == 1
  226. #define WOLFSSL_HAVE_SP_ECC
  227. #endif
  228. #if WOLF_CONF_MATH == 6 || WOLF_CONF_MATH == 7
  229. #define WOLFSSL_SP_MATH_ALL /* use sp_int.c multi precision math */
  230. #else
  231. #define WOLFSSL_SP_MATH /* disable non-standard curves / key sizes */
  232. #endif
  233. #define SP_WORD_SIZE 32
  234. /* Enable to put all math on stack (no heap) */
  235. //#define WOLFSSL_SP_NO_MALLOC
  236. #if WOLF_CONF_MATH == 4 || WOLF_CONF_MATH == 5
  237. #define WOLFSSL_SP_ASM /* required if using the ASM versions */
  238. #if WOLF_CONF_MATH == 4
  239. /* ARM Cortex-M3+ */
  240. #define WOLFSSL_SP_ARM_CORTEX_M_ASM
  241. #endif
  242. #if WOLF_CONF_MATH == 5
  243. /* Generic ARM Thumb (Cortex-M0) Assembly */
  244. #define WOLFSSL_SP_ARM_THUMB_ASM
  245. #endif
  246. #endif
  247. #endif
  248. /* ------------------------------------------------------------------------- */
  249. /* Enable Features */
  250. /* ------------------------------------------------------------------------- */
  251. /* Required for TLS */
  252. #define HAVE_TLS_EXTENSIONS
  253. #define HAVE_SUPPORTED_CURVES
  254. #define HAVE_ENCRYPT_THEN_MAC
  255. #define HAVE_EXTENDED_MASTER
  256. #if defined(WOLF_CONF_TLS13) && WOLF_CONF_TLS13 == 1
  257. #define WOLFSSL_TLS13
  258. #define HAVE_HKDF
  259. #endif
  260. #if defined(WOLF_CONF_DTLS) && WOLF_CONF_DTLS == 1
  261. #define WOLFSSL_DTLS
  262. #endif
  263. #if defined(WOLF_CONF_PSK) && WOLF_CONF_PSK == 0
  264. #define NO_PSK
  265. #endif
  266. #if defined(WOLF_CONF_PWDBASED) && WOLF_CONF_PWDBASED == 0
  267. #define NO_PWDBASED
  268. #endif
  269. #if defined(WOLF_CONF_KEEP_PEER_CERT) && WOLF_CONF_KEEP_PEER_CERT == 1
  270. #define KEEP_PEER_CERT
  271. #endif
  272. #if defined(WOLF_CONF_BASE64_ENCODE) && WOLF_CONF_BASE64_ENCODE == 1
  273. #define WOLFSSL_BASE64_ENCODE
  274. #endif
  275. #if defined(WOLF_CONF_OPENSSL_EXTRA) && WOLF_CONF_OPENSSL_EXTRA >= 1
  276. #define OPENSSL_EXTRA
  277. #if !defined(INT_MAX)
  278. #include <limits.h>
  279. #endif
  280. #endif
  281. #if defined(WOLF_CONF_OPENSSL_EXTRA) && WOLF_CONF_OPENSSL_EXTRA >= 2
  282. #define OPENSSL_ALL
  283. #endif
  284. /* TLS Session Cache */
  285. #if 0
  286. #define SMALL_SESSION_CACHE
  287. #else
  288. #define NO_SESSION_CACHE
  289. #endif
  290. /* Post Quantum
  291. * Note: PQM4 is compatible with STM32. The project can be found at:
  292. * https://github.com/mupq/pqm4
  293. */
  294. #if defined(WOLF_CONF_PQM4) && WOLF_CONF_PQM4 == 1
  295. #define HAVE_PQM4
  296. #endif
  297. /* ------------------------------------------------------------------------- */
  298. /* Crypto */
  299. /* ------------------------------------------------------------------------- */
  300. /* RSA */
  301. #undef NO_RSA
  302. #if defined(WOLF_CONF_RSA) && WOLF_CONF_RSA == 1
  303. #ifdef USE_FAST_MATH
  304. /* Maximum math bits (Max RSA key bits * 2) */
  305. #undef FP_MAX_BITS
  306. #define FP_MAX_BITS 4096
  307. #endif
  308. /* half as much memory but twice as slow */
  309. #undef RSA_LOW_MEM
  310. //#define RSA_LOW_MEM
  311. /* Enables blinding mode, to prevent timing attacks */
  312. #undef WC_RSA_BLINDING
  313. #define WC_RSA_BLINDING
  314. /* RSA PSS Support (required for TLS v1.3) */
  315. #ifdef WOLFSSL_TLS13
  316. #define WC_RSA_PSS
  317. #endif
  318. #else
  319. #define NO_RSA
  320. #endif
  321. /* ECC */
  322. #undef HAVE_ECC
  323. #if defined(WOLF_CONF_ECC) && WOLF_CONF_ECC == 1
  324. #define HAVE_ECC
  325. /* Manually define enabled curves */
  326. #define ECC_USER_CURVES
  327. //#define HAVE_ECC192
  328. //#define HAVE_ECC224
  329. #undef NO_ECC256
  330. //#define HAVE_ECC384
  331. //#define HAVE_ECC521
  332. /* Fixed point cache (speeds repeated operations against same private key) */
  333. #undef FP_ECC
  334. //#define FP_ECC
  335. #ifdef FP_ECC
  336. /* Bits / Entries */
  337. #undef FP_ENTRIES
  338. #define FP_ENTRIES 2
  339. #undef FP_LUT
  340. #define FP_LUT 4
  341. #endif
  342. /* Optional ECC calculation method */
  343. /* Note: doubles heap usage, but slightly faster */
  344. #undef ECC_SHAMIR
  345. #define ECC_SHAMIR
  346. /* Reduces heap usage, but slower */
  347. #define ECC_TIMING_RESISTANT
  348. /* Compressed ECC key support */
  349. //#define HAVE_COMP_KEY
  350. #ifdef USE_FAST_MATH
  351. #ifdef NO_RSA
  352. /* Custom fastmath size if not using RSA */
  353. /* MAX = ROUND32(ECC BITS) * 2 */
  354. #define FP_MAX_BITS (256 * 2)
  355. #else
  356. #define ALT_ECC_SIZE
  357. #endif
  358. /* Enable TFM optimizations for ECC */
  359. //#define TFM_ECC192
  360. //#define TFM_ECC224
  361. //#define TFM_ECC256
  362. //#define TFM_ECC384
  363. //#define TFM_ECC521
  364. #endif
  365. #endif
  366. /* DH */
  367. #undef NO_DH
  368. #if defined(WOLF_CONF_DH) && WOLF_CONF_DH == 1
  369. #define HAVE_DH /* freeRTOS settings.h requires this */
  370. #define HAVE_FFDHE_2048
  371. #define HAVE_DH_DEFAULT_PARAMS
  372. #else
  373. #define NO_DH
  374. #endif
  375. /* AES */
  376. #if defined(WOLF_CONF_AESGCM) && WOLF_CONF_AESGCM == 1
  377. #define HAVE_AESGCM
  378. /* GCM Method: GCM_SMALL, GCM_WORD32, GCM_TABLE or GCM_TABLE_4BIT */
  379. /* GCM_TABLE is about 4K larger and 3x faster for GHASH */
  380. #define GCM_SMALL
  381. #define HAVE_AES_DECRYPT
  382. #endif
  383. #if defined(WOLF_CONF_AESCBC) && WOLF_CONF_AESCBC == 1
  384. #define HAVE_AES_CBC
  385. #define HAVE_AES_DECRYPT
  386. #endif
  387. /* Other possible AES modes */
  388. //#define WOLFSSL_AES_COUNTER
  389. //#define HAVE_AESCCM
  390. //#define WOLFSSL_AES_XTS
  391. //#define WOLFSSL_AES_DIRECT
  392. //#define HAVE_AES_ECB
  393. //#define HAVE_AES_KEYWRAP
  394. //#define AES_MAX_KEY_SIZE 256
  395. /* ChaCha20 / Poly1305 */
  396. #undef HAVE_CHACHA
  397. #undef HAVE_POLY1305
  398. #if defined(WOLF_CONF_CHAPOLY) && WOLF_CONF_CHAPOLY == 1
  399. #define HAVE_CHACHA
  400. #define HAVE_POLY1305
  401. /* Needed for Poly1305 */
  402. #undef HAVE_ONE_TIME_AUTH
  403. #define HAVE_ONE_TIME_AUTH
  404. #endif
  405. /* Ed25519 / Curve25519 */
  406. #undef HAVE_CURVE25519
  407. #undef HAVE_ED25519
  408. #if defined(WOLF_CONF_EDCURVE25519) && WOLF_CONF_EDCURVE25519 == 1
  409. #define HAVE_CURVE25519
  410. #define HAVE_ED25519
  411. /* Optionally use small math (less flash usage, but much slower) */
  412. #define CURVED25519_SMALL
  413. #endif
  414. /* ------------------------------------------------------------------------- */
  415. /* Hashing */
  416. /* ------------------------------------------------------------------------- */
  417. /* Sha1 */
  418. #undef NO_SHA
  419. #if defined(WOLF_CONF_SHA1) && WOLF_CONF_SHA1 == 1
  420. /* 1k smaller, but 25% slower */
  421. //#define USE_SLOW_SHA
  422. #else
  423. #define NO_SHA
  424. #endif
  425. /* Sha2-256 */
  426. #undef NO_SHA256
  427. #if defined(WOLF_CONF_SHA2_256) && WOLF_CONF_SHA2_256 == 1
  428. /* not unrolled - ~2k smaller and ~25% slower */
  429. //#define USE_SLOW_SHA256
  430. //#define WOLFSSL_SHAKE256
  431. /* Sha2-224 */
  432. #if defined(WOLF_CONF_SHA2_224) && WOLF_CONF_SHA2_224 == 1
  433. #define WOLFSSL_SHA224
  434. #endif
  435. #else
  436. #define NO_SHA256
  437. #endif
  438. /* Sha2-512 */
  439. #undef WOLFSSL_SHA512
  440. #if defined(WOLF_CONF_SHA2_512) && WOLF_CONF_SHA2_512 == 1
  441. /* over twice as small, but 50% slower */
  442. //#define USE_SLOW_SHA512
  443. #define WOLFSSL_SHA512
  444. #define HAVE_SHA512 /* freeRTOS settings.h requires this */
  445. #endif
  446. /* Sha2-384 */
  447. #undef WOLFSSL_SHA384
  448. #if defined(WOLF_CONF_SHA2_384) && WOLF_CONF_SHA2_384 == 1
  449. #define WOLFSSL_SHA384
  450. #endif
  451. /* Sha3 */
  452. #undef WOLFSSL_SHA3
  453. #if defined(WOLF_CONF_SHA3) && WOLF_CONF_SHA3 == 1
  454. #define WOLFSSL_SHA3
  455. #endif
  456. /* MD5 */
  457. #if defined(WOLF_CONF_MD5) && WOLF_CONF_MD5 == 1
  458. /* enabled */
  459. #else
  460. #define NO_MD5
  461. #endif
  462. /* ------------------------------------------------------------------------- */
  463. /* Benchmark / Test */
  464. /* ------------------------------------------------------------------------- */
  465. /* Use reduced benchmark / test sizes */
  466. #define BENCH_EMBEDDED
  467. #define USE_CERT_BUFFERS_2048
  468. #define USE_CERT_BUFFERS_256
  469. /* ------------------------------------------------------------------------- */
  470. /* Debugging */
  471. /* ------------------------------------------------------------------------- */
  472. #if defined(WOLF_CONF_DEBUG) && WOLF_CONF_DEBUG == 1
  473. #define DEBUG_WOLFSSL
  474. /* Use this to measure / print heap usage */
  475. #if 0
  476. #define USE_WOLFSSL_MEMORY
  477. #define WOLFSSL_TRACK_MEMORY
  478. #define WOLFSSL_DEBUG_MEMORY
  479. #define WOLFSSL_DEBUG_MEMORY_PRINT
  480. #endif
  481. #else
  482. //#define NO_WOLFSSL_MEMORY
  483. //#define NO_ERROR_STRINGS
  484. #endif
  485. /* ------------------------------------------------------------------------- */
  486. /* Port */
  487. /* ------------------------------------------------------------------------- */
  488. /* Override Current Time */
  489. /* Allows custom "custom_time()" function to be used for benchmark */
  490. #define WOLFSSL_USER_CURRTIME
  491. /* ------------------------------------------------------------------------- */
  492. /* RNG */
  493. /* ------------------------------------------------------------------------- */
  494. #define NO_OLD_RNGNAME /* conflicts with STM RNG macro */
  495. #if !defined(WOLF_CONF_RNG) || WOLF_CONF_RNG == 1
  496. /* default is enabled */
  497. #define HAVE_HASHDRBG
  498. #else /* WOLF_CONF_RNG == 0 */
  499. #define WC_NO_HASHDRBG
  500. #define WC_NO_RNG
  501. #endif
  502. /* ------------------------------------------------------------------------- */
  503. /* Disable Features */
  504. /* ------------------------------------------------------------------------- */
  505. #if defined(WOLF_CONF_TLS12) && WOLF_CONF_TLS12 == 0
  506. #define WOLFSSL_NO_TLS12
  507. #endif
  508. #if defined(WOLF_CONF_WOLFCRYPT_ONLY) && WOLF_CONF_WOLFCRYPT_ONLY == 1
  509. #define WOLFCRYPT_ONLY
  510. #endif
  511. //#define NO_WOLFSSL_SERVER
  512. //#define NO_WOLFSSL_CLIENT
  513. #if defined(WOLF_CONF_TEST) && WOLF_CONF_TEST == 0
  514. #define NO_CRYPT_TEST
  515. #define NO_CRYPT_BENCHMARK
  516. #endif
  517. #define NO_FILESYSTEM
  518. #define NO_WRITEV
  519. #define NO_MAIN_DRIVER
  520. #define NO_DEV_RANDOM
  521. #define NO_OLD_TLS
  522. #define WOLFSSL_NO_CLIENT_AUTH /* disable client auth for Ed25519/Ed448 */
  523. #define NO_DSA
  524. #define NO_RC4
  525. #define NO_MD4
  526. #define NO_DES3
  527. /* In-lining of misc.c functions */
  528. /* If defined, must include wolfcrypt/src/misc.c in build */
  529. /* Slower, but about 1k smaller */
  530. //#define NO_INLINE
  531. /* Base16 / Base64 encoding */
  532. //#define NO_CODING
  533. /* bypass certificate date checking, due to lack of properly configured RTC source */
  534. #ifndef HAL_RTC_MODULE_ENABLED
  535. #define NO_ASN_TIME
  536. #endif
  537. #ifdef __cplusplus
  538. }
  539. #endif
  540. #endif /* ${inclusion_protection}_H */
  541. /**
  542. * @}
  543. */
  544. /*****END OF FILE****/