1
0

user_settings.h 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. #define NO_MAIN_DRIVER
  2. #define BENCH_EMBEDDED
  3. #define NO_WRITEV
  4. #define WOLFSSL_USER_IO
  5. #define NO_DEV_RANDOM
  6. #define USE_CERT_BUFFERS_2048
  7. #define WOLFSSL_USER_CURRTIME
  8. #define SIZEOF_LONG_LONG 8
  9. #define NO_WOLFSSL_DIR
  10. #define WOLFSSL_NO_CURRDIR
  11. #define NO_WOLF_C99
  12. #define NO_MULTIBYTE_PRINT
  13. #define XVALIDATEDATE(d, f,t) (0)
  14. #define WOLFSSL_USER_CURRTIME /* for benchmark */
  15. #define WOLFSSL_GENSEED_FORTEST /* Warning: define your own seed gen */
  16. /* A few examples of different math options below.
  17. *
  18. * See examples/configs/user_settings_template.h for a more
  19. * detailed template. */
  20. #if 1
  21. /* Use only single precision (SP) math and algorithms.
  22. * SP math is written to accelerate specific/common key
  23. * sizes and curves. This adds code from sp_c32.c, or one of the specific
  24. * assembly implementations like sp_cortexm.c. This code is faster than the
  25. * multi-precision support because it's optimized for the key/curve.
  26. * The SP math can be used together with any multi-precision math library
  27. * if WOLFSSL_SP_MATH is removed. If only standard keys/curves are being
  28. * used the multi-precision math is not required.
  29. */
  30. #define WOLFSSL_SP_MATH
  31. /* Enable SP ECC support */
  32. #define WOLFSSL_HAVE_SP_ECC
  33. /* Enable SP RSA support */
  34. #define WOLFSSL_HAVE_SP_RSA
  35. /* Enable SP DH support */
  36. #define WOLFSSL_HAVE_SP_DH
  37. /* Reduce stack use specifically in SP implementation. */
  38. #define WOLFSSL_SP_SMALL_STACK
  39. /* use smaller version of code */
  40. #define WOLFSSL_SP_SMALL
  41. /* Assembly optimized version - sp_cortexm.c */
  42. //#define WOLFSSL_SP_ARM_CORTEX_M_ASM
  43. #elif 1
  44. /* Use SP math for all key sizes and curves. This will use
  45. * the multi-precision (MP) math implementation in sp_int.c */
  46. #define WOLFSSL_SP_MATH_ALL
  47. /* Disable use of dynamic stack items */
  48. #define WOLFSSL_SP_NO_DYN_STACK
  49. /* use smaller version of code */
  50. #define WOLFSSL_SP_SMALL
  51. #elif 1
  52. /* Fast Math (tfm.c) (stack based and timing resistant) */
  53. #define USE_FAST_MATH
  54. /* Enable Fast Math Timing Resistance */
  55. #define TFM_TIMING_RESISTANT
  56. #else
  57. /* Normal (integer.c) (heap based, not timing resistant) - not recommended*/
  58. #define USE_INTEGER_HEAP_MATH
  59. #endif
  60. /* Enable ECC Timing Resistance */
  61. #define ECC_TIMING_RESISTANT
  62. /* Enables blinding mode, to prevent timing attacks */
  63. #define WC_RSA_BLINDING
  64. /* reduce stack use. For variables over 100 bytes allocate from heap */
  65. #define WOLFSSL_SMALL_STACK
  66. /* disable mutex locking */
  67. #define SINGLE_THREADED /* or define RTOS option */
  68. /* #define WOLFSSL_CMSIS_RTOS */
  69. #define NO_FILESYSTEM
  70. /* #define NO_DH */
  71. #define HAVE_AESGCM
  72. #define WOLFSSL_SHA512
  73. #define HAVE_ECC
  74. #define HAVE_CURVE25519
  75. #define CURVE25519_SMALL
  76. #define HAVE_ED25519