Commit Graph

1 Commits (6f8bb5ee70bb4a79d0315da76df6c204d156826f)

Author SHA1 Message Date
Ran Benita 2cb5c2a3f3 Add fuzzing infrastructure
Though text formats aren't exactly fuzzer's strong suit, fuzzers can
catch many surface-level bugs.

The fuzz/ directory contains target programs, testcases and dictionaries
to drive the afl fuzzer.

This commit adds a fuzzer for the XKB keymap text format and the Compose
text format. On my slow machine, using a single core, a full cycle of
the XKB fuzzer takes 5 hours. For Compose, it takes a few minutes.

Fuzzing for the other file formats (rules files mostly) will be added
later.

To do some fuzzing, run `./fuzz/fuzz.sh`.

Signed-off-by: Ran Benita <ran234@gmail.com>
2018-07-30 10:35:10 +03:00