commit f53eb8ea854f3d5016f234f55e265bf19b95d77d from: Sergey Bronnikov date: Sun Nov 26 10:20:22 2017 UTC Update commit - 10ede6139b4961e7a7f6f39a8b70448e5e1f7a56 commit + f53eb8ea854f3d5016f234f55e265bf19b95d77d blob - f5968bf260ab5d96e696fca4ffd5978a9661bfc4 blob + de39ec6a7788933af3015efc46abf92c434dcb57 --- tests/afl-fuzz/afl_run +++ tests/afl-fuzz/afl_run @@ -20,19 +20,22 @@ # radiusd ctfdump ctfconf sasyncd libutil pfctl # # TODO: -# iked ipsecctl bgpd dvmrpd eigrpd hostapd ifstated -# iscsictl ldapd ldomctl ldpd npppd/npppd ntpd ospf6d -# ospfd relayd ripd smtpd snmpd switchd vmd ypldap keynote +# iked ipsecctl eigrpd iscsictl ldapd ldomctl +# snmpd vmd ypldap keynote ldpd ospf6d +# ... +# sed last nm bc lex fold +# ssh mandoc ksh ctags make m4 yacc deroff cwm +# radiusd ctfdump ctfconf sasyncd pfctl # libfuzzer candidates: # chio -# syslogd - no option check_config +# syslogd - no option -n set -eu SRC_BASE="/usr/src" CONF_PATH="/root/openbsd-tests/tools/afl" -DATE="2017-11-23" +DATE="2016-11-23" type afl-fuzz || pkg_add afl type git || pkg_add git @@ -47,21 +50,31 @@ afl_exec () return fi - _run_cmd="cd $_path; CC=afl-gcc make; mkdir in out; cp /root/afl-static/* in/; $_cmd" + _run_cmd="cd $_path; CC=afl-gcc make; rm -rf in out; mkdir in out; cp /root/afl-static/* in/; $_cmd" tmux new-window -d -n "$_path" "$_run_cmd" tmux set-window-option -t "$_path" remain-on-exit on } -tmux new-session -d -c $SRC_BASE -s afl-run +tmux new-session -d -c $SRC_BASE -s afl-run || true -afl_exec "bin/ed" "afl-fuzz -i in -o out -f ed.commands -- ./ed @@" -afl_exec "sbin/dhclient" "afl-fuzz -i in -o out -f dhclient.conf -- ./dhclient -n -c @@ em0" -afl_exec "usr.bin/cap_mkdb" "afl-fuzz -i in -o out -f termcap -- ./cap_mkdb -f outfile @@" -afl_exec "usr.bin/doas" "afl-fuzz -i in -o out -f doas.conf -- ./doas -C @@ ls" -afl_exec "usr.bin/kdump" "afl-fuzz -i in -o out -f ktrace.out ./kdump -f @@" -afl_exec "usr.sbin/acme-client" "acme-client -f acme-client.conf example.com" -afl_exec "usr.sbin/httpd" "afl-fuzz -i in -o out -- ./httpd -n -f @@" -afl_exec "usr.sbin/ifstated" "afl-fuzz -i in -o out -f ifstated.conf ./ifstated -n -f @@" -afl_exec "usr.sbin/mtree" "afl-fuzz -i in -o out -f special -- ./mtree -f @@ -p /" -afl_exec "usr.sbin/tcpdump" "afl-fuzz -i in -o out -f sample.pcap ./tcpdump -r @@" -afl_exec "usr.sbin/tcpdump" "afl-fuzz -i in -o out -f tcpdump.expression ./tcpdump -r $CONF_PATH/sample.pcap -F @@" +afl_exec "bin/ed" "afl-fuzz -i in -o out -f ed.commands -- ./ed @@" # KNOWN ISSUE +afl_exec "sbin/dhclient" "afl-fuzz -i in -o out -f dhclient.conf -- ./dhclient -n -c @@ em0" +afl_exec "usr.bin/cap_mkdb" "afl-fuzz -i in -o out -f termcap -- ./cap_mkdb -f outfile @@" +afl_exec "usr.bin/doas" "afl-fuzz -i in -o out -f doas.conf -- ./doas -C @@ ls" +afl_exec "usr.bin/kdump" "afl-fuzz -i in -o out -f ktrace.out -- ./kdump -f @@" +# FIXME: afl_exec "usr.sbin/acme-client" "acme-client -f acme-client.conf example.com" +afl_exec "usr.sbin/bgpd" "afl-fuzz -i in -o out -f bgpd.conf -- ./bgpd -n -f @@" +afl_exec "usr.sbin/dvmrpd" "afl-fuzz -i in -o out -f dvmrpd.conf -- ./dvmrpd -n -f @@" +afl_exec "usr.sbin/hostapd" "afl-fuzz -i in -o out -f hostapd.conf -- ./hostapd -f @@" # NOTE: there is no option -n +afl_exec "usr.sbin/httpd" "afl-fuzz -i in -o out -f httpd.conf -- ./httpd -n -f @@" +afl_exec "usr.sbin/ifstated" "afl-fuzz -i in -o out -f ifstated.conf -- ./ifstated -n -f @@" +afl_exec "usr.sbin/mtree" "afl-fuzz -i in -o out -f special -- ./mtree -f @@ -p /" +afl_exec "usr.sbin/npppd" "afl-fuzz -i in -o out -f npppd.conf -- ./npppd/npppd -n -f @@" +afl_exec "usr.sbin/ntpd" "afl-fuzz -i in -o out -f ntpd.conf -- ./ntpd -n -f @@" +afl_exec "usr.sbin/ospfd" "afl-fuzz -i in -o out -f ospfd.conf -- ./ospfd -n -f @@" +afl_exec "usr.sbin/relayd" "afl-fuzz -i in -o out -f relayd.conf -- ./relayd -n -f @@" +afl_exec "usr.sbin/ripd" "afl-fuzz -i in -o out -f ripd.conf -- ./ripd -n -f @@" +afl_exec "usr.sbin/smtpd" "afl-fuzz -i in -o out -f smtpd.conf -- ./smtpd/smtpd -n -f @@" +afl_exec "usr.sbin/switchd" "afl-fuzz -i in -o out -f switchd.conf -- ./switchd -n -f @@" +afl_exec "usr.sbin/tcpdump" "afl-fuzz -i in -o out -f sample.pcap -- ./tcpdump -r @@" +afl_exec "usr.sbin/tcpdump" "afl-fuzz -i in -o out -f tcpdump.expression -- ./tcpdump -r $CONF_PATH/sample.pcap -F @@"