Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Kea
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Sebastian Schrader
Kea
Commits
d0d51539
Commit
d0d51539
authored
Dec 16, 2016
by
Tomek Mrugalski
🛰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[5017] Examples for echo-client-id and match-client-id added.
parent
5eb78ae5
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
36 additions
and
8 deletions
+36
-8
doc/examples/kea4/hooks.json
doc/examples/kea4/hooks.json
+5
-1
doc/examples/kea4/several-subnets.json
doc/examples/kea4/several-subnets.json
+28
-7
src/bin/dhcp4/.gitignore
src/bin/dhcp4/.gitignore
+1
-0
src/bin/dhcp4/dhcp4_lexer.ll
src/bin/dhcp4/dhcp4_lexer.ll
+2
-0
No files found.
doc/examples/kea4/hooks.json
View file @
d0d51539
...
...
@@ -37,7 +37,11 @@
"library"
:
"/opt/lib/security.so"
},
{
"library"
:
"/opt/lib/charging.so"
"library"
:
"/opt/lib/charging.so"
,
"parameters"
:
{
"path"
:
"/var/kea/var"
,
"base-name"
:
"kea-forensic6"
}
}
]
}
...
...
doc/examples/kea4/several-subnets.json
View file @
d0d51539
...
...
@@ -27,15 +27,36 @@
"renew-timer"
:
1000
,
"rebind-timer"
:
2000
,
#
RFC
6842
says
that
the
server
is
supposed
to
echo
back
client-id
option.
#
However
,
some
older
clients
do
not
support
this
and
are
getting
confused
#
when
they
get
their
own
client-id.
Kea
can
disable
RFC
6842
support.
"echo-client-id"
:
false
,
#
Some
clients
don't
use
stable
client
identifier
,
but
rather
generate
them
#
during
each
boot.
This
may
cause
a
client
that
reboots
frequently
to
get
#
multiple
leases
,
which
may
not
be
desirable.
As
such
,
sometimes
admins
#
prefer
to
tell
their
DHCPv
4
server
to
ignore
client-id
value
altogether
#
and
rely
exclusively
on
MAC
address.
This
is
a
parameter
that
is
defined
#
globally
,
but
can
be
overridden
on
a
subnet
level.
"match-client-id"
:
true
,
#
The
following
list
defines
subnets.
Each
subnet
consists
of
at
#
least
subnet
and
pool
entries.
"subnet4"
:
[
{
"pools"
:
[
{
"pool"
:
"192.0.2.1 - 192.0.2.200"
}
],
"subnet"
:
"192.0.2.0/24"
},
{
"pools"
:
[
{
"pool"
:
"192.0.3.100 - 192.0.3.200"
}
],
"subnet"
:
"192.0.3.0/24"
},
{
"pools"
:
[
{
"pool"
:
"192.0.4.1 - 192.0.4.254"
}
],
"subnet"
:
"192.0.4.0/24"
}
]
"subnet4"
:
[
{
"pools"
:
[
{
"pool"
:
"192.0.2.1 - 192.0.2.200"
}
],
"subnet"
:
"192.0.2.0/24"
},
{
#
This
particular
subnet
has
match-client-id
value
changed.
"pools"
:
[
{
"pool"
:
"192.0.3.100 - 192.0.3.200"
}
],
"subnet"
:
"192.0.3.0/24"
,
"match-client-id"
:
false
},
{
"pools"
:
[
{
"pool"
:
"192.0.4.1 - 192.0.4.254"
}
],
"subnet"
:
"192.0.4.0/24"
}
]
},
#
The
following
configures
logging.
It
assumes
that
messages
with
at
least
...
...
src/bin/dhcp4/.gitignore
View file @
d0d51539
...
...
@@ -5,3 +5,4 @@
/spec_config.h
/spec_config.h.pre
/s-messages
/dhcp4_parser.report
src/bin/dhcp4/dhcp4_lexer.ll
View file @
d0d51539
...
...
@@ -862,6 +862,7 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence}
\"
echo-client-id\
" {
switch(driver.ctx_) {
case isc::dhcp::Parser4Context::DHCP4:
case isc::dhcp::Parser4Context::SUBNET4:
return isc::dhcp::Dhcp4Parser::make_ECHO_CLIENT_ID(driver.loc_);
default:
...
...
@@ -871,6 +872,7 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence}
\"
match-client-id\
" {
switch(driver.ctx_) {
case isc::dhcp::Parser4Context::DHCP4:
case isc::dhcp::Parser4Context::SUBNET4:
return isc::dhcp::Dhcp4Parser::make_MATCH_CLIENT_ID(driver.loc_);
default:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment