From 4e20e344d2b95f3951d61e77a2d8b6f84449a590 Mon Sep 17 00:00:00 2001 From: Oliver Chang Date: Tue, 30 Aug 2016 14:20:32 -0700 Subject: [PATCH] Add documentation about dictionaries and custom options. --- docs/new_library.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/docs/new_library.md b/docs/new_library.md index 11192f888..a074dbafe 100644 --- a/docs/new_library.md +++ b/docs/new_library.md @@ -118,6 +118,22 @@ Breaking this down: and `.libs/libexpat.a` (which we just built). +### Dictionaries and custom libfuzzer options + +Any top-level files in the library directory ending with the extension ".dict" +or ".options" will be picked up by ClusterFuzz. Files ending with ".dict" are +assumed to be libFuzzer compatible [dictionaries], and .options files have the +format: + +``` +[libfuzzer] +dict = dictionary_name.dict +max_len = 9001 +``` + +This means that `-dict=/path/to/dictionary_name.dict` and `-max_len=9001` will +be passed to the fuzzer when it's run. + ### Others (e.g. fuzzer source) For some libraries, the upstream repository will contain fuzzers (e.g. @@ -184,3 +200,4 @@ Once your change is merged, the fuzzers should be automatically built and run on ClusterFuzz after a short while! [oss-fuzz repo]: https://github.com/google/oss-fuzz +[dictionaries]: http://llvm.org/docs/LibFuzzer.html#dictionaries