From: Arran Cudbard-Bell Date: Fri, 29 Oct 2021 13:39:45 +0000 (-0400) Subject: Disable dns lookups for fuzzers X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2600950ed2f24db1a4150fd9dc71a4afbb65b3a7;p=thirdparty%2Ffreeradius-server.git Disable dns lookups for fuzzers --- diff --git a/src/bin/fuzzer.c b/src/bin/fuzzer.c index 5b4d2307212..ea95e7e6c26 100644 --- a/src/bin/fuzzer.c +++ b/src/bin/fuzzer.c @@ -154,6 +154,13 @@ int LLVMFuzzerInitialize(int *argc, char ***argv) fr_exit_now(EXIT_FAILURE); } + /* + * Disable hostname lookups, so we don't produce spurious DNS + * queries, and there's no chance of spurious failures if + * it takes a long time to get a response. + */ + fr_hostname_lookups = false; + dl_loader = dl_loader_init(NULL, NULL, 0, false); if (!dl_loader) { fr_perror("fuzzer: Failed initializing library loader");