package afl-persistent

  1. Overview
  2. Docs
Use afl-fuzz in persistent mode

Install

Dune Dependency

Authors

Maintainers

Sources

v1.4.tar.gz
md5=4791d637ade0269ddb348d231e643bb0
sha512=68b779f67d3e4e25f64b4cfe902a183b977158e476abd9691e65a65b0220595de802a7fdb3ac473c5379e12e2e1a4cd96cc5f51e407c72f892bdb87db364dd2c

README.md.html

afl-persistent - persistent-mode afl-fuzz for ocaml

by using AflPersistent.run, you can fuzz things really fast:

let f () =
  let s = read_line () in
  match Array.to_list (Array.init (String.length s) (String.get s)) with
    ['s'; 'e'; 'c'; 'r'; 'e'; 't'; ' '; 'c'; 'o'; 'd'; 'e'] -> failwith "uh oh"
  | _ -> ()

let _ = AflPersistent.run f

compile with a version of ocaml that supports afl. that means trunk for now, but the next release (4.05) will work too, and pass the -afl-instrument option to ocamlopt.