2020-10-11 09:58:57 +02:00
|
|
|
FUZZ_RULES := $(lastword $(MAKEFILE_LIST))
|
|
|
|
include $(dir $(FUZZ_RULES))../../src/build.rules
|
|
|
|
|
2019-06-07 22:57:02 +02:00
|
|
|
FUZZ_CFLAGS =
|
|
|
|
|
|
|
|
ifdef LIBFUZZER
|
|
|
|
CC ?= clang
|
|
|
|
#FUZZ_FLAGS ?= -fsanitize=fuzzer,address,signed-integer-overflow,unsigned-integer-overflow
|
|
|
|
FUZZ_FLAGS ?= -fsanitize=fuzzer,address
|
|
|
|
ifndef CFLAGS
|
|
|
|
FUZZ_CFLAGS += $(FUZZ_FLAGS)
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
|
|
|
FUZZ_CFLAGS += -DCONFIG_NO_RANDOM_POOL -DTEST_FUZZ
|
|
|
|
export FUZZ_CFLAGS
|
|
|
|
CFLAGS ?= -MMD -O2 -Wall -g
|
|
|
|
CFLAGS += $(FUZZ_CFLAGS)
|
2019-06-01 13:53:24 +02:00
|
|
|
ifdef LIBFUZZER
|
|
|
|
CFLAGS += -DTEST_LIBFUZZER
|
2019-06-07 22:57:02 +02:00
|
|
|
LDFLAGS += $(FUZZ_FLAGS)
|
2019-06-01 13:53:24 +02:00
|
|
|
endif
|
|
|
|
|
|
|
|
WPAS_SRC=../../../wpa_supplicant
|
|
|
|
SRC=../../../src
|
|
|
|
|
|
|
|
CFLAGS += -I$(SRC) -I$(SRC)/utils -I$(WPAS_SRC)
|
|
|
|
OBJS += ../fuzzer-common.o
|
|
|
|
|
|
|
|
$(SRC)/ap/libap.a:
|
|
|
|
$(MAKE) -C $(SRC)/ap TEST_FUZZ=y
|
|
|
|
|
|
|
|
$(SRC)/common/libcommon.a:
|
|
|
|
$(MAKE) -C $(SRC)/common
|
|
|
|
|
|
|
|
$(SRC)/crypto/libcrypto.a:
|
2019-06-07 22:57:02 +02:00
|
|
|
$(MAKE) -C $(SRC)/crypto TEST_FUZZ=y
|
2019-06-01 13:53:24 +02:00
|
|
|
|
|
|
|
$(SRC)/eapol_auth/libeapol_auth.a:
|
|
|
|
$(MAKE) -C $(SRC)/eapol_auth
|
|
|
|
|
|
|
|
$(SRC)/eapol_supp/libeapol_supp.a:
|
|
|
|
$(MAKE) -C $(SRC)/eapol_supp
|
|
|
|
|
|
|
|
$(SRC)/eap_common/libeap_common.a:
|
|
|
|
$(MAKE) -C $(SRC)/eap_common
|
|
|
|
|
|
|
|
$(SRC)/eap_peer/libeap_peer.a:
|
|
|
|
$(MAKE) -C $(SRC)/eap_peer
|
|
|
|
|
|
|
|
$(SRC)/eap_server/libeap_server.a:
|
|
|
|
$(MAKE) -C $(SRC)/eap_server
|
|
|
|
|
|
|
|
$(SRC)/l2_packet/libl2_packet.a:
|
|
|
|
$(MAKE) -C $(SRC)/l2_packet
|
|
|
|
|
|
|
|
$(SRC)/p2p/libp2p.a:
|
|
|
|
$(MAKE) -C $(SRC)/p2p
|
|
|
|
|
|
|
|
$(SRC)/radius/libradius.a:
|
|
|
|
$(MAKE) -C $(SRC)/radius
|
|
|
|
|
|
|
|
$(SRC)/rsn_supp/librsn_supp.a:
|
|
|
|
$(MAKE) -C $(SRC)/rsn_supp TEST_FUZZ=y
|
|
|
|
|
|
|
|
$(SRC)/tls/libtls.a:
|
|
|
|
$(MAKE) -C $(SRC)/tls TEST_FUZZ=y
|
|
|
|
|
|
|
|
$(SRC)/utils/libutils.a:
|
|
|
|
$(MAKE) -C $(SRC)/utils TEST_FUZZ=y
|
|
|
|
|
|
|
|
$(SRC)/wps/libwps.a:
|
|
|
|
$(MAKE) -C $(SRC)/wps
|