From: Andrei Pavel Date: Wed, 5 Aug 2026 11:52:22 +0000 (+0300) Subject: [#4272] Catch exception in fuzz_config_* X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6c5c4eff7631e55ffbcf04c74a23afcf8beee7cb;p=thirdparty%2Fkea.git [#4272] Catch exception in fuzz_config_* --- diff --git a/src/fuzz/corp/dhcp-6-sample1.json b/src/fuzz/corp/dhcp-6-sample1.json index e8f2e659e1..7237acf78f 100644 --- a/src/fuzz/corp/dhcp-6-sample1.json +++ b/src/fuzz/corp/dhcp-6-sample1.json @@ -10,7 +10,7 @@ # Next we set up the interfaces to be used by the server. "interfaces-config": { - "interfaces": [] + "interfaces": ["eth0"] }, # And we specify the type of lease database diff --git a/src/fuzz/fuzz_config_kea_dhcp4.cc b/src/fuzz/fuzz_config_kea_dhcp4.cc index 04790e29ef..789a54504e 100644 --- a/src/fuzz/fuzz_config_kea_dhcp4.cc +++ b/src/fuzz/fuzz_config_kea_dhcp4.cc @@ -64,6 +64,7 @@ LLVMFuzzerTestOneInput(uint8_t const* data, size_t size) { server.init(KEA_DHCP4_CONF); } catch (BadValue const&) { } catch (Dhcp4ParseError const&) { + } catch (std::exception const&) { } return 0; diff --git a/src/fuzz/fuzz_config_kea_dhcp6.cc b/src/fuzz/fuzz_config_kea_dhcp6.cc index a8d720464e..593f8744ff 100644 --- a/src/fuzz/fuzz_config_kea_dhcp6.cc +++ b/src/fuzz/fuzz_config_kea_dhcp6.cc @@ -64,6 +64,7 @@ LLVMFuzzerTestOneInput(uint8_t const* data, size_t size) { server.init(KEA_DHCP6_CONF); } catch (BadValue const&) { } catch (Dhcp6ParseError const&) { + } catch (std::exception const&) { } return 0;