24 #ifndef WOLFSSL_USER_SETTINGS_H 25 #define WOLFSSL_USER_SETTINGS_H 35 #undef WOLFSSL_GENERAL_ALIGNMENT 36 #define WOLFSSL_GENERAL_ALIGNMENT 4 38 #undef SINGLE_THREADED 39 #define SINGLE_THREADED 41 #undef WOLFSSL_SMALL_STACK 42 #define WOLFSSL_SMALL_STACK 44 #undef WOLFSSL_USER_IO 45 #define WOLFSSL_USER_IO 51 #undef SIZEOF_LONG_LONG 52 #define SIZEOF_LONG_LONG 8 58 #undef TFM_TIMING_RESISTANT 59 #define TFM_TIMING_RESISTANT 69 #define WOLFSSL_SP_SMALL 70 #define WOLFSSL_HAVE_SP_RSA 71 #define WOLFSSL_HAVE_SP_DH 72 #define WOLFSSL_HAVE_SP_ECC 73 #define WOLFSSL_SP_CACHE_RESISTANT 89 #undef HAVE_FIPS_VERSION 90 #define HAVE_FIPS_VERSION 2 92 #ifdef SINGLE_THREADED 108 #define FP_MAX_BITS 4096 117 #undef WC_RSA_BLINDING 118 #define WC_RSA_BLINDING 130 #define WC_RSA_NO_PADDING 142 #undef ECC_USER_CURVES 143 #define ECC_USER_CURVES 145 #ifdef ECC_USER_CURVES 171 #undef ECC_TIMING_RESISTANT 172 #define ECC_TIMING_RESISTANT 182 #undef WOLFSSL_VALIDATE_ECC_IMPORT 183 #define WOLFSSL_VALIDATE_ECC_IMPORT 196 #define FP_MAX_BITS (256 + 32) 215 #define WOLFSSL_DH_CONST 216 #define HAVE_FFDHE_2048 217 #define HAVE_FFDHE_4096 223 #define WOLFSSL_VALIDATE_FFC_IMPORT 243 #undef WOLFSSL_AES_DIRECT 249 #undef WOLFSSL_AES_COUNTER 271 #define HAVE_POLY1305 274 #undef HAVE_ONE_TIME_AUTH 275 #define HAVE_ONE_TIME_AUTH 279 #undef HAVE_CURVE25519 282 #define HAVE_CURVE25519 287 #define CURVED25519_SMALL 312 #define WOLFSSL_SHA224 319 #undef WOLFSSL_SHA512 321 #define WOLFSSL_SHA512 324 #undef WOLFSSL_SHA384 326 #define WOLFSSL_SHA384 364 #undef BENCH_EMBEDDED 365 #define BENCH_EMBEDDED 367 #undef USE_CERT_BUFFERS_2048 368 #define USE_CERT_BUFFERS_2048 373 #undef USE_CERT_BUFFERS_256 374 #define USE_CERT_BUFFERS_256 382 #undef NO_ERROR_STRINGS 384 #define DEBUG_WOLFSSL 387 #define NO_ERROR_STRINGS 398 #undef XMALLOC_OVERRIDE 399 #define XMALLOC_OVERRIDE 404 extern void *myMalloc(
size_t n,
void* heap,
int type);
405 extern void myFree(
void *p,
void* heap,
int type);
406 extern void *myRealloc(
void *p,
size_t n,
void* heap,
int type);
408 #define XMALLOC(n, h, t) myMalloc(n, h, t) 409 #define XFREE(p, h, t) myFree(p, h, t) 410 #define XREALLOC(p, n, h, t) myRealloc(p, n, h, t) 415 #define WOLFSSL_STATIC_MEMORY 418 #define WOLFSSL_NO_MALLOC 420 #define WOLFSSL_MALLOC_CHECK 426 #undef USE_WOLFSSL_MEMORY 427 #define USE_WOLFSSL_MEMORY 431 #undef WOLFSSL_TRACK_MEMORY 432 #define WOLFSSL_TRACK_MEMORY 434 #undef WOLFSSL_DEBUG_MEMORY 435 #define WOLFSSL_DEBUG_MEMORY 438 #ifndef WOLFSSL_STATIC_MEMORY 439 #define NO_WOLFSSL_MEMORY 451 #define WOLFSSL_USER_CURRTIME 452 #define WOLFSSL_GMTIME 454 extern unsigned long my_time(
unsigned long* timer);
455 #define XTIME my_time 464 #define CUSTOM_RAND_TYPE unsigned int 465 extern unsigned int my_rng_seed_gen(
void);
466 #undef CUSTOM_RAND_GENERATE 467 #define CUSTOM_RAND_GENERATE my_rng_seed_gen 474 #define HAVE_HASHDRBG 476 #undef WC_NO_HASHDRBG 477 #define WC_NO_HASHDRBG 480 extern int my_rng_gen_block(
unsigned char* output,
unsigned int sz);
481 #undef CUSTOM_RAND_GENERATE_BLOCK 482 #define CUSTOM_RAND_GENERATE_BLOCK my_rng_gen_block 496 #undef USE_WOLF_STRSEP 497 #define USE_WOLF_STRSEP 498 #define XSTRSEP(s1,d) wc_strsep((s1),(d)) 500 #undef USE_WOLF_STRTOK 501 #define USE_WOLF_STRTOK 502 #define XSTRTOK(s1,d,ptr) wc_strtok((s1),(d),(ptr)) 504 #define XSTRNSTR(s1,s2,n) mystrnstr((s1),(s2),(n)) 506 #define XMEMCPY(d,s,l) memcpy((d),(s),(l)) 507 #define XMEMSET(b,c,l) memset((b),(c),(l)) 508 #define XMEMCMP(s1,s2,n) memcmp((s1),(s2),(n)) 509 #define XMEMMOVE(d,s,l) memmove((d),(s),(l)) 511 #define XSTRLEN(s1) strlen((s1)) 512 #define XSTRNCPY(s1,s2,n) strncpy((s1),(s2),(n)) 513 #define XSTRSTR(s1,s2) strstr((s1),(s2)) 515 #define XSTRNCMP(s1,s2,n) strncmp((s1),(s2),(n)) 516 #define XSTRNCAT(s1,s2,n) strncat((s1),(s2),(n)) 517 #define XSTRNCASECMP(s1,s2,n) strncasecmp((s1),(s2),(n)) 519 #define XSNPRINTF snprintf 529 #define WOLFSSL_TLS13 532 #undef WOLFSSL_KEY_GEN 534 #define WOLFSSL_KEY_GEN 537 #if defined(HAVE_FIPS) && !defined(WOLFSSL_KEY_GEN) 538 #define WOLFSSL_OLD_PRIME_CHECK 541 #undef KEEP_PEER_CERT 547 #undef HAVE_TLS_EXTENSIONS 548 #define HAVE_TLS_EXTENSIONS 550 #undef HAVE_SUPPORTED_CURVES 551 #define HAVE_SUPPORTED_CURVES 553 #undef WOLFSSL_BASE64_ENCODE 554 #define WOLFSSL_BASE64_ENCODE 558 #define SMALL_SESSION_CACHE 560 #define NO_SESSION_CACHE 567 #undef NO_WOLFSSL_SERVER 570 #undef NO_WOLFSSL_CLIENT 576 #undef NO_CRYPT_BENCHMARK 579 #undef WOLFCRYPT_ONLY 589 #define NO_FILESYSTEM 594 #undef NO_MAIN_DRIVER 595 #define NO_MAIN_DRIVER 598 #define NO_DEV_RANDOM 633 #undef NO_SIG_WRAPPER