1 /* user_setting.h
2  *
3  * Copyright (C) 2006-2021 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 
22 #ifndef DEOS_USER_SETTINGS_H_
23 #define DEOS_USER_SETTINGS_H_
24 
25 #ifdef __cplusplus
26     extern "C" {
27 #endif
28 
29 #define WOLFSSL_DEOS
30 
31 /* You can select none or all of the following tests
32 using #define instead of #undef.
33 By default, all four tests run*/
34 
35 #undef NO_CRYPT_TEST
36 #undef NO_CRYPT_BENCHMARK
37 #undef NO_WOLFSSL_CLIENT
38 #undef NO_WOLFSSL_SERVER
39 
40 /* adjust CURRENT_UNIX_TIMESTAMP to seconds since Jan 01 1970. (UTC)
41 You can get the current time from https://www.unixtimestamp.com/
42 */
43 #define CURRENT_UNIX_TIMESTAMP 1545864916
44 
45 #define NO_FILESYSTEM
46 #define SIZEOF_LONG_LONG 8
47 
48 /* prevents from including multiple definition of main() */
49 #define NO_MAIN_DRIVER
50 #define NO_TESTSUITE_MAIN_DRIVER
51 
52 /* includes certificate test buffers via header files */
53 #define USE_CERT_BUFFERS_2048
54 
55 /*use kB instead of mB for embedded benchmarking*/
56 #define BENCH_EMBEDDED
57 
58 #define NO_WRITE_TEMP_FILES
59 
60 #define HAVE_AESGCM
61 #define WOLFSSL_SHA512
62 #define HAVE_ECC
63 #define HAVE_CURVE25519
64 #define CURVE25519_SMALL
65 #define HAVE_ED25519
66 #define ED25519_SMALL
67 
68 #define WOLFSSL_DTLS
69 
70 /* TLS 1.3 */
71 #if 0
72     #define WOLFSSL_TLS13
73     #define WC_RSA_PSS
74     #define HAVE_HKDF
75     #define HAVE_FFDHE_2048
76     #define HAVE_AEAD
77 #endif
78 
79 #if 0
80 
81 /* You can use your own custom random generator function with
82    no input parameters and a `CUSTOM_RAND_TYPE` return type*/
83 
84     #ifndef CUSTOM_RAND_GENERATE
85          #define CUSTOM_RAND_TYPE     int
86          #define CUSTOM_RAND_GENERATE yourRandGenFunc
87     #endif
88 
89 #endif
90 
91 #if 1
92     #undef  XMALLOC_OVERRIDE
93     #define XMALLOC_OVERRIDE
94     /* prototypes for user heap override functions */
95 
96     #include <stddef.h>  /* for size_t */
97 
98     extern void *malloc_deos(size_t size);
99     extern void  free_deos(void *ptr);
100     extern void *realloc_deos(void *ptr, size_t size);
101 
102     #define XMALLOC(n, h, t)     malloc_deos(n)
103     #define XFREE(p, h, t)       free_deos(p)
104     #define XREALLOC(p, n, h, t) realloc_deos(p, n)
105 
106 #endif
107 
108 #ifdef __cplusplus
109     }   /* extern "C" */
110 #endif
111 
112 #endif
113