about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSamuel Moelius <sam@moeli.us>2024-09-12 10:05:23 -0400
committerSamuel Moelius <sam@moeli.us>2024-09-12 10:05:23 -0400
commit6a285021917824696708647b2c55f11b55c5dc0b (patch)
tree4e10fb7affa9800ad1414150cfd1114f0d90ccb0
parent4086b93ad799e3cd28968102a2d175b166a31300 (diff)
downloadafl++-6a285021917824696708647b2c55f11b55c5dc0b.tar.gz
Adjust cmplog test to use `AFL_SHA1_FILENAMES=1`
-rwxr-xr-xtest/test-llvm.sh8
1 files changed, 6 insertions, 2 deletions
diff --git a/test/test-llvm.sh b/test/test-llvm.sh
index 4dd35e6e..8236d138 100755
--- a/test/test-llvm.sh
+++ b/test/test-llvm.sh
@@ -269,9 +269,9 @@ test -e ../afl-clang-fast -a -e ../split-switches-pass.so && {
     {
       mkdir -p in
       echo 00000000000000000000000000000000 > in/in
-      AFL_BENCH_UNTIL_CRASH=1 ../afl-fuzz -Z -l 3 -m none -V30 -i in -o out -c 0 -- ./test-cmplog >>errors 2>&1
+      AFL_BENCH_UNTIL_CRASH=1 AFL_NO_CRASH_README=1 AFL_SHA1_FILENAMES=1 ../afl-fuzz -Z -l 3 -m none -V30 -i in -o out -c 0 -- ./test-cmplog >>errors 2>&1
     } >>errors 2>&1
-    test -n "$( ls out/default/crashes/id:000000* out/default/hangs/id:000000* 2>/dev/null )" && {
+    test -n "$( ls out/default/crashes/* out/default/hangs/* 2>/dev/null )" && {
       $ECHO "$GREEN[+] afl-fuzz is working correctly with llvm_mode cmplog"
     } || {
       echo CUT------------------------------------------------------------------CUT
@@ -280,6 +280,10 @@ test -e ../afl-clang-fast -a -e ../split-switches-pass.so && {
       $ECHO "$RED[!] afl-fuzz is not working correctly with llvm_mode cmplog"
       CODE=1
     }
+    test -n "$( ls out/default/crashes/id:000000* out/default/hangs/id:000000* 2>/dev/null )" && {
+      $ECHO "$RED[!] filenames are not SHA1"
+      CODE=1
+    } || true
   } || {
     $ECHO "$YELLOW[-] we cannot test llvm_mode cmplog because it is not present"
     INCOMPLETE=1