123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305 |
- # This file was generated by fuzzing_include_am.py; do not hand-edit unless
- # you enjoy having your changes erased.
- FUZZING_CPPFLAGS = \
- $(src_test_AM_CPPFLAGS) $(TEST_CPPFLAGS)
- FUZZING_CFLAGS = \
- $(AM_CFLAGS) $(TEST_CFLAGS)
- FUZZING_LDFLAG = \
- @TOR_LDFLAGS_zlib@ @TOR_LDFLAGS_openssl@ @TOR_LDFLAGS_libevent@
- FUZZING_LIBS = \
- src/or/libtor-testing.a \
- src/common/libor-crypto-testing.a \
- $(LIBKECCAK_TINY) \
- $(LIBDONNA) \
- src/common/libor-testing.a \
- src/common/libor-ctime-testing.a \
- src/common/libor-event-testing.a \
- src/trunnel/libor-trunnel-testing.a \
- @TOR_ZLIB_LIBS@ @TOR_LIB_MATH@ \
- @TOR_LIBEVENT_LIBS@ \
- @TOR_OPENSSL_LIBS@ @TOR_LIB_WS32@ @TOR_LIB_GDI@ @CURVE25519_LIBS@ \
- @TOR_SYSTEMD_LIBS@ \
- @TOR_LZMA_LIBS@ \
- @TOR_ZSTD_LIBS@ \
- $(rust_ldadd)
- oss-fuzz-prereqs: \
- src/or/libtor-testing.a \
- src/common/libor-crypto-testing.a \
- $(LIBKECCAK_TINY) \
- $(LIBDONNA) \
- src/common/libor-testing.a \
- src/common/libor-ctime-testing.a \
- src/common/libor-event-testing.a \
- src/trunnel/libor-trunnel-testing.a
- noinst_HEADERS += \
- src/test/fuzz/fuzzing.h
- LIBFUZZER = -lFuzzer
- LIBFUZZER_CPPFLAGS = $(FUZZING_CPPFLAGS) -DLLVM_FUZZ
- LIBFUZZER_CFLAGS = $(FUZZING_CFLAGS)
- LIBFUZZER_LDFLAG = $(FUZZING_LDFLAG)
- LIBFUZZER_LIBS = $(FUZZING_LIBS) $(LIBFUZZER) -lstdc++
- LIBOSS_FUZZ_CPPFLAGS = $(FUZZING_CPPFLAGS) -DLLVM_FUZZ
- LIBOSS_FUZZ_CFLAGS = $(FUZZING_CFLAGS)
- # ===== AFL fuzzers
- src_test_fuzz_fuzz_consensus_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_consensus.c
- src_test_fuzz_fuzz_consensus_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_consensus_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_consensus_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_consensus_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_descriptor_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_descriptor.c
- src_test_fuzz_fuzz_descriptor_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_descriptor_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_descriptor_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_descriptor_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_diff_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_diff.c
- src_test_fuzz_fuzz_diff_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_diff_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_diff_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_diff_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_diff_apply_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_diff_apply.c
- src_test_fuzz_fuzz_diff_apply_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_diff_apply_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_diff_apply_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_diff_apply_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_extrainfo_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_extrainfo.c
- src_test_fuzz_fuzz_extrainfo_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_extrainfo_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_extrainfo_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_extrainfo_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_hsdescv2_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_hsdescv2.c
- src_test_fuzz_fuzz_hsdescv2_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_hsdescv2_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_hsdescv2_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_hsdescv2_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_http_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_http.c
- src_test_fuzz_fuzz_http_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_http_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_http_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_http_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_iptsv2_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_iptsv2.c
- src_test_fuzz_fuzz_iptsv2_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_iptsv2_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_iptsv2_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_iptsv2_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_microdesc_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_microdesc.c
- src_test_fuzz_fuzz_microdesc_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_microdesc_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_microdesc_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_microdesc_LDADD = $(FUZZING_LIBS)
- src_test_fuzz_fuzz_vrs_SOURCES = \
- src/test/fuzz/fuzzing_common.c \
- src/test/fuzz/fuzz_vrs.c
- src_test_fuzz_fuzz_vrs_CPPFLAGS = $(FUZZING_CPPFLAGS)
- src_test_fuzz_fuzz_vrs_CFLAGS = $(FUZZING_CFLAGS)
- src_test_fuzz_fuzz_vrs_LDFLAGS = $(FUZZING_LDFLAG)
- src_test_fuzz_fuzz_vrs_LDADD = $(FUZZING_LIBS)
- FUZZERS = \
- src/test/fuzz/fuzz-consensus \
- src/test/fuzz/fuzz-descriptor \
- src/test/fuzz/fuzz-diff \
- src/test/fuzz/fuzz-diff-apply \
- src/test/fuzz/fuzz-extrainfo \
- src/test/fuzz/fuzz-hsdescv2 \
- src/test/fuzz/fuzz-http \
- src/test/fuzz/fuzz-iptsv2 \
- src/test/fuzz/fuzz-microdesc \
- src/test/fuzz/fuzz-vrs
- # ===== libfuzzer
- if LIBFUZZER_ENABLED
- src_test_fuzz_lf_fuzz_consensus_SOURCES = \
- $(src_test_fuzz_fuzz_consensus_SOURCES)
- src_test_fuzz_lf_fuzz_consensus_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_consensus_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_consensus_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_consensus_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_descriptor_SOURCES = \
- $(src_test_fuzz_fuzz_descriptor_SOURCES)
- src_test_fuzz_lf_fuzz_descriptor_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_descriptor_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_descriptor_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_descriptor_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_diff_SOURCES = \
- $(src_test_fuzz_fuzz_diff_SOURCES)
- src_test_fuzz_lf_fuzz_diff_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_diff_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_diff_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_diff_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_diff_apply_SOURCES = \
- $(src_test_fuzz_fuzz_diff_apply_SOURCES)
- src_test_fuzz_lf_fuzz_diff_apply_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_diff_apply_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_diff_apply_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_diff_apply_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_extrainfo_SOURCES = \
- $(src_test_fuzz_fuzz_extrainfo_SOURCES)
- src_test_fuzz_lf_fuzz_extrainfo_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_extrainfo_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_extrainfo_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_extrainfo_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_hsdescv2_SOURCES = \
- $(src_test_fuzz_fuzz_hsdescv2_SOURCES)
- src_test_fuzz_lf_fuzz_hsdescv2_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_hsdescv2_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_hsdescv2_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_hsdescv2_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_http_SOURCES = \
- $(src_test_fuzz_fuzz_http_SOURCES)
- src_test_fuzz_lf_fuzz_http_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_http_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_http_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_http_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_iptsv2_SOURCES = \
- $(src_test_fuzz_fuzz_iptsv2_SOURCES)
- src_test_fuzz_lf_fuzz_iptsv2_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_iptsv2_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_iptsv2_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_iptsv2_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_microdesc_SOURCES = \
- $(src_test_fuzz_fuzz_microdesc_SOURCES)
- src_test_fuzz_lf_fuzz_microdesc_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_microdesc_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_microdesc_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_microdesc_LDADD = $(LIBFUZZER_LIBS)
- src_test_fuzz_lf_fuzz_vrs_SOURCES = \
- $(src_test_fuzz_fuzz_vrs_SOURCES)
- src_test_fuzz_lf_fuzz_vrs_CPPFLAGS = $(LIBFUZZER_CPPFLAGS)
- src_test_fuzz_lf_fuzz_vrs_CFLAGS = $(LIBFUZZER_CFLAGS)
- src_test_fuzz_lf_fuzz_vrs_LDFLAGS = $(LIBFUZZER_LDFLAG)
- src_test_fuzz_lf_fuzz_vrs_LDADD = $(LIBFUZZER_LIBS)
- LIBFUZZER_FUZZERS = \
- src/test/fuzz/lf-fuzz-consensus \
- src/test/fuzz/lf-fuzz-descriptor \
- src/test/fuzz/lf-fuzz-diff \
- src/test/fuzz/lf-fuzz-diff-apply \
- src/test/fuzz/lf-fuzz-extrainfo \
- src/test/fuzz/lf-fuzz-hsdescv2 \
- src/test/fuzz/lf-fuzz-http \
- src/test/fuzz/lf-fuzz-iptsv2 \
- src/test/fuzz/lf-fuzz-microdesc \
- src/test/fuzz/lf-fuzz-vrs
- else
- LIBFUZZER_FUZZERS =
- endif
- # ===== oss-fuzz
- if OSS_FUZZ_ENABLED
- src_test_fuzz_liboss_fuzz_consensus_a_SOURCES = \
- $(src_test_fuzz_fuzz_consensus_SOURCES)
- src_test_fuzz_liboss_fuzz_consensus_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_consensus_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_descriptor_a_SOURCES = \
- $(src_test_fuzz_fuzz_descriptor_SOURCES)
- src_test_fuzz_liboss_fuzz_descriptor_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_descriptor_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_diff_a_SOURCES = \
- $(src_test_fuzz_fuzz_diff_SOURCES)
- src_test_fuzz_liboss_fuzz_diff_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_diff_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_diff_apply_a_SOURCES = \
- $(src_test_fuzz_fuzz_diff_apply_SOURCES)
- src_test_fuzz_liboss_fuzz_diff_apply_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_diff_apply_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_extrainfo_a_SOURCES = \
- $(src_test_fuzz_fuzz_extrainfo_SOURCES)
- src_test_fuzz_liboss_fuzz_extrainfo_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_extrainfo_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_hsdescv2_a_SOURCES = \
- $(src_test_fuzz_fuzz_hsdescv2_SOURCES)
- src_test_fuzz_liboss_fuzz_hsdescv2_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_hsdescv2_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_http_a_SOURCES = \
- $(src_test_fuzz_fuzz_http_SOURCES)
- src_test_fuzz_liboss_fuzz_http_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_http_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_iptsv2_a_SOURCES = \
- $(src_test_fuzz_fuzz_iptsv2_SOURCES)
- src_test_fuzz_liboss_fuzz_iptsv2_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_iptsv2_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_microdesc_a_SOURCES = \
- $(src_test_fuzz_fuzz_microdesc_SOURCES)
- src_test_fuzz_liboss_fuzz_microdesc_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_microdesc_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- src_test_fuzz_liboss_fuzz_vrs_a_SOURCES = \
- $(src_test_fuzz_fuzz_vrs_SOURCES)
- src_test_fuzz_liboss_fuzz_vrs_a_CPPFLAGS = $(LIBOSS_FUZZ_CPPFLAGS)
- src_test_fuzz_liboss_fuzz_vrs_a_CFLAGS = $(LIBOSS_FUZZ_CFLAGS)
- OSS_FUZZ_FUZZERS = \
- src/test/fuzz/liboss-fuzz-consensus.a \
- src/test/fuzz/liboss-fuzz-descriptor.a \
- src/test/fuzz/liboss-fuzz-diff.a \
- src/test/fuzz/liboss-fuzz-diff-apply.a \
- src/test/fuzz/liboss-fuzz-extrainfo.a \
- src/test/fuzz/liboss-fuzz-hsdescv2.a \
- src/test/fuzz/liboss-fuzz-http.a \
- src/test/fuzz/liboss-fuzz-iptsv2.a \
- src/test/fuzz/liboss-fuzz-microdesc.a \
- src/test/fuzz/liboss-fuzz-vrs.a
- else
- OSS_FUZZ_FUZZERS =
- endif
- noinst_PROGRAMS += $(FUZZERS) $(LIBFUZZER_FUZZERS)
- noinst_LIBRARIES += $(OSS_FUZZ_FUZZERS)
- oss-fuzz-fuzzers: oss-fuzz-prereqs $(OSS_FUZZ_FUZZERS)
- fuzzers: $(FUZZERS) $(LIBFUZZER_FUZZERS)
- test-fuzz-corpora: $(FUZZERS)
- $(top_srcdir)/src/test/fuzz_static_testcases.sh
|