Files
Benjamin Gordon 4313f0de62 Add basic fuzzers
To compile:
  * CXX=clang++ meson build
  * ninja -C build fuzzer-xml fuzzer-uri

These fuzzers use libFuzzer and asan support in clang 10 or later to
fuzz the XML parsing and http_uri functions.  They aren't very thorough
(yet), but demonstrate the basic technique.
2020-11-11 12:50:08 -07:00

526 B

The fuzzer directory contains several fuzz targets that make use of asan and libFuzzer from clang 10 or later to test functions that are expected to process untrusted inputs.

To build:

CXX=clang++-10 meson build
ninja -C build fuzzer-$name

where $name can be any of the files in the fuzzer directory.

You can then run the fuzzer as build/fuzzer-$name. The basic mode will run indefinitely until a problem is found. Pass -help=1 to see additional fuzzer options.