From f676e5528ac8a2d454a607fceaa8590f11b9f795 Mon Sep 17 00:00:00 2001 From: hexcoder- Date: Mon, 3 Feb 2020 19:20:16 +0100 Subject: [PATCH] adapt to new afl-ahowmap with forkserver mode --- afl-cmin | 9 ++------- test/test.sh | 4 ++-- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/afl-cmin b/afl-cmin index 9179628e..182376c9 100755 --- a/afl-cmin +++ b/afl-cmin @@ -397,13 +397,8 @@ BEGIN { system( "AFL_CMIN_ALLOW_ANY=1 \""showmap"\" -m "mem_limit" -t "timeout" -o \""trace_dir"/"fn"\" -Z "extra_par" -- \""target_bin"\" "prog_args_string" <\""in_dir"/"fn"\"") } } else { - while (cur < in_count) { - fn = infilesSmallToBig[cur] - ++cur - printf "\r Processing file "cur"/"in_count - system("cp "in_dir"/"fn" "stdin_file) - system( "AFL_CMIN_ALLOW_ANY=1 \""showmap"\" -m "mem_limit" -t "timeout" -o \""trace_dir"/"fn"\" -Z "extra_par" -A \""stdin_file"\" -- \""target_bin"\" "prog_args_string" in/in2 mkdir -p in2 - ../afl-cmin -i in -o in2 -- ./test-instr.plain > /dev/null + ../afl-cmin -i in -o in2 -- ./test-instr.plain @@ >/dev/null CNT=`ls in2/ | wc -l` case "$CNT" in *1) $ECHO "$GREEN[+] afl-cmin correctly minimized the number of testcases" ;; @@ -256,7 +256,7 @@ test -e ../afl-clang-fast -a -e ../split-switches-pass.so && { test "$SYS" = "i686" -o "$SYS" = "x86_64" -o "$SYS" = "amd64" || { echo 000000000000000000000000 > in/in2 mkdir -p in2 - ../afl-cmin -i in -o in2 -- ./test-instr.plain > /dev/null + ../afl-cmin -i in -o in2 -- ./test-instr.plain @@ >/dev/null CNT=`ls in2/ | wc -l` case "$CNT" in *1) $ECHO "$GREEN[+] afl-cmin correctly minimized the number of testcases" ;;