mirror of
https://github.com/kernelkit/infix.git
synced 2026-07-31 04:53:01 +02:00
Let's drop the leading IETF or Infix prefixes from tests. Initially the idea was to mimnic the YANG models, but it's difficult to navigate and does not provide any real benefit to developers or end-users. Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
=== DHCP option 121 vs option 3
ifdef::topdoc[:imagesdir: {topdoc}../../test/case/dhcp/client_routes]
==== Description
Verify that DHCP option 121 (classless static routes) is used over the
older option 3 (default gateway) in the DHCP client, when both are sent
by the server, see RFC3442. Use the routing RIB in the operational
datastore to verify.
Installing routes from a DHCP server should not affect already existing
(static) routes. To verify this, a static canary route (20.0.0.0/24 via
192.168.0.2) is installed before starting the DHCP client. As a twist,
this canary route has a next-hop (192.168.0.2) which is not reachable
until a DHCP lease has been acquired.
The DHCP server is set up to hand out both a default router (option 3)
via 192.168.0.1 and a default route (option 121) via 192.168.0.254.
==== Topology
image::topology.svg[DHCP option 121 vs option 3 topology, align=center, scaledwidth=75%]
==== Sequence
. Setting up canary route, 20.0.0.0/24 via 192.168.0.2
. Enabling DHCP client, allow option 3 and 121
. Verify client has route 10.0.0.0/24 via 192.168.0.254 (option 121)
. Verify client has default route via 192.168.0.254 (not use option 3)
. Verify client still has canary route to 20.0.0.0/24 via 192.168.0.2