mirror of
https://github.com/openvswitch/ovs
synced 2025-08-22 09:58:01 +00:00
tests: Add regression tests for all the bugs found by oss-fuzz so far.
This will make it harder for bugs found by oss-fuzz to reappear. Signed-off-by: Ben Pfaff <blp@ovn.org> Tested-by: Yifeng Sun <pkusunyifeng@gmail.com> Reviewed-by: Yifeng Sun <pkusunyifeng@gmail.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
This commit is contained in:
parent
49b21677f4
commit
2bdeb9a70e
@ -37,6 +37,8 @@ TESTSUITE_AT = \
|
|||||||
tests/ofp-util.at \
|
tests/ofp-util.at \
|
||||||
tests/ofp-errors.at \
|
tests/ofp-errors.at \
|
||||||
tests/ovs-ofctl.at \
|
tests/ovs-ofctl.at \
|
||||||
|
tests/fuzz-regression.at \
|
||||||
|
tests/fuzz-regression-list.at \
|
||||||
tests/odp.at \
|
tests/odp.at \
|
||||||
tests/mpls-xlate.at \
|
tests/mpls-xlate.at \
|
||||||
tests/multipath.at \
|
tests/multipath.at \
|
||||||
@ -108,6 +110,37 @@ TESTSUITE_AT = \
|
|||||||
tests/packet-type-aware.at \
|
tests/packet-type-aware.at \
|
||||||
tests/nsh.at
|
tests/nsh.at
|
||||||
|
|
||||||
|
EXTRA_DIST += $(FUZZ_REGRESSION_TESTS)
|
||||||
|
FUZZ_REGRESSION_TESTS = \
|
||||||
|
tests/fuzz-regression/flow_extract_fuzzer-5112775280951296 \
|
||||||
|
tests/fuzz-regression/flow_extract_fuzzer-5457710546944000 \
|
||||||
|
tests/fuzz-regression/json_parser_fuzzer-4790908707930112 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-4584019764183040 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-4730143510626304 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-4854119633256448 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5070973479944192 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5072291707748352 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5147430386401280 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5168455220199424 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5190507327127552 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5204186701496320 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5394482341085184 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5395207246839808 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5647458888581120 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5674119268925440 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5674419757252608 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5677588436484096 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5706562554298368 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-5722747668791296 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-6285128790704128 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-6470117922701312 \
|
||||||
|
tests/fuzz-regression/ofp_print_fuzzer-6502620041576448
|
||||||
|
$(srcdir)/tests/fuzz-regression-list.at: tests/automake.mk
|
||||||
|
for name in $(FUZZ_REGRESSION_TESTS); do \
|
||||||
|
basename=`echo $$name | sed 's,^.*/,,'`; \
|
||||||
|
echo "TEST_FUZZ_REGRESSION([$$basename])"; \
|
||||||
|
done > $@.tmp && mv $@.tmp $@
|
||||||
|
|
||||||
SYSTEM_KMOD_TESTSUITE_AT = \
|
SYSTEM_KMOD_TESTSUITE_AT = \
|
||||||
tests/system-common-macros.at \
|
tests/system-common-macros.at \
|
||||||
tests/system-kmod-testsuite.at \
|
tests/system-kmod-testsuite.at \
|
||||||
|
23
tests/fuzz-regression-list.at
Normal file
23
tests/fuzz-regression-list.at
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
TEST_FUZZ_REGRESSION([flow_extract_fuzzer-5112775280951296])
|
||||||
|
TEST_FUZZ_REGRESSION([flow_extract_fuzzer-5457710546944000])
|
||||||
|
TEST_FUZZ_REGRESSION([json_parser_fuzzer-4790908707930112])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-4584019764183040])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-4730143510626304])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-4854119633256448])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5070973479944192])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5072291707748352])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5147430386401280])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5168455220199424])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5190507327127552])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5204186701496320])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5394482341085184])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5395207246839808])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5647458888581120])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5674119268925440])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5674419757252608])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5677588436484096])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5706562554298368])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-5722747668791296])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-6285128790704128])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-6470117922701312])
|
||||||
|
TEST_FUZZ_REGRESSION([ofp_print_fuzzer-6502620041576448])
|
21
tests/fuzz-regression.at
Normal file
21
tests/fuzz-regression.at
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
AT_BANNER([fuzz regression])
|
||||||
|
|
||||||
|
OVS_START_SHELL_HELPERS
|
||||||
|
test_fuzz_regression() {
|
||||||
|
filename=$top_srcdir/tests/fuzz-regression/$1
|
||||||
|
AS_CASE([$1],
|
||||||
|
[flow_extract_fuzzer*], [ovs-ofctl parse-packet < $filename],
|
||||||
|
[ofp_print_fuzzer*], [ovs-ofctl ofp-parse - < $filename],
|
||||||
|
[json_parser_fuzzer*], [ovstest test-json $filename],
|
||||||
|
[*], [AT_FAIL_IF([:])])
|
||||||
|
status=$?
|
||||||
|
AT_CHECK([test $status = 0 || test $status = 1])
|
||||||
|
}
|
||||||
|
OVS_END_SHELL_HELPERS
|
||||||
|
|
||||||
|
m4_define([TEST_FUZZ_REGRESSION],
|
||||||
|
[AT_SETUP([fuzz regression - $1])
|
||||||
|
test_fuzz_regression $1
|
||||||
|
AT_CLEANUP])
|
||||||
|
|
||||||
|
m4_include([tests/fuzz-regression-list.at])
|
BIN
tests/fuzz-regression/flow_extract_fuzzer-5112775280951296
Normal file
BIN
tests/fuzz-regression/flow_extract_fuzzer-5112775280951296
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/flow_extract_fuzzer-5457710546944000
Normal file
BIN
tests/fuzz-regression/flow_extract_fuzzer-5457710546944000
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/json_parser_fuzzer-4790908707930112
Normal file
BIN
tests/fuzz-regression/json_parser_fuzzer-4790908707930112
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-4584019764183040
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-4584019764183040
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-4730143510626304
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-4730143510626304
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-4854119633256448
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-4854119633256448
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5070973479944192
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5070973479944192
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5072291707748352
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5072291707748352
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5147430386401280
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5147430386401280
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5168455220199424
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5168455220199424
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5190507327127552
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5190507327127552
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5204186701496320
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5204186701496320
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5394482341085184
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5394482341085184
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5395207246839808
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5395207246839808
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5647458888581120
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5647458888581120
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5674119268925440
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5674119268925440
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5674419757252608
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5674419757252608
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5677588436484096
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5677588436484096
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5706562554298368
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5706562554298368
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-5722747668791296
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-5722747668791296
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-6285128790704128
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-6285128790704128
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-6470117922701312
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-6470117922701312
Normal file
Binary file not shown.
BIN
tests/fuzz-regression/ofp_print_fuzzer-6502620041576448
Normal file
BIN
tests/fuzz-regression/ofp_print_fuzzer-6502620041576448
Normal file
Binary file not shown.
@ -37,6 +37,7 @@ m4_include([tests/ofp-print.at])
|
|||||||
m4_include([tests/ofp-util.at])
|
m4_include([tests/ofp-util.at])
|
||||||
m4_include([tests/ofp-errors.at])
|
m4_include([tests/ofp-errors.at])
|
||||||
m4_include([tests/ovs-ofctl.at])
|
m4_include([tests/ovs-ofctl.at])
|
||||||
|
m4_include([tests/fuzz-regression.at])
|
||||||
m4_include([tests/odp.at])
|
m4_include([tests/odp.at])
|
||||||
m4_include([tests/mpls-xlate.at])
|
m4_include([tests/mpls-xlate.at])
|
||||||
m4_include([tests/multipath.at])
|
m4_include([tests/multipath.at])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user