summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorThomas Markwalder <tmark@isc.org>2024-10-31 19:37:19 +0100
committerThomas Markwalder <tmark@isc.org>2024-11-26 18:19:56 +0100
commitb4ca3bdd202694e05641de9ff4d8e8fd87c9c84b (patch)
treeda6f88577dae8f20f9bab48c979d094596c1abcf /doc
parent[#3592] Update kea-dhcp4 parsing and UTs (diff)
downloadkea-b4ca3bdd202694e05641de9ff4d8e8fd87c9c84b.tar.xz
kea-b4ca3bdd202694e05641de9ff4d8e8fd87c9c84b.zip
[#3582] Update kea-dhcp6 parsing and UTs
/doc/examples/kea4/all-keys.json /doc/examples/kea4/classify.json /doc/examples/kea4/classify2.json /doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json /doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json /doc/examples/kea4/ha-load-balancing-server2-mt.json /doc/examples/kea4/ha-load-balancing-server2-mt.json /doc/examples/kea4/hooks-radius.json /doc/examples/kea6/all-keys.json /src/bin/dhcp4/tests/config_parser_unittest.cc TEST_F(Dhcp4ParserTest, deprecatedClientClassesCheck) - new test /src/bin/dhcp4/tests/get_config_unittest.cc updated /src/bin/dhcp6/dhcp6_lexer.ll /src/bin/dhcp6/dhcp6_parser.yy added support for client-classes /src/bin/dhcp6/tests/config_parser_unittest.cc updated TEST_F(Dhcp6ParserTest, sharedNetworksDeriveClientClass) - removed obsolete test TEST_F(Dhcp6ParserTest, deprecatedClientClassesCheck) - new test /src/bin/dhcp6/tests/get_config_unittest.cc /src/bin/dhcp6/tests/host_unittest.cc /src/bin/dhcp6/tests/shared_network_unittest.cc updated src/lib/dhcpsrv/parsers/simple_parser6.cc Corrected globals
Diffstat (limited to 'doc')
-rw-r--r--doc/examples/kea4/all-keys.json30
-rw-r--r--doc/examples/kea4/classify.json4
-rw-r--r--doc/examples/kea4/classify2.json8
-rw-r--r--doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json8
-rw-r--r--doc/examples/kea4/ha-load-balancing-server2-mt.json8
-rw-r--r--doc/examples/kea4/hooks-radius.json4
-rw-r--r--doc/examples/kea6/all-keys.json37
7 files changed, 52 insertions, 47 deletions
diff --git a/doc/examples/kea4/all-keys.json b/doc/examples/kea4/all-keys.json
index 0c71d8b9f1..2bcab40a92 100644
--- a/doc/examples/kea4/all-keys.json
+++ b/doc/examples/kea4/all-keys.json
@@ -859,9 +859,9 @@
"boot-file-name": "/dev/null",
// Restricts this shared network to allow only clients
- // that belong to a particular client class. If an
- // empty string is provided, no restriction is applied.
- "client-class": "",
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [],
// Shared-network level value. See description at the global level.
"ddns-generated-prefix": "myhost",
@@ -998,10 +998,10 @@
// Subnet-level bootfile name, set in 'file' field.
"boot-file-name": "",
- // Restricts this subnet to allow only clients that belong
- // to a particular client class. If an empty string is
- // provided, no restriction is applied.
- "client-class": "",
+ // Restricts this subnet to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [],
// Subnet-level value. See description at the global level.
"ddns-generated-prefix": "myhost",
@@ -1076,7 +1076,7 @@
// option will be applied. If the list is empty or is
// omitted this option will be applied regardless of class
// membership.
- "client-classes": [ ],
+ "client-classes": [],
// Option code.
"code": 3,
@@ -1105,9 +1105,10 @@
// List of IP address pools belonging to the subnet.
"pools": [
{
- // Restricts this pool to only be used for client
- // requests belonging to a particular client class.
- "client-class": "phones_server1",
+ // Restricts this pool to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [ "phones_server1" ],
// Pool-level list of DHCP options.
"option-data": [],
@@ -1120,9 +1121,10 @@
"evaluate-additional-classes": [ "late" ]
},
{
- // Restricts this pool to only be used for client
- // requests belonging to a particular client class.
- "client-class": "phones_server2",
+ // Restricts this pool to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [ "phones_server2" ],
// Pool-level list of DHCP options.
"option-data": [],
diff --git a/doc/examples/kea4/classify.json b/doc/examples/kea4/classify.json
index 9af06d8377..5f0c668b49 100644
--- a/doc/examples/kea4/classify.json
+++ b/doc/examples/kea4/classify.json
@@ -83,7 +83,7 @@
"pools": [ { "pool": "192.0.2.1 - 192.0.2.200" } ],
"id": 1,
"subnet": "192.0.2.0/24",
- "client-class": "VoIP",
+ "client-classes": [ "VoIP" ],
"interface": "eth0"
},
@@ -113,7 +113,7 @@
// This one is for VoIP devices only.
{
"pool": "192.0.4.1 - 192.0.4.200",
- "client-class": "VoIP"
+ "client-classes": [ "VoIP" ]
},
// This one doesn't have any client-class specified,
diff --git a/doc/examples/kea4/classify2.json b/doc/examples/kea4/classify2.json
index 0f9cf09dea..34da597507 100644
--- a/doc/examples/kea4/classify2.json
+++ b/doc/examples/kea4/classify2.json
@@ -92,7 +92,7 @@
"pools": [ { "pool": "192.0.2.1 - 192.0.2.200" } ],
"id": 1,
"subnet": "192.0.2.0/24",
- "client-class": "VoIP",
+ "client-classes": [ "VoIP" ],
"interface": "eth0"
},
// This one doesn't have any client-class specified, so everyone
@@ -122,7 +122,7 @@
{
// This one is for VoIP devices only.
"pool": "192.0.4.1 - 192.0.4.200",
- "client-class": "VoIP"
+ "client-classes": [ "VoIP" ]
},
// This one doesn't have any client-class specified, so everyone
// is allowed in.
@@ -144,11 +144,11 @@
"pools": [
{
"pool": "192.0.8.100 - 192.0.8.200",
- "client-class": "UNKNOWN"
+ "client-classes": [ "UNKNOWN" ]
},
{
"pool": "192.0.9.100 - 192.0.9.200",
- "client-class": "KNOWN"
+ "client-classes": [ "KNOWN" ]
}
],
"id": 4,
diff --git a/doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json b/doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json
index fdef507e70..c7d08e7725 100644
--- a/doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json
+++ b/doc/examples/kea4/ha-load-balancing-server1-mt-with-tls.json
@@ -214,19 +214,19 @@
"pools": [
{
"pool": "192.0.3.100 - 192.0.3.125",
- "client-class": "phones_server1"
+ "client-classes": [ "phones_server1" ]
},
{
"pool": "192.0.3.126 - 192.0.3.150",
- "client-class": "laptops_server1"
+ "client-classes": [ "laptops_server1" ]
},
{
"pool": "192.0.3.200 - 192.0.3.225",
- "client-class": "phones_server2"
+ "client-classes": [ "phones_server2" ]
},
{
"pool": "192.0.3.226 - 192.0.3.250",
- "client-class": "laptops_server2"
+ "client-classes": [ "laptops_server2" ]
}
],
diff --git a/doc/examples/kea4/ha-load-balancing-server2-mt.json b/doc/examples/kea4/ha-load-balancing-server2-mt.json
index 154a129f8a..223d69bd2d 100644
--- a/doc/examples/kea4/ha-load-balancing-server2-mt.json
+++ b/doc/examples/kea4/ha-load-balancing-server2-mt.json
@@ -197,19 +197,19 @@
"pools": [
{
"pool": "192.0.3.100 - 192.0.3.125",
- "client-class": "phones_server1"
+ "client-classes": [ "phones_server1" ]
},
{
"pool": "192.0.3.126 - 192.0.3.150",
- "client-class": "laptops_server1"
+ "client-classes": [ "laptops_server1" ]
},
{
"pool": "192.0.3.200 - 192.0.3.225",
- "client-class": "phones_server2"
+ "client-classes": [ "phones_server2" ]
},
{
"pool": "192.0.3.226 - 192.0.3.250",
- "client-class": "laptops_server2"
+ "client-classes": [ "laptops_server2" ]
}
],
diff --git a/doc/examples/kea4/hooks-radius.json b/doc/examples/kea4/hooks-radius.json
index 164e6f8577..98a1478754 100644
--- a/doc/examples/kea4/hooks-radius.json
+++ b/doc/examples/kea4/hooks-radius.json
@@ -106,12 +106,12 @@
{
// Red pool (10-19 are for reservations)
"pool": "192.0.2.20-192.0.2.99",
- "client-class": "red"
+ "client-classes": [ "red" ]
},
{
// White pool (110-119 are for reservations)
"pool": "192.0.2.120-192.0.2.199",
- "client-class": "white"
+ "client-classes": [ "white" ]
}
// Note there are not pools available to anyone. This is
diff --git a/doc/examples/kea6/all-keys.json b/doc/examples/kea6/all-keys.json
index 6ac1bb3f83..c91c0a1f19 100644
--- a/doc/examples/kea6/all-keys.json
+++ b/doc/examples/kea6/all-keys.json
@@ -802,9 +802,9 @@
"pd-allocator": "iterative",
// Restricts this shared network to allow only clients
- // that belong to a particular client class. If an
- // empty string is provided, no restriction is applied.
- "client-class": "",
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [],
// Shared-network level value. See description at the global level.
"ddns-generated-prefix": "myhost",
@@ -933,10 +933,10 @@
// for the subnet.
"pd-allocator": "iterative",
- // Restricts this subnet to allow only clients that belong
- // to a particular client class. If an empty string is
- // provided, no restriction is applied.
- "client-class": "",
+ // Restricts this subnet to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [],
// Subnet-level value. See description at the global level.
"ddns-generated-prefix": "myhost",
@@ -1004,7 +1004,7 @@
// option will be applied. If the list is empty or is
// omitted this option will be applied regardless of class
// membership.
- "client-classes": [ ],
+ "client-classes": [],
// Option code.
"code": 7,
@@ -1034,9 +1034,10 @@
// clients.
"pd-pools": [
{
- // Restricts this prefix pool to be used only for the client
- // requests belonging to a particular client class.
- "client-class": "phones_server1",
+ // Restricts this prefix pool subnet to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [ "phones_server1" ],
// Length of prefixes delegated to clients.
"delegated-len": 64,
@@ -1083,9 +1084,10 @@
// List of IP address pools belonging to the subnet.
"pools": [
{
- // Restricts this pool to only be used for client
- // requests belonging to a particular client class.
- "client-class": "phones_server1",
+ // Restricts this pool subnet to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [ "phones_server1" ],
// Pool-level list of DHCP options.
"option-data": [],
@@ -1098,9 +1100,10 @@
"evaluate-additional-classes": [ "late" ]
},
{
- // Restricts this pool to only be used for client
- // requests belonging to a particular client class.
- "client-class": "phones_server2",
+ // Restricts this pool subnet to allow only clients
+ // that belong to at least one class in this list. If omitted
+ // or an empty list is provided, no restriction is applied.
+ "client-classes": [ "phones_server2" ],
// Pool-level list of DHCP options.
"option-data": [],