1 /* config.h. Generated from config.h.in by configure. */
2 /* config.h.in. Generated from configure.ac by autoheader. */
4 /* apply the noreturn attribute to a function that exits the program */
5 #define ATTR_NORETURN __attribute__((__noreturn__))
7 /* apply the weak attribute to a symbol */
8 #define ATTR_WEAK __attribute__((weak))
10 /* Directory to chroot to */
11 #define CHROOT_DIR "/var/unbound"
13 /* Define this to enable client subnet option. */
14 /* #undef CLIENT_SUBNET */
16 /* Do sha512 definitions in config.h */
17 /* #undef COMPAT_SHA512 */
19 /* Command line arguments used with configure */
20 #define CONFCMDLINE "--with-ssl=/usr --with-libexpat=/usr --disable-dnscrypt --disable-dnstap --enable-ecdsa --disable-event-api --enable-gost --with-libevent --disable-subnet --disable-tfo-client --disable-tfo-server --with-pthreads--prefix=/usr --localstatedir=/var/unbound --mandir=/usr/share/man --build=freebsd"
22 /* Pathname to the Unbound configuration file */
23 #define CONFIGFILE "/var/unbound/unbound.conf"
25 /* Define this if on macOSX10.4-darwin8 and setreuid and setregid do not work
27 /* #undef DARWIN_BROKEN_SETREUID */
29 /* Whether daemon is deprecated */
30 /* #undef DEPRECATED_DAEMON */
32 /* default dnstap socket path */
33 /* #undef DNSTAP_SOCKET_PATH */
35 /* Define if you want to use debug lock checking (slow). */
36 /* #undef ENABLE_LOCK_CHECKS */
38 /* Define this if you enabled-allsymbols from libunbound to link binaries to
39 it for smaller install size, but the libunbound export table is polluted by
41 /* #undef EXPORT_ALL_SYMBOLS */
43 /* Define to 1 if you have the `accept4' function. */
44 #define HAVE_ACCEPT4 1
46 /* Define to 1 if you have the `arc4random' function. */
47 #define HAVE_ARC4RANDOM 1
49 /* Define to 1 if you have the `arc4random_uniform' function. */
50 #define HAVE_ARC4RANDOM_UNIFORM 1
52 /* Define to 1 if you have the <arpa/inet.h> header file. */
53 #define HAVE_ARPA_INET_H 1
55 /* Whether the C compiler accepts the "format" attribute */
56 #define HAVE_ATTR_FORMAT 1
58 /* Whether the C compiler accepts the "noreturn" attribute */
59 #define HAVE_ATTR_NORETURN 1
61 /* Whether the C compiler accepts the "unused" attribute */
62 #define HAVE_ATTR_UNUSED 1
64 /* Whether the C compiler accepts the "weak" attribute */
65 #define HAVE_ATTR_WEAK 1
67 /* Define to 1 if you have the `chown' function. */
70 /* Define to 1 if you have the `chroot' function. */
73 /* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */
74 /* #undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA */
76 /* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */
77 /* #undef HAVE_CRYPTO_THREADID_SET_CALLBACK */
79 /* Define to 1 if you have the `ctime_r' function. */
80 #define HAVE_CTIME_R 1
82 /* Define to 1 if you have the `daemon' function. */
85 /* Define to 1 if you have the declaration of `arc4random', and to 0 if you
87 /* #undef HAVE_DECL_ARC4RANDOM */
89 /* Define to 1 if you have the declaration of `arc4random_uniform', and to 0
91 /* #undef HAVE_DECL_ARC4RANDOM_UNIFORM */
93 /* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if
95 /* #undef HAVE_DECL_EVSIGNAL_ASSIGN */
97 /* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you
99 #define HAVE_DECL_INET_NTOP 1
101 /* Define to 1 if you have the declaration of `inet_pton', and to 0 if you
103 #define HAVE_DECL_INET_PTON 1
105 /* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you
107 #define HAVE_DECL_NID_ED25519 1
109 /* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you
111 #define HAVE_DECL_NID_ED448 1
113 /* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you
115 #define HAVE_DECL_NID_SECP384R1 1
117 /* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0
119 #define HAVE_DECL_NID_X9_62_PRIME256V1 1
121 /* Define to 1 if you have the declaration of `reallocarray', and to 0 if you
123 #define HAVE_DECL_REALLOCARRAY 1
125 /* Define to 1 if you have the declaration of `redisConnect', and to 0 if you
127 /* #undef HAVE_DECL_REDISCONNECT */
129 /* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0
131 #define HAVE_DECL_SK_SSL_COMP_POP_FREE 1
133 /* Define to 1 if you have the declaration of
134 `SSL_COMP_get_compression_methods', and to 0 if you don't. */
135 #define HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS 1
137 /* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to
139 #define HAVE_DECL_SSL_CTX_SET_ECDH_AUTO 1
141 /* Define to 1 if you have the declaration of `strlcat', and to 0 if you
143 /* #undef HAVE_DECL_STRLCAT */
145 /* Define to 1 if you have the declaration of `strlcpy', and to 0 if you
147 /* #undef HAVE_DECL_STRLCPY */
149 /* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if
151 #define HAVE_DECL_XML_STOPPARSER 1
153 /* Define to 1 if you have the <dlfcn.h> header file. */
154 #define HAVE_DLFCN_H 1
156 /* Define to 1 if you have the `DSA_SIG_set0' function. */
157 #define HAVE_DSA_SIG_SET0 1
159 /* Define to 1 if you have the <endian.h> header file. */
160 /* #undef HAVE_ENDIAN_H */
162 /* Define to 1 if you have the `endprotoent' function. */
163 #define HAVE_ENDPROTOENT 1
165 /* Define to 1 if you have the `endpwent' function. */
166 #define HAVE_ENDPWENT 1
168 /* Define to 1 if you have the `endservent' function. */
169 #define HAVE_ENDSERVENT 1
171 /* Define to 1 if you have the `ERR_free_strings' function. */
172 /* #undef HAVE_ERR_FREE_STRINGS */
174 /* Define to 1 if you have the `ERR_load_crypto_strings' function. */
175 /* #undef HAVE_ERR_LOAD_CRYPTO_STRINGS */
177 /* Define to 1 if you have the `event_assign' function. */
178 /* #undef HAVE_EVENT_ASSIGN */
180 /* Define to 1 if you have the `event_base_free' function. */
181 /* #undef HAVE_EVENT_BASE_FREE */
183 /* Define to 1 if you have the `event_base_get_method' function. */
184 /* #undef HAVE_EVENT_BASE_GET_METHOD */
186 /* Define to 1 if you have the `event_base_new' function. */
187 /* #undef HAVE_EVENT_BASE_NEW */
189 /* Define to 1 if you have the `event_base_once' function. */
190 /* #undef HAVE_EVENT_BASE_ONCE */
192 /* Define to 1 if you have the <event.h> header file. */
193 /* #undef HAVE_EVENT_H */
195 /* Define to 1 if you have the `EVP_aes_256_cbc' function. */
196 #define HAVE_EVP_AES_256_CBC 1
198 /* Define to 1 if you have the `EVP_cleanup' function. */
199 /* #undef HAVE_EVP_CLEANUP */
201 /* Define to 1 if you have the `EVP_DigestVerify' function. */
202 #define HAVE_EVP_DIGESTVERIFY 1
204 /* Define to 1 if you have the `EVP_dss1' function. */
205 /* #undef HAVE_EVP_DSS1 */
207 /* Define to 1 if you have the `EVP_EncryptInit_ex' function. */
208 #define HAVE_EVP_ENCRYPTINIT_EX 1
210 /* Define to 1 if you have the `EVP_MD_CTX_new' function. */
211 #define HAVE_EVP_MD_CTX_NEW 1
213 /* Define to 1 if you have the `EVP_sha1' function. */
214 #define HAVE_EVP_SHA1 1
216 /* Define to 1 if you have the `EVP_sha256' function. */
217 #define HAVE_EVP_SHA256 1
219 /* Define to 1 if you have the `EVP_sha512' function. */
220 #define HAVE_EVP_SHA512 1
222 /* Define to 1 if you have the `ev_default_loop' function. */
223 /* #undef HAVE_EV_DEFAULT_LOOP */
225 /* Define to 1 if you have the `ev_loop' function. */
226 /* #undef HAVE_EV_LOOP */
228 /* Define to 1 if you have the <expat.h> header file. */
229 #define HAVE_EXPAT_H 1
231 /* Define to 1 if you have the `explicit_bzero' function. */
232 #define HAVE_EXPLICIT_BZERO 1
234 /* Define to 1 if you have the `fcntl' function. */
237 /* Define to 1 if you have the `FIPS_mode' function. */
238 #define HAVE_FIPS_MODE 1
240 /* Define to 1 if you have the `fork' function. */
243 /* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
244 #define HAVE_FSEEKO 1
246 /* Define to 1 if you have the `fsync' function. */
249 /* Whether getaddrinfo is available */
250 #define HAVE_GETADDRINFO 1
252 /* Define to 1 if you have the `getauxval' function. */
253 /* #undef HAVE_GETAUXVAL */
255 /* Define to 1 if you have the `getentropy' function. */
256 /* #undef HAVE_GETENTROPY */
258 /* Define to 1 if you have the <getopt.h> header file. */
259 #define HAVE_GETOPT_H 1
261 /* Define to 1 if you have the `getpwnam' function. */
262 #define HAVE_GETPWNAM 1
264 /* Define to 1 if you have the `getrlimit' function. */
265 #define HAVE_GETRLIMIT 1
267 /* Define to 1 if you have the `glob' function. */
270 /* Define to 1 if you have the <glob.h> header file. */
271 #define HAVE_GLOB_H 1
273 /* Define to 1 if you have the `gmtime_r' function. */
274 #define HAVE_GMTIME_R 1
276 /* Define to 1 if you have the <grp.h> header file. */
279 /* Define to 1 if you have the <hiredis/hiredis.h> header file. */
280 /* #undef HAVE_HIREDIS_HIREDIS_H */
282 /* Define to 1 if you have the `HMAC_Init_ex' function. */
283 #define HAVE_HMAC_INIT_EX 1
285 /* If you have HMAC_Update */
286 #define HAVE_HMAC_UPDATE 1
288 /* Define to 1 if you have the `inet_aton' function. */
289 #define HAVE_INET_ATON 1
291 /* Define to 1 if you have the `inet_ntop' function. */
292 #define HAVE_INET_NTOP 1
294 /* Define to 1 if you have the `inet_pton' function. */
295 #define HAVE_INET_PTON 1
297 /* Define to 1 if you have the `initgroups' function. */
298 #define HAVE_INITGROUPS 1
300 /* Define to 1 if you have the <inttypes.h> header file. */
301 #define HAVE_INTTYPES_H 1
303 /* if the function 'ioctlsocket' is available */
304 /* #undef HAVE_IOCTLSOCKET */
306 /* Define to 1 if you have the <iphlpapi.h> header file. */
307 /* #undef HAVE_IPHLPAPI_H */
309 /* Define to 1 if you have the `isblank' function. */
310 #define HAVE_ISBLANK 1
312 /* Define to 1 if you have the `kill' function. */
315 /* Define to 1 if you have the <libkern/OSByteOrder.h> header file. */
316 /* #undef HAVE_LIBKERN_OSBYTEORDER_H */
318 /* Define if we have LibreSSL */
319 /* #undef HAVE_LIBRESSL */
321 /* Define to 1 if you have the `localtime_r' function. */
322 #define HAVE_LOCALTIME_R 1
324 /* Define to 1 if you have the <login_cap.h> header file. */
325 #define HAVE_LOGIN_CAP_H 1
327 /* If have GNU libc compatible malloc */
328 #define HAVE_MALLOC 1
330 /* Define to 1 if you have the `memmove' function. */
331 #define HAVE_MEMMOVE 1
333 /* Define to 1 if you have the <memory.h> header file. */
334 #define HAVE_MEMORY_H 1
336 /* Define to 1 if you have the <netdb.h> header file. */
337 #define HAVE_NETDB_H 1
339 /* Define to 1 if you have the <netinet/in.h> header file. */
340 #define HAVE_NETINET_IN_H 1
342 /* Define to 1 if you have the <netinet/tcp.h> header file. */
343 #define HAVE_NETINET_TCP_H 1
345 /* Use libnettle for crypto */
346 /* #undef HAVE_NETTLE */
348 /* Define to 1 if you have the <nettle/dsa-compat.h> header file. */
349 /* #undef HAVE_NETTLE_DSA_COMPAT_H */
351 /* Define to 1 if you have the <nettle/eddsa.h> header file. */
352 /* #undef HAVE_NETTLE_EDDSA_H */
354 /* Use libnss for crypto */
355 /* #undef HAVE_NSS */
357 /* Define to 1 if you have the `OpenSSL_add_all_digests' function. */
358 /* #undef HAVE_OPENSSL_ADD_ALL_DIGESTS */
360 /* Define to 1 if you have the <openssl/bn.h> header file. */
361 #define HAVE_OPENSSL_BN_H 1
363 /* Define to 1 if you have the `OPENSSL_config' function. */
364 #define HAVE_OPENSSL_CONFIG 1
366 /* Define to 1 if you have the <openssl/conf.h> header file. */
367 #define HAVE_OPENSSL_CONF_H 1
369 /* Define to 1 if you have the <openssl/dh.h> header file. */
370 #define HAVE_OPENSSL_DH_H 1
372 /* Define to 1 if you have the <openssl/dsa.h> header file. */
373 #define HAVE_OPENSSL_DSA_H 1
375 /* Define to 1 if you have the <openssl/engine.h> header file. */
376 #define HAVE_OPENSSL_ENGINE_H 1
378 /* Define to 1 if you have the <openssl/err.h> header file. */
379 #define HAVE_OPENSSL_ERR_H 1
381 /* Define to 1 if you have the `OPENSSL_init_crypto' function. */
382 #define HAVE_OPENSSL_INIT_CRYPTO 1
384 /* Define to 1 if you have the `OPENSSL_init_ssl' function. */
385 #define HAVE_OPENSSL_INIT_SSL 1
387 /* Define to 1 if you have the <openssl/rand.h> header file. */
388 #define HAVE_OPENSSL_RAND_H 1
390 /* Define to 1 if you have the <openssl/rsa.h> header file. */
391 #define HAVE_OPENSSL_RSA_H 1
393 /* Define to 1 if you have the <openssl/ssl.h> header file. */
394 #define HAVE_OPENSSL_SSL_H 1
396 /* Define if you have POSIX threads libraries and header files. */
397 #define HAVE_PTHREAD 1
399 /* Have PTHREAD_PRIO_INHERIT. */
400 #define HAVE_PTHREAD_PRIO_INHERIT 1
402 /* Define to 1 if the system has the type `pthread_rwlock_t'. */
403 #define HAVE_PTHREAD_RWLOCK_T 1
405 /* Define to 1 if the system has the type `pthread_spinlock_t'. */
406 #define HAVE_PTHREAD_SPINLOCK_T 1
408 /* Define to 1 if you have the <pwd.h> header file. */
411 /* Define if you have Python libraries and header files. */
412 /* #undef HAVE_PYTHON */
414 /* Define to 1 if you have the `random' function. */
415 #define HAVE_RANDOM 1
417 /* Define to 1 if you have the `RAND_cleanup' function. */
418 /* #undef HAVE_RAND_CLEANUP */
420 /* If we have reallocarray(3) */
421 #define HAVE_REALLOCARRAY 1
423 /* Define to 1 if you have the `recvmsg' function. */
424 #define HAVE_RECVMSG 1
426 /* Define to 1 if you have the `sendmsg' function. */
427 #define HAVE_SENDMSG 1
429 /* Define to 1 if you have the `setregid' function. */
430 /* #undef HAVE_SETREGID */
432 /* Define to 1 if you have the `setresgid' function. */
433 #define HAVE_SETRESGID 1
435 /* Define to 1 if you have the `setresuid' function. */
436 #define HAVE_SETRESUID 1
438 /* Define to 1 if you have the `setreuid' function. */
439 /* #undef HAVE_SETREUID */
441 /* Define to 1 if you have the `setrlimit' function. */
442 #define HAVE_SETRLIMIT 1
444 /* Define to 1 if you have the `setsid' function. */
445 #define HAVE_SETSID 1
447 /* Define to 1 if you have the `setusercontext' function. */
448 #define HAVE_SETUSERCONTEXT 1
450 /* Define to 1 if you have the `SHA512_Update' function. */
451 /* #undef HAVE_SHA512_UPDATE */
453 /* Define to 1 if you have the `shmget' function. */
454 #define HAVE_SHMGET 1
456 /* Define to 1 if you have the `sigprocmask' function. */
457 #define HAVE_SIGPROCMASK 1
459 /* Define to 1 if you have the `sleep' function. */
462 /* Define to 1 if you have the `snprintf' function. */
463 #define HAVE_SNPRINTF 1
465 /* Define to 1 if you have the `socketpair' function. */
466 #define HAVE_SOCKETPAIR 1
468 /* Using Solaris threads */
469 /* #undef HAVE_SOLARIS_THREADS */
471 /* Define to 1 if you have the `srandom' function. */
472 #define HAVE_SRANDOM 1
474 /* Define if you have the SSL libraries installed. */
475 #define HAVE_SSL /**/
477 /* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */
478 #define HAVE_SSL_CTX_SET_CIPHERSUITES 1
480 /* Define to 1 if you have the `SSL_CTX_set_security_level' function. */
481 #define HAVE_SSL_CTX_SET_SECURITY_LEVEL 1
483 /* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_cb' function. */
484 /* #undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_CB */
486 /* Define to 1 if you have the `SSL_get0_peername' function. */
487 #define HAVE_SSL_GET0_PEERNAME 1
489 /* Define to 1 if you have the `SSL_set1_host' function. */
490 #define HAVE_SSL_SET1_HOST 1
492 /* Define to 1 if you have the <stdarg.h> header file. */
493 #define HAVE_STDARG_H 1
495 /* Define to 1 if you have the <stdbool.h> header file. */
496 #define HAVE_STDBOOL_H 1
498 /* Define to 1 if you have the <stdint.h> header file. */
499 #define HAVE_STDINT_H 1
501 /* Define to 1 if you have the <stdlib.h> header file. */
502 #define HAVE_STDLIB_H 1
504 /* Define to 1 if you have the `strftime' function. */
505 #define HAVE_STRFTIME 1
507 /* Define to 1 if you have the <strings.h> header file. */
508 #define HAVE_STRINGS_H 1
510 /* Define to 1 if you have the <string.h> header file. */
511 #define HAVE_STRING_H 1
513 /* Define to 1 if you have the `strlcat' function. */
514 #define HAVE_STRLCAT 1
516 /* Define to 1 if you have the `strlcpy' function. */
517 #define HAVE_STRLCPY 1
519 /* Define to 1 if you have the `strptime' function. */
520 #define HAVE_STRPTIME 1
522 /* Define to 1 if you have the `strsep' function. */
523 #define HAVE_STRSEP 1
525 /* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */
526 /* #undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST */
528 /* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */
529 #define HAVE_STRUCT_SOCKADDR_UN_SUN_LEN 1
531 /* Define if you have Swig libraries and header files. */
532 /* #undef HAVE_SWIG */
534 /* Define to 1 if you have the <syslog.h> header file. */
535 #define HAVE_SYSLOG_H 1
537 /* Define to 1 if systemd should be used */
538 /* #undef HAVE_SYSTEMD */
540 /* Define to 1 if you have the <sys/endian.h> header file. */
541 #define HAVE_SYS_ENDIAN_H 1
543 /* Define to 1 if you have the <sys/ipc.h> header file. */
544 #define HAVE_SYS_IPC_H 1
546 /* Define to 1 if you have the <sys/param.h> header file. */
547 #define HAVE_SYS_PARAM_H 1
549 /* Define to 1 if you have the <sys/resource.h> header file. */
550 #define HAVE_SYS_RESOURCE_H 1
552 /* Define to 1 if you have the <sys/sha2.h> header file. */
553 /* #undef HAVE_SYS_SHA2_H */
555 /* Define to 1 if you have the <sys/shm.h> header file. */
556 #define HAVE_SYS_SHM_H 1
558 /* Define to 1 if you have the <sys/socket.h> header file. */
559 #define HAVE_SYS_SOCKET_H 1
561 /* Define to 1 if you have the <sys/stat.h> header file. */
562 #define HAVE_SYS_STAT_H 1
564 /* Define to 1 if you have the <sys/sysctl.h> header file. */
565 /* #undef HAVE_SYS_SYSCTL_H */
567 /* Define to 1 if you have the <sys/types.h> header file. */
568 #define HAVE_SYS_TYPES_H 1
570 /* Define to 1 if you have the <sys/uio.h> header file. */
571 #define HAVE_SYS_UIO_H 1
573 /* Define to 1 if you have the <sys/un.h> header file. */
574 #define HAVE_SYS_UN_H 1
576 /* Define to 1 if you have the <sys/wait.h> header file. */
577 #define HAVE_SYS_WAIT_H 1
579 /* Define to 1 if you have the <time.h> header file. */
580 #define HAVE_TIME_H 1
582 /* Define to 1 if you have the `tzset' function. */
585 /* Define to 1 if you have the <unistd.h> header file. */
586 #define HAVE_UNISTD_H 1
588 /* Define to 1 if you have the `usleep' function. */
589 #define HAVE_USLEEP 1
591 /* Define to 1 if you have the `vfork' function. */
594 /* Define to 1 if you have the <vfork.h> header file. */
595 /* #undef HAVE_VFORK_H */
597 /* Define to 1 if you have the <windows.h> header file. */
598 /* #undef HAVE_WINDOWS_H */
600 /* Using Windows threads */
601 /* #undef HAVE_WINDOWS_THREADS */
603 /* Define to 1 if you have the <winsock2.h> header file. */
604 /* #undef HAVE_WINSOCK2_H */
606 /* Define to 1 if `fork' works. */
607 #define HAVE_WORKING_FORK 1
609 /* Define to 1 if `vfork' works. */
610 #define HAVE_WORKING_VFORK 1
612 /* Define to 1 if you have the `writev' function. */
613 #define HAVE_WRITEV 1
615 /* Define to 1 if you have the <ws2tcpip.h> header file. */
616 /* #undef HAVE_WS2TCPIP_H */
618 /* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */
619 #define HAVE_X509_VERIFY_PARAM_SET1_HOST 1
621 /* Define to 1 if you have the `_beginthreadex' function. */
622 /* #undef HAVE__BEGINTHREADEX */
624 /* If HMAC_Init_ex() returns void */
625 /* #undef HMAC_INIT_EX_RETURNS_VOID */
627 /* if lex has yylex_destroy */
628 #define LEX_HAS_YYLEX_DESTROY 1
630 /* Define to the sub-directory where libtool stores uninstalled libraries. */
631 #define LT_OBJDIR ".libs/"
633 /* Define to the maximum message length to pass to syslog. */
634 #define MAXSYSLOGMSGLEN 10240
636 /* Define if memcmp() does not compare unsigned bytes */
637 /* #undef MEMCMP_IS_BROKEN */
639 /* Define if mkdir has one argument. */
640 /* #undef MKDIR_HAS_ONE_ARG */
642 /* Define if the network stack does not fully support nonblocking io (causes
643 lower performance). */
644 /* #undef NONBLOCKING_IS_BROKEN */
646 /* Put -D_ALL_SOURCE define in config.h */
647 /* #undef OMITTED__D_ALL_SOURCE */
649 /* Put -D_BSD_SOURCE define in config.h */
650 /* #undef OMITTED__D_BSD_SOURCE */
652 /* Put -D_DEFAULT_SOURCE define in config.h */
653 /* #undef OMITTED__D_DEFAULT_SOURCE */
655 /* Put -D_GNU_SOURCE define in config.h */
656 /* #undef OMITTED__D_GNU_SOURCE */
658 /* Put -D_LARGEFILE_SOURCE=1 define in config.h */
659 /* #undef OMITTED__D_LARGEFILE_SOURCE_1 */
661 /* Put -D_POSIX_C_SOURCE=200112 define in config.h */
662 /* #undef OMITTED__D_POSIX_C_SOURCE_200112 */
664 /* Put -D_XOPEN_SOURCE=600 define in config.h */
665 /* #undef OMITTED__D_XOPEN_SOURCE_600 */
667 /* Put -D_XOPEN_SOURCE_EXTENDED=1 define in config.h */
668 /* #undef OMITTED__D_XOPEN_SOURCE_EXTENDED_1 */
670 /* Put -D__EXTENSIONS__ define in config.h */
671 /* #undef OMITTED__D__EXTENSIONS__ */
673 /* Define to the address where bug reports for this package should be sent. */
674 #define PACKAGE_BUGREPORT "unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues"
676 /* Define to the full name of this package. */
677 #define PACKAGE_NAME "unbound"
679 /* Define to the full name and version of this package. */
680 #define PACKAGE_STRING "unbound 1.9.6"
682 /* Define to the one symbol short name of this package. */
683 #define PACKAGE_TARNAME "unbound"
685 /* Define to the home page for this package. */
686 #define PACKAGE_URL ""
688 /* Define to the version of this package. */
689 #define PACKAGE_VERSION "1.9.6"
691 /* default pidfile location */
692 #define PIDFILE "/var/unbound/unbound.pid"
694 /* Define to necessary symbol if this constant uses a non-standard name on
696 /* #undef PTHREAD_CREATE_JOINABLE */
698 /* Define as the return type of signal handlers (`int' or `void'). */
699 #define RETSIGTYPE void
701 /* if REUSEPORT is enabled by default */
702 #define REUSEPORT_DEFAULT 0
704 /* default rootkey location */
705 #define ROOT_ANCHOR_FILE "/var/unbound/root.key"
707 /* default rootcert location */
708 #define ROOT_CERT_FILE "/var/unbound/icannbundle.pem"
710 /* version number for resource files */
711 #define RSRC_PACKAGE_VERSION 1,9,6,0
713 /* Directory to chdir to */
714 #define RUN_DIR "/var/unbound"
717 #define SHARE_DIR "/var/unbound"
719 /* The size of `size_t'. */
721 #define SIZEOF_SIZE_T 8
723 #define SIZEOF_SIZE_T 4
726 /* The size of `time_t', as computed by sizeof. */
728 #define SIZEOF_TIME_T 4
730 #define SIZEOF_TIME_T 8
733 /* define if (v)snprintf does not return length needed, (but length used) */
734 /* #undef SNPRINTF_RET_BROKEN */
736 /* Define to 1 if libsodium supports sodium_set_misuse_handler */
737 /* #undef SODIUM_MISUSE_HANDLER */
739 /* Define to 1 if you have the ANSI C header files. */
740 #define STDC_HEADERS 1
742 /* use default strptime. */
743 #define STRPTIME_WORKS 1
745 /* Use win32 resources and API */
746 /* #undef UB_ON_WINDOWS */
748 /* the SYSLOG_FACILITY to use, default LOG_DAEMON */
749 #define UB_SYSLOG_FACILITY LOG_DAEMON
751 /* default username */
752 #define UB_USERNAME "unbound"
754 /* use to enable lightweight alloc assertions, for debug use */
755 /* #undef UNBOUND_ALLOC_LITE */
757 /* use malloc not regions, for debug use */
758 /* #undef UNBOUND_ALLOC_NONREGIONAL */
760 /* use statistics for allocs and frees, for debug use */
761 /* #undef UNBOUND_ALLOC_STATS */
763 /* define this to enable debug checks. */
764 /* #undef UNBOUND_DEBUG */
766 /* Define to 1 to use cachedb support */
767 /* #undef USE_CACHEDB */
769 /* Define to 1 to enable dnscrypt support */
770 /* #undef USE_DNSCRYPT */
772 /* Define to 1 to enable dnscrypt with xchacha20 support */
773 /* #undef USE_DNSCRYPT_XCHACHA20 */
775 /* Define to 1 to enable dnstap support */
776 /* #undef USE_DNSTAP */
778 /* Define this to enable DSA support. */
781 /* Define this to enable ECDSA support. */
784 /* Define this to enable an EVP workaround for older openssl */
785 /* #undef USE_ECDSA_EVP_WORKAROUND */
787 /* Define this to enable ED25519 support. */
788 #define USE_ED25519 1
790 /* Define this to enable ED448 support. */
793 /* Define this to enable GOST support. */
794 /* #undef USE_GOST */
796 /* Define to 1 to use ipsecmod support. */
797 /* #undef USE_IPSECMOD */
799 /* Define to 1 to use ipset support */
800 /* #undef USE_IPSET */
802 /* Define if you want to use internal select based events */
803 #define USE_MINI_EVENT 1
805 /* Define this to enable client TCP Fast Open. */
806 /* #undef USE_MSG_FASTOPEN */
808 /* Define this to enable client TCP Fast Open. */
809 /* #undef USE_OSX_MSG_FASTOPEN */
811 /* Define this to use hiredis client. */
812 /* #undef USE_REDIS */
814 /* Define this to enable SHA1 support. */
817 /* Define this to enable SHA256 and SHA512 support. */
820 /* Enable extensions on AIX 3, Interix. */
822 # define _ALL_SOURCE 1
824 /* Enable GNU extensions on systems that have them. */
826 # define _GNU_SOURCE 1
828 /* Enable threading extensions on Solaris. */
829 #ifndef _POSIX_PTHREAD_SEMANTICS
830 # define _POSIX_PTHREAD_SEMANTICS 1
832 /* Enable extensions on HP NonStop. */
833 #ifndef _TANDEM_SOURCE
834 # define _TANDEM_SOURCE 1
836 /* Enable general extensions on Solaris. */
837 #ifndef __EXTENSIONS__
838 # define __EXTENSIONS__ 1
842 /* Define this to enable server TCP Fast Open. */
843 /* #undef USE_TCP_FASTOPEN */
845 /* Whether the windows socket API is used */
846 /* #undef USE_WINSOCK */
848 /* the version of the windows API enabled */
849 #define WINVER 0x0502
851 /* Define if you want Python module. */
852 /* #undef WITH_PYTHONMODULE */
854 /* Define if you want PyUnbound. */
855 /* #undef WITH_PYUNBOUND */
857 /* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
859 #define YYTEXT_POINTER 1
861 /* Enable large inode numbers on Mac OS X 10.5. */
862 #ifndef _DARWIN_USE_64_BIT_INODE
863 # define _DARWIN_USE_64_BIT_INODE 1
866 /* Number of bits in a file offset, on hosts where this is settable. */
867 /* #undef _FILE_OFFSET_BITS */
869 /* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
870 /* #undef _LARGEFILE_SOURCE */
872 /* Define for large files, on AIX-style hosts. */
873 /* #undef _LARGE_FILES */
875 /* Define to 1 if on MINIX. */
878 /* Enable for compile on Minix */
879 /* #undef _NETBSD_SOURCE */
881 /* Define to 2 if the system does not provide POSIX.1 features except with
883 /* #undef _POSIX_1_SOURCE */
885 /* Define to 1 if you need to in order for `stat' and other things to work. */
886 /* #undef _POSIX_SOURCE */
888 /* Define to empty if `const' does not conform to ANSI C. */
891 /* Define to `int' if <sys/types.h> doesn't define. */
895 /* #undef in_addr_t */
898 /* #undef in_port_t */
900 /* Define to `__inline__' or `__inline' if that's what the C compiler
901 calls it, or to nothing if 'inline' is not supported under any name. */
906 /* Define to `short' if <sys/types.h> does not define. */
909 /* Define to `int' if <sys/types.h> does not define. */
912 /* Define to `long long' if <sys/types.h> does not define. */
915 /* Define to `signed char' if <sys/types.h> does not define. */
918 /* Define if replacement function should be used. */
921 /* Define to `long int' if <sys/types.h> does not define. */
924 /* Define to `int' if <sys/types.h> does not define. */
927 /* Define to 'int' if not defined */
930 /* Define to `unsigned int' if <sys/types.h> does not define. */
933 /* Define to 'int' if not defined */
934 /* #undef socklen_t */
936 /* Define to `int' if <sys/types.h> does not define. */
939 /* Define to 'unsigned char if not defined */
942 /* Define to `int' if <sys/types.h> doesn't define. */
945 /* Define to `unsigned short' if <sys/types.h> does not define. */
946 /* #undef uint16_t */
948 /* Define to `unsigned int' if <sys/types.h> does not define. */
949 /* #undef uint32_t */
951 /* Define to `unsigned long long' if <sys/types.h> does not define. */
952 /* #undef uint64_t */
954 /* Define to `unsigned char' if <sys/types.h> does not define. */
957 /* Define as `fork' if `vfork' does not work. */
960 #if defined(OMITTED__D_GNU_SOURCE) && !defined(_GNU_SOURCE)
961 #define _GNU_SOURCE 1
964 #if defined(OMITTED__D_BSD_SOURCE) && !defined(_BSD_SOURCE)
965 #define _BSD_SOURCE 1
968 #if defined(OMITTED__D_DEFAULT_SOURCE) && !defined(_DEFAULT_SOURCE)
969 #define _DEFAULT_SOURCE 1
972 #if defined(OMITTED__D__EXTENSIONS__) && !defined(__EXTENSIONS__)
973 #define __EXTENSIONS__ 1
976 #if defined(OMITTED__D_POSIX_C_SOURCE_200112) && !defined(_POSIX_C_SOURCE)
977 #define _POSIX_C_SOURCE 200112
980 #if defined(OMITTED__D_XOPEN_SOURCE_600) && !defined(_XOPEN_SOURCE)
981 #define _XOPEN_SOURCE 600
984 #if defined(OMITTED__D_XOPEN_SOURCE_EXTENDED_1) && !defined(_XOPEN_SOURCE_EXTENDED)
985 #define _XOPEN_SOURCE_EXTENDED 1
988 #if defined(OMITTED__D_ALL_SOURCE) && !defined(_ALL_SOURCE)
989 #define _ALL_SOURCE 1
992 #if defined(OMITTED__D_LARGEFILE_SOURCE_1) && !defined(_LARGEFILE_SOURCE)
993 #define _LARGEFILE_SOURCE 1
999 #ifndef _OPENBSD_SOURCE
1000 #define _OPENBSD_SOURCE 1
1003 #ifndef UNBOUND_DEBUG
1009 /** Use small-ldns codebase */
1012 # define LDNS_BUILD_CONFIG_HAVE_SSL 1
1025 #ifdef HAVE_STDARG_H
1029 #ifdef HAVE_STDINT_H
1035 #if HAVE_SYS_PARAM_H
1036 #include <sys/param.h>
1039 #ifdef HAVE_SYS_SOCKET_H
1040 #include <sys/socket.h>
1043 #ifdef HAVE_SYS_UIO_H
1044 #include <sys/uio.h>
1047 #ifdef HAVE_NETINET_IN_H
1048 #include <netinet/in.h>
1051 #ifdef HAVE_NETINET_TCP_H
1052 #include <netinet/tcp.h>
1055 #ifdef HAVE_ARPA_INET_H
1056 #include <arpa/inet.h>
1059 #ifdef HAVE_WINSOCK2_H
1060 #include <winsock2.h>
1063 #ifdef HAVE_WS2TCPIP_H
1064 #include <ws2tcpip.h>
1068 #define ARG_LL "%ll"
1070 #define ARG_LL "%I64"
1074 #define AF_LOCAL AF_UNIX
1079 #ifdef HAVE_ATTR_FORMAT
1080 # define ATTR_FORMAT(archetype, string_index, first_to_check) \
1081 __attribute__ ((format (archetype, string_index, first_to_check)))
1082 #else /* !HAVE_ATTR_FORMAT */
1083 # define ATTR_FORMAT(archetype, string_index, first_to_check) /* empty */
1084 #endif /* !HAVE_ATTR_FORMAT */
1087 #if defined(DOXYGEN)
1088 # define ATTR_UNUSED(x) x
1089 #elif defined(__cplusplus)
1090 # define ATTR_UNUSED(x)
1091 #elif defined(HAVE_ATTR_UNUSED)
1092 # define ATTR_UNUSED(x) x __attribute__((unused))
1093 #else /* !HAVE_ATTR_UNUSED */
1094 # define ATTR_UNUSED(x) x
1095 #endif /* !HAVE_ATTR_UNUSED */
1099 #define fseeko fseek
1100 #define ftello ftell
1101 #endif /* HAVE_FSEEKO */
1104 #ifndef MAXHOSTNAMELEN
1105 #define MAXHOSTNAMELEN 256
1108 #if !defined(HAVE_SNPRINTF) || defined(SNPRINTF_RET_BROKEN)
1109 #define snprintf snprintf_unbound
1110 #define vsnprintf vsnprintf_unbound
1112 int snprintf (char *str, size_t count, const char *fmt, ...);
1113 int vsnprintf (char *str, size_t count, const char *fmt, va_list arg);
1114 #endif /* HAVE_SNPRINTF or SNPRINTF_RET_BROKEN */
1116 #ifndef HAVE_INET_PTON
1117 #define inet_pton inet_pton_unbound
1118 int inet_pton(int af, const char* src, void* dst);
1119 #endif /* HAVE_INET_PTON */
1122 #ifndef HAVE_INET_NTOP
1123 #define inet_ntop inet_ntop_unbound
1124 const char *inet_ntop(int af, const void *src, char *dst, size_t size);
1128 #ifndef HAVE_INET_ATON
1129 #define inet_aton inet_aton_unbound
1130 int inet_aton(const char *cp, struct in_addr *addr);
1134 #ifndef HAVE_MEMMOVE
1135 #define memmove memmove_unbound
1136 void *memmove(void *dest, const void *src, size_t n);
1140 #ifndef HAVE_STRLCAT
1141 #define strlcat strlcat_unbound
1142 size_t strlcat(char *dst, const char *src, size_t siz);
1146 #ifndef HAVE_STRLCPY
1147 #define strlcpy strlcpy_unbound
1148 size_t strlcpy(char *dst, const char *src, size_t siz);
1152 #ifndef HAVE_GMTIME_R
1153 #define gmtime_r gmtime_r_unbound
1154 struct tm *gmtime_r(const time_t *timep, struct tm *result);
1158 #ifndef HAVE_REALLOCARRAY
1159 #define reallocarray reallocarrayunbound
1160 void* reallocarray(void *ptr, size_t nmemb, size_t size);
1164 #if !defined(HAVE_SLEEP) || defined(HAVE_WINDOWS_H)
1165 #define sleep(x) Sleep((x)*1000) /* on win32 */
1166 #endif /* HAVE_SLEEP */
1170 #define usleep(x) Sleep((x)/1000 + 1) /* on win32 */
1171 #endif /* HAVE_USLEEP */
1175 #define random rand /* on win32, for tests only (bad random) */
1176 #endif /* HAVE_RANDOM */
1179 #ifndef HAVE_SRANDOM
1180 #define srandom(x) srand(x) /* on win32, for tests only (bad random) */
1181 #endif /* HAVE_SRANDOM */
1184 /* detect if we need to cast to unsigned int for FD_SET to avoid warnings */
1185 #ifdef HAVE_WINSOCK2_H
1186 #define FD_SET_T (u_int)
1192 #ifndef IPV6_MIN_MTU
1193 #define IPV6_MIN_MTU 1280
1194 #endif /* IPV6_MIN_MTU */
1197 #ifdef MEMCMP_IS_BROKEN
1198 #include "compat/memcmp.h"
1199 #define memcmp memcmp_unbound
1200 int memcmp(const void *x, const void *y, size_t n);
1205 #ifndef HAVE_CTIME_R
1206 #define ctime_r unbound_ctime_r
1207 char *ctime_r(const time_t *timep, char *buf);
1211 #define strsep unbound_strsep
1212 char *strsep(char **stringp, const char *delim);
1215 #ifndef HAVE_ISBLANK
1216 #define isblank unbound_isblank
1220 #ifndef HAVE_EXPLICIT_BZERO
1221 #define explicit_bzero unbound_explicit_bzero
1222 void explicit_bzero(void* buf, size_t len);
1225 #if defined(HAVE_INET_NTOP) && !HAVE_DECL_INET_NTOP
1226 const char *inet_ntop(int af, const void *src, char *dst, size_t size);
1229 #if defined(HAVE_INET_PTON) && !HAVE_DECL_INET_PTON
1230 int inet_pton(int af, const char* src, void* dst);
1233 #if !defined(HAVE_STRPTIME) || !defined(STRPTIME_WORKS)
1234 #define strptime unbound_strptime
1236 char *strptime(const char *s, const char *format, struct tm *tm);
1239 #if !HAVE_DECL_REALLOCARRAY
1240 void *reallocarray(void *ptr, size_t nmemb, size_t size);
1243 #ifdef HAVE_LIBRESSL
1244 # if !HAVE_DECL_STRLCPY
1245 size_t strlcpy(char *dst, const char *src, size_t siz);
1247 # if !HAVE_DECL_STRLCAT
1248 size_t strlcat(char *dst, const char *src, size_t siz);
1250 # if !HAVE_DECL_ARC4RANDOM && defined(HAVE_ARC4RANDOM)
1251 uint32_t arc4random(void);
1253 # if !HAVE_DECL_ARC4RANDOM_UNIFORM && defined(HAVE_ARC4RANDOM_UNIFORM)
1254 uint32_t arc4random_uniform(uint32_t upper_bound);
1256 #endif /* HAVE_LIBRESSL */
1257 #ifndef HAVE_ARC4RANDOM
1258 int getentropy(void* buf, size_t len);
1259 uint32_t arc4random(void);
1260 void arc4random_buf(void* buf, size_t n);
1261 void _ARC4_LOCK(void);
1262 void _ARC4_UNLOCK(void);
1263 void _ARC4_LOCK_DESTROY(void);
1265 #ifndef HAVE_ARC4RANDOM_UNIFORM
1266 uint32_t arc4random_uniform(uint32_t upper_bound);
1268 #ifdef COMPAT_SHA512
1269 #ifndef SHA512_DIGEST_LENGTH
1270 #define SHA512_BLOCK_LENGTH 128
1271 #define SHA512_DIGEST_LENGTH 64
1272 #define SHA512_DIGEST_STRING_LENGTH (SHA512_DIGEST_LENGTH * 2 + 1)
1273 typedef struct _SHA512_CTX {
1275 uint64_t bitcount[2];
1276 uint8_t buffer[SHA512_BLOCK_LENGTH];
1278 #endif /* SHA512_DIGEST_LENGTH */
1279 void SHA512_Init(SHA512_CTX*);
1280 void SHA512_Update(SHA512_CTX*, void*, size_t);
1281 void SHA512_Final(uint8_t[SHA512_DIGEST_LENGTH], SHA512_CTX*);
1282 unsigned char *SHA512(void* data, unsigned int data_len, unsigned char *digest);
1283 #endif /* COMPAT_SHA512 */
1287 #if defined(HAVE_EVENT_H) && !defined(HAVE_EVENT_BASE_ONCE) && !(defined(HAVE_EV_LOOP) || defined(HAVE_EV_DEFAULT_LOOP)) && (defined(HAVE_PTHREAD) || defined(HAVE_SOLARIS_THREADS))
1288 /* using version of libevent that is not threadsafe. */
1289 # define LIBEVENT_SIGNAL_PROBLEM 1
1292 #ifndef CHECKED_INET6
1293 # define CHECKED_INET6
1297 # define AF_INET6 28
1299 #endif /* CHECKED_INET6 */
1301 #ifndef HAVE_GETADDRINFO
1302 struct sockaddr_storage;
1303 #include "compat/fake-rfc2553.h"
1306 #ifdef UNBOUND_ALLOC_STATS
1307 # define malloc(s) unbound_stat_malloc_log(s, __FILE__, __LINE__, __func__)
1308 # define calloc(n,s) unbound_stat_calloc_log(n, s, __FILE__, __LINE__, __func__)
1309 # define free(p) unbound_stat_free_log(p, __FILE__, __LINE__, __func__)
1310 # define realloc(p,s) unbound_stat_realloc_log(p, s, __FILE__, __LINE__, __func__)
1311 void *unbound_stat_malloc(size_t size);
1312 void *unbound_stat_calloc(size_t nmemb, size_t size);
1313 void unbound_stat_free(void *ptr);
1314 void *unbound_stat_realloc(void *ptr, size_t size);
1315 void *unbound_stat_malloc_log(size_t size, const char* file, int line,
1317 void *unbound_stat_calloc_log(size_t nmemb, size_t size, const char* file,
1318 int line, const char* func);
1319 void unbound_stat_free_log(void *ptr, const char* file, int line,
1321 void *unbound_stat_realloc_log(void *ptr, size_t size, const char* file,
1322 int line, const char* func);
1323 #elif defined(UNBOUND_ALLOC_LITE)
1324 # include "util/alloc.h"
1325 #endif /* UNBOUND_ALLOC_LITE and UNBOUND_ALLOC_STATS */
1327 /** default port for DNS traffic. */
1328 #define UNBOUND_DNS_PORT 53
1329 /** default port for DNS over TLS traffic. */
1330 #define UNBOUND_DNS_OVER_TLS_PORT 853
1331 /** default port for unbound control traffic, registered port with IANA,
1332 ub-dns-control 8953/tcp unbound dns nameserver control */
1333 #define UNBOUND_CONTROL_PORT 8953
1334 /** the version of unbound-control that this software implements */
1335 #define UNBOUND_CONTROL_VERSION 1