Compiling fuzzer

electricworry worryelectric at
Wed Jul 15 17:36:22 CEST 2020

I'm trying to build FreeRADIUS with the fuzzers, but I'm running into
some problems. Can anyone please point out what I'm doing wrong?

First up I appended "CFLAGS += -fsanitize=fuzzer" to
before running ./configure. Next I had to amend my configure command
so that clang is used:

    ./configure CC=clang

Next I ran into linking issues because not all binaries have LibFuzzer
targets (as I would expect) so I appended again to
"LDFLAGS += -fsanitize=fuzzer-no-link" (which is probably the wrong
direction). At the stage of compiling src/bin/fuzzer.c I get an error:

    CC src/bin/fuzzer.c
    src/bin/fuzzer.c:111:25: error: use of undeclared identifier
            dl_search_path_prepend(dl_module_loader->dl_loader, lib_dir);

What am I missing? Looking at the makefiles it looks like it should
build out of the box but I seem to be missing something.

More information about the Freeradius-Devel mailing list