Skip to content
This repository has been archived by the owner on Jun 7, 2018. It is now read-only.

Commit

Permalink
Fix timeout config setting, update README.md (refs #38)
Browse files Browse the repository at this point in the history
  • Loading branch information
rc0r committed Nov 12, 2016
1 parent 631a316 commit 1675cb2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,11 @@ here:
$ afl-collect -d crashes.db -e gdb_script -r -rr ./afl_sync_dir ./collection_dir \
-j 8 -- /path/to/target --target-opts

During sample verification (enabled using `-r`) `afl-collect` uses a default time of
10 seconds to allow the target process to finish processing a single sample. This ensures
that `afl-collect` continues to run even if you happen to encounter some DoS condition
in the target. If you want to tweak this value use `-r` in conjunction with
`-rt <timeout>` to specify the timeout in seconds.

## afl-cron

Expand Down
5 changes: 2 additions & 3 deletions afl_utils/afl_collect.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,8 +328,7 @@ def main(argv):
parser = argparse.ArgumentParser(description="afl-collect copies all crash sample files from an afl sync dir used \
by multiple fuzzers when fuzzing in parallel into a single location providing easy access for further crash analysis.",
usage="afl-collect [-d DATABASE] [-e|-g GDB_EXPL_SCRIPT_FILE] [-f LIST_FILENAME]\n \
[-h] [-j THREADS] [-m] [-r] [-rr] sync_dir collection_dir -- target_cmd")

[-h] [-j THREADS] [-m] [-r [-rt TIMEOUT]] [-rr] sync_dir collection_dir -- target_cmd")
parser.add_argument("sync_dir", help="afl synchronisation directory crash samples will be collected from.")
parser.add_argument("collection_dir",
help="Output directory that will hold a copy of all crash samples and other generated files. \
Expand Down Expand Up @@ -414,7 +413,7 @@ def main(argv):
if args.remove_invalid:
from afl_utils import afl_vcrash
invalid_samples, timeout_samples = afl_vcrash.verify_samples(int(args.num_threads), sample_index.inputs(),
args.target_cmd, timeout_secs=args.remove_timeout)
args.target_cmd, timeout_secs=float(args.remove_timeout))

# store invalid samples in db
if args.gdb_expl_script_file and db_file:
Expand Down

0 comments on commit 1675cb2

Please sign in to comment.