diff options
Diffstat (limited to 'tests/ossfuzz.sh')
-rw-r--r-- | tests/ossfuzz.sh | 37 |
1 files changed, 19 insertions, 18 deletions
diff --git a/tests/ossfuzz.sh b/tests/ossfuzz.sh index b6631fbe7..752ae0415 100644 --- a/tests/ossfuzz.sh +++ b/tests/ossfuzz.sh @@ -1,4 +1,5 @@ -#!/bin/bash -eu +#!/usr/bin/env bash +set -eu # Copyright 2019 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -46,25 +47,25 @@ cd ndpi RANLIB=llvm-ranlib LDFLAGS="-L/usr/local/lib -lpcap" ./autogen.sh --enable-fuzztargets --with-only-libndpi --enable-tls-sigs make -j$(nproc) # Copy fuzzers -ls fuzz/fuzz* | grep -v "\." | while read i; do cp $i $OUT/; done +ls fuzz/fuzz* | grep -v "\." | while read -r i; do cp "$i" "$OUT"/; done # Copy dictionaries -cp fuzz/*.dict $OUT/ +cp fuzz/*.dict "$OUT"/ # Copy seed corpus -cp fuzz/*.zip $OUT/ +cp fuzz/*.zip "$OUT"/ # Copy options -cp fuzz/*.options $OUT/ +cp fuzz/*.options "$OUT"/ # Copy configuration files -cp example/protos.txt $OUT/ -cp example/categories.txt $OUT/ -cp example/risky_domains.txt $OUT/ -cp example/ja3_fingerprints.csv $OUT/ -cp example/sha1_fingerprints.csv $OUT/ -cp example/config.txt $OUT/ -cp lists/public_suffix_list.dat $OUT/ -cp fuzz/ipv*_addresses.txt $OUT/ -cp fuzz/bd_param.txt $OUT/ -cp fuzz/splt_param.txt $OUT/ -cp fuzz/random_list.list $OUT/ -mkdir -p $OUT/lists +cp example/protos.txt "$OUT"/ +cp example/categories.txt "$OUT"/ +cp example/risky_domains.txt "$OUT"/ +cp example/ja3_fingerprints.csv "$OUT"/ +cp example/sha1_fingerprints.csv "$OUT"/ +cp example/config.txt "$OUT"/ +cp lists/public_suffix_list.dat "$OUT"/ +cp fuzz/ipv*_addresses.txt "$OUT"/ +cp fuzz/bd_param.txt "$OUT"/ +cp fuzz/splt_param.txt "$OUT"/ +cp fuzz/random_list.list "$OUT"/ +mkdir -p "$OUT"/lists # Ignore a huge list to speed up init time -find lists/*.list ! -name 100_malware.list -exec cp -t $OUT/lists/ {} + +find lists/*.list ! -name 100_malware.list -exec cp -t "$OUT"/lists/ {} + |