From 7142f0137877dce1892bb6f886ad8f8271dbe239 Mon Sep 17 00:00:00 2001 From: Andrei Pavel Date: Tue, 1 Jul 2025 15:12:38 +0300 Subject: [PATCH] [#3848] Fix fuzzers after security enforcement --- fuzz/fuzz_http_endpoint_kea_dhcp4.cc | 6 +++++- fuzz/fuzz_http_endpoint_kea_dhcp6.cc | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/fuzz/fuzz_http_endpoint_kea_dhcp4.cc b/fuzz/fuzz_http_endpoint_kea_dhcp4.cc index e76f91d21a..ac5e8ffad2 100644 --- a/fuzz/fuzz_http_endpoint_kea_dhcp4.cc +++ b/fuzz/fuzz_http_endpoint_kea_dhcp4.cc @@ -9,7 +9,6 @@ #include #include #include -#include #include @@ -37,6 +36,7 @@ using namespace isc::process; using namespace isc::http; using namespace isc::http::test; using namespace isc::util; +using namespace isc::util::file; using namespace std; namespace { @@ -105,6 +105,10 @@ LLVMFuzzerInitialize() { setenv("KEA_DHCP4_FUZZING_ROTATE_PORT", "true", 0); + // The main focus is on fuzzing the raw HTTP endpoint without the authorization header. + // So bypass the enforcement. + PathChecker::enableEnforcement(false); + return 0; } diff --git a/fuzz/fuzz_http_endpoint_kea_dhcp6.cc b/fuzz/fuzz_http_endpoint_kea_dhcp6.cc index 95230f3a4a..cbccab069b 100644 --- a/fuzz/fuzz_http_endpoint_kea_dhcp6.cc +++ b/fuzz/fuzz_http_endpoint_kea_dhcp6.cc @@ -9,7 +9,6 @@ #include #include #include -#include #include @@ -37,6 +36,7 @@ using namespace isc::process; using namespace isc::http; using namespace isc::http::test; using namespace isc::util; +using namespace isc::util::file; using namespace std; namespace { @@ -105,6 +105,10 @@ LLVMFuzzerInitialize() { setenv("KEA_DHCP6_FUZZING_ROTATE_PORT", "true", 0); + // The main focus is on fuzzing the raw HTTP endpoint without the authorization header. + // So bypass the enforcement. + PathChecker::enableEnforcement(false); + return 0; }