2
0
mirror of https://gitlab.isc.org/isc-projects/kea synced 2025-08-30 13:37:55 +00:00

755 Commits

Author SHA1 Message Date
Francis Dupont
d33ca01e44 [#3609] Addressed comments 2024-11-22 11:24:15 +01:00
Thomas Markwalder
9af00a7533 [#3257] Addressed review comments
Minor cosmetics:
	modified:   src/bin/dhcp4/dhcp4_srv.cc
	modified:   src/bin/dhcp6/dhcp6_srv.cc
2024-11-19 05:19:15 -05:00
Thomas Markwalder
3862bab83f [#3257] Suppress NCRs when reusing leases
/src/bin/dhcp4/dhcp4_srv.cc
    Dhcpv4Srv::createNameChangeRequests() - modified to check for
    reused lease

/src/bin/dhcp4/tests/dora_unittest.cc
    DORATest::leaseCaching() - modified to verify suppression of NCRs

/src/bin/dhcp6/dhcp6_srv.cc
    Dhcpv6Srv::createNameChangeRequests() - modified to iteralte over
    IA contexts rather than IA options in response and to check for
    reused leases

/src/bin/dhcp6/tests/fqdn_unittest.cc
    Updated tests to populate IAContexts

/src/bin/dhcp6/tests/sarr_unittest.cc
    SARRTest::leaseCaching()- modified to verify suppression of NCRs

/src/lib/dhcpsrv/alloc_engine.*
    AllocEngine::ClientContext6::IAContext - added reused_leases_ container
    AllocEngine::ClientContext6::getIAContexts() - new function
2024-11-19 05:19:15 -05:00
Francis Dupont
bb7625b7d1 [#3268] Post rebase updates 2024-11-06 10:48:47 +01:00
Francis Dupont
6b9061456b [#3268] Moved to ConstSubnet*Ptr 2024-11-06 09:43:56 +01:00
Razvan Becheriu
31754d811d [#3587] addressed review 2024-10-28 07:58:38 -04:00
Thomas Markwalder
a198acc1e2 [#3587] Updated doc, messages, parsers, and UTs
/doc/sphinx/arm/classify.rst
/doc/sphinx/arm/dhcp4-srv.rst
/doc/sphinx/arm/dhcp6-srv.rst
/doc/sphinx/arm/hooks-class-cmds.rst
/doc/sphinx/arm/hooks-limits.rst
/src/bin/dhcp4/dhcp4_lexer.ll
/src/bin/dhcp4/dhcp4_messages.mes
/src/bin/dhcp4/dhcp4_srv.cc
/src/bin/dhcp4/tests/classify_unittest.cc
/src/bin/dhcp4/tests/config_parser_unittest.cc
/src/bin/dhcp6/dhcp6_messages.mes b/src/bin/dhcp6/dhcp6_messages.mes
/src/bin/dhcp6/dhcp6_srv.cc
/src/bin/dhcp6/tests/classify_unittest.cc
/src/bin/dhcp6/tests/config_parser_unittest.cc
/src/lib/dhcpsrv/tests/client_class_def_parser_unittest.cc
/src/share/api/class-get.json
2024-10-28 07:58:38 -04:00
Thomas Markwalder
37ff02e12b [#3587] Bulk of the code changes
Everything except parsers, UTs to test
deprecation, and doc.
2024-10-28 07:58:38 -04:00
Andrei Pavel
8036286956 [#3605] Add missing headers used for fuzzing 2024-10-24 19:48:18 +03:00
Andrei Pavel
9698dbcc63 [#3605] Include what you use on src/bin/dhcp*/dhcp*_srv.cc 2024-10-23 19:50:24 +00:00
Andrei Pavel
a18fa75bcf [#3605] Remove unused chrono 2024-10-23 19:50:24 +00:00
Andrei Pavel
a740d0bfe5
[#3605] Rotate ports on HTTP fuzzers as well 2024-10-23 16:40:37 +03:00
Andrei Pavel
a96168e762
[#3605] Integrate a new fuzzing solution in Kea
The solution is based on clusterfuzzlite, libfuzzer, and oss-fuzz
technologies.

- Add the .clusterfuzzlite directory.
- Add the fuzz CI stage and fuzzing CI jobs.
- Add the fuzzing targets in the fuzz directory.
- Document fuzzing in doxygen.
2024-10-23 16:40:31 +03:00
Andrei Pavel
58d4caa865
[#3605] Prepare existing code for fuzzing
- Separate ENABLE_AFL into ENABLE_FUZZING and HAVE_AFL.
- Add the --disable-unicode flag required in the oss-fuzz container.
- Add checking of support for C++17.
- Make Kea compile with afl++.
- Rotate ports in `getServerPort()` functions under an env var.
- Fix some destruction issues that would result in crashes when fuzzing.
- Add some checks in the UnixControlClient that prevent some crashes when fuzzing.
- Add `isc::util::isSocket()` function.
- Change `isc::util::file::Path` to not append a trailing slash to allow
  chained calls of `parentPath()`.
- Add `isc::util::file::TemporaryDirectory` useful when fuzzing.
2024-10-23 16:37:31 +03:00
Razvan Becheriu
f08c5d642b [#3619] destroy maangers before hook unload 2024-10-22 15:58:11 +00:00
Thomas Markwalder
64c15b1131 [#3583] Addressred review comments
modified:
    doc/sphinx/arm/classify.rst
    src/bin/dhcp4/dhcp4_srv.cc
    src/bin/dhcp4/tests/config_parser_unittest.cc
    src/bin/dhcp6/tests/config_parser_unittest.cc
    src/hooks/dhcp/mysql/mysql_cb_dhcp4.cc
    src/lib/dhcp/classify.cc
    src/lib/dhcp/classify.h
    src/lib/dhcp/tests/classify_unittest.cc
    src/lib/dhcpsrv/cfg_option.cc
    src/lib/dhcpsrv/cfg_option.h
    src/lib/dhcpsrv/parsers/option_data_parser.cc
    src/lib/dhcpsrv/parsers/simple_parser4.cc
    src/lib/dhcpsrv/parsers/simple_parser6.cc
    src/lib/dhcpsrv/tests/dhcp_parsers_unittest.cc
    src/lib/dhcpsrv/testutils/generic_backend_unittest.cc
2024-10-15 13:51:57 -04:00
Thomas Markwalder
b83340e635 [#3583] kea-dhcp4 now supports option class tagging
/src/bin/dhcp4/dhcp4_srv.cc
    Dhcpv4Srv::appendServerID() - modified to use the standard
    option defintion when appending a generated server id.

    Dhcpv4Srv::appendRequestedOptions()
    Dhcpv4Srv::appendRequestedVendorOptions()
    Dhcpv4Srv::appendBasicOptions()
    - modified to OptionDescriptor::allowedForClientClasses()

/src/bin/dhcp4/tests/classify_unittest.cc
    TEST_F(ClassifyTest, requestedOptionClassTagTest)
    TEST_F(ClassifyTest, vendorOptionClassTagTest)
    TEST_F(ClassifyTest, vivcoOptionClassTagTest)
    TEST_F(ClassifyTest, vivsoOptionClassTagTest)
    TEST_F(ClassifyTest, basicOptionClassTagTest)
    - new tests

/src/bin/dhcp4/tests/dhcp4_srv_unittest.cc
    TEST_F(Dhcpv4SrvTest, appendServerID) - updated test

/src/bin/dhcp4/tests/dhcp4_test_utils.*
    Dhcpv4SrvTest::checkServerIdentifier() - new function

/src/lib/dhcpsrv/cfg_option.*
    OptionDescriptor::allowedForClientClasses() - new function

/src/lib/dhcpsrv/tests/cfg_option_unittest.cc
    TEST(OptionDescriptorTest, allowedForClientClassesTest) - new test
2024-10-15 13:51:57 -04:00
Francis Dupont
9a3dd31864 [#3588] Addressed comments 2024-10-11 10:18:01 +02:00
Francis Dupont
dc8af16a6e [#3588] Modified no test required classes 2024-10-11 10:18:01 +02:00
Francis Dupont
069f1520c9 [#3590] Checkpoint: reversed required order 2024-10-07 15:06:40 +02:00
Razvan Becheriu
b116338663 [#3536] refactor getDBVersions 2024-10-03 21:04:37 +03:00
Razvan Becheriu
38ea2d6dab [#3536] removed empty line in getDBVersions 2024-10-03 21:04:37 +03:00
Razvan Becheriu
e1672f39e9 [#3536] remove Initializer 2024-10-03 21:04:37 +03:00
Razvan Becheriu
7db5e95100 [#3536] enable unittests 2024-10-03 21:04:37 +03:00
Razvan Becheriu
14c95b4705 [#3536] remove HAVE_MYSQL and HAVE_PGSQL 2024-10-03 21:04:36 +03:00
Marcin Siodelski
874513041a [#3565] Prevent declining expired and released 2024-10-01 16:20:35 +02:00
Razvan Becheriu
379ec3ec0a [#3536] moved from lib to hooks 2024-09-16 13:31:01 +00:00
Razvan Becheriu
d904a18699 [#3536] moved lease and host backends 2024-09-16 13:31:01 +00:00
Andrei Pavel
2aa6b29b13
[#1945] log EVAL_RESULT messages only at debug level
- Split the 15 occurrences of EVAL_RESULT into one message for each log call in code.
- Log all these messages only on debug level 50.
- Remove bad practice `catch (...)` and the message logged on that if-branch.
2024-08-22 15:47:23 +03:00
Francis Dupont
411a0b2353 [#3477] Checkpoint: updating servers 2024-08-01 09:23:53 +02:00
Francis Dupont
0975949b9c [#3094] Finished tests and doc 2024-07-18 14:45:25 +02:00
Francis Dupont
6901b0f0a5 [#3094] Checkpoint: added UTs, doc to do 2024-07-18 14:44:32 +02:00
Francis Dupont
8f1742a2d6 [#3094] Checkpoint: translated idea to code, need logs, UTs and doc 2024-07-18 14:44:32 +02:00
Razvan Becheriu
2da36722ea [#3446] added unittests 2024-07-16 12:43:21 +00:00
Marcin Siodelski
a52bf68db9 [#3246] Do not delete soft released leases 2024-06-19 12:34:18 +02:00
Francis Dupont
58cc9eb76c [#2755] Code done, doc to update 2024-06-14 22:44:34 +02:00
Thomas Markwalder
f49b1825cb [#3203] Log packet recv and send at INFO
Added ChangeLog entry

src/bin/dhcp4/dhcp4_srv.cc
    DHCP4_PACKET_RECEIVED and DHCP4_PACKET_SEND moved to INFO

src/bin/dhcp6/dhcp6_srv.cc
    DHCP6_PACKET_RECEIVED and DHCP6_PACKET_SEND moved to INFO
2024-05-10 14:00:26 -04:00
Francis Dupont
ebfcd3f9b8 [#2976] Began basic UTs 2024-04-26 18:25:06 +03:00
Francis Dupont
6213bed135 [#2976] Added recoverStashedAgentOption 2024-04-26 18:25:06 +03:00
Francis Dupont
60a92cc635 [#2976] Disabled stashed RAI copy into response 2024-04-26 18:25:06 +03:00
Piotrek Zadroga
9b4a2d26d5 [#2820] addressed review comments 2024-04-26 14:43:12 +02:00
Piotrek Zadroga
45eccb302e [#2820] revert some log msgs 2024-04-26 14:43:12 +02:00
Piotrek Zadroga
31da595b78 [#2820] add tid in some packets logs 2024-04-26 14:42:46 +02:00
Piotrek Zadroga
7b93d1b62b [#2820] add tid in some options logs 2024-04-26 14:42:46 +02:00
Piotrek Zadroga
e681090bd3 [#2820] add tid in some leases logs 2024-04-26 14:42:46 +02:00
Piotrek Zadroga
9d154be00c [#2820] add tid in all eval logs 2024-04-26 14:42:46 +02:00
Piotrek Zadroga
ca345208ea [#2820] add tid in some bad-packets logs 2024-04-26 14:42:46 +02:00
Andrei Pavel
677f8a8f0e
[#3254] consistent version output across executables
- replace VERSION with PACKAGE_VERSION in src/bin/admin to avoid
  overlap with VERSION used in src/share/database.
- add -V to kea-admin
- add -V to kea-shell
- add -V to keactrl
- add -V to perfdhcp
- removed getVersionAddendum from d2 and added the openssl version to
  the output of other process versions since it's not only used by d2
- make all -V outputs consistent. Some are showing only core version and
  are missing premium version which is fine since they are the
  executables that don't have something to do with premium directly
  anyway.
2024-04-24 15:23:48 +03:00
Andrei Pavel
a764025dfd
[#3254] show premium source in extended version 2024-04-24 15:23:48 +03:00
Razvan Becheriu
a0707133f8 [#3315] use stopAndPoll 2024-04-22 23:00:29 +03:00