Replace all random functions with isc_random, isc_random_buf and isc_random_uniform API.
The three functions has been modeled after the arc4random family of functions, and they will always return random bytes. The isc_random family of functions internally use these CSPRNG (if available): 1. getrandom() libc call (might be available on Linux and Solaris) 2. SYS_getrandom syscall (might be available on Linux, detected at runtime) 3. arc4random(), arc4random_buf() and arc4random_uniform() (available on BSDs and Mac OS X) 4. crypto library function: 4a. RAND_bytes in case OpenSSL 4b. pkcs_C_GenerateRandom() in case PKCS#11 library
This commit is contained in:
committed by
Witold Kręcicki
parent
74dd289a1c
commit
3a4f820d62
@@ -40,7 +40,6 @@ SRCS = acl_test.c \
|
||||
dnstap_test.c \
|
||||
dst_test.c \
|
||||
dnstest.c \
|
||||
dstrandom_test.c \
|
||||
geoip_test.c \
|
||||
gost_test.c \
|
||||
keytable_test.c \
|
||||
@@ -73,7 +72,6 @@ TARGETS = acl_test@EXEEXT@ \
|
||||
dispatch_test@EXEEXT@ \
|
||||
dnstap_test@EXEEXT@ \
|
||||
dst_test@EXEEXT@ \
|
||||
dstrandom_test@EXEEXT@ \
|
||||
geoip_test@EXEEXT@ \
|
||||
gost_test@EXEEXT@ \
|
||||
keytable_test@EXEEXT@ \
|
||||
@@ -258,11 +256,6 @@ zt_test@EXEEXT@: zt_test.@O@ dnstest.@O@ \
|
||||
zt_test.@O@ dnstest.@O@ ${DNSLIBS} \
|
||||
${ISCLIBS} ${LIBS}
|
||||
|
||||
dstrandom_test@EXEEXT@: dstrandom_test.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
|
||||
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ \
|
||||
dstrandom_test.@O@ ${DNSLIBS} \
|
||||
${ISCLIBS} ${ISCPK11LIBS} ${LIBS}
|
||||
|
||||
unit::
|
||||
sh ${top_builddir}/unit/unittest.sh
|
||||
|
||||
|
||||
Reference in New Issue
Block a user