]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Test decoding repeated options at the end of a DHCPv4 packet
authorNick Porter <nick@portercomputing.co.uk>
Thu, 23 Oct 2025 09:31:02 +0000 (10:31 +0100)
committerNick Porter <nick@portercomputing.co.uk>
Thu, 23 Oct 2025 09:31:02 +0000 (10:31 +0100)
src/tests/unit/protocols/dhcpv4/packet.txt

index 466f3f7f16e73f015466d4ed32294d917b82333b..6e755120a5f7651a3124587cc247c24b35d54978 100644 (file)
@@ -28,5 +28,11 @@ decode-proto 01 01 06 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0
 #
 match Opcode = ::Client-Message, Hardware-Type = ::Ethernet, Hardware-Address-Length = 6, Hop-Count = 0, Transaction-Id = 0, Number-of-Seconds = 0, Flags = 0, Client-IP-Address = 0.0.0.0, Your-IP-Address = 0.0.0.0, Server-IP-Address = 0.0.0.0, Gateway-IP-Address = 10.11.19.3, Client-Hardware-Address = 44:48:42:66:00:5a, Message-Type = ::Discover, Subnet-Mask = 255.255.255.0, Captive-Portal = 0x7777772e6578616d706c652e636f6d, Network-Subnet = 10.11.19.3/32
 
+#
+#  Test having repeated options at the end of the packet
+#
+decode-proto 01 01 06 00 e9 6f ee 16 00 fd 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0a 0b 13 02 6c 92 cf 01 a0 b0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 35 01 01 0c 1c 6d 6b 62 6e 65 74 2d 54 68 69 6e 6b 53 74 61 74 69 6f 6e 2d 50 33 2d 54 6f 77 65 72 37 0d 01 1c 02 03 0f 06 77 0c 2c 2f 1a 79 2a 52 08 01 06 31 30 35 32 35 30 52 0d 02 0b 6e 6f 6e 65 78 69 73 74 65 6e 74 ff
+match Opcode = ::Client-Message, Hardware-Type = ::Ethernet, Hardware-Address-Length = 6, Hop-Count = 0, Transaction-Id = 3916426774, Number-of-Seconds = 253, Flags = 0, Client-IP-Address = 0.0.0.0, Your-IP-Address = 0.0.0.0, Server-IP-Address = 0.0.0.0, Gateway-IP-Address = 10.11.19.2, Client-Hardware-Address = 6c:92:cf:01:a0:b0, Message-Type = ::Discover, Hostname = "mkbnet-ThinkStation-P3-Tower", Parameter-Request-List = ::Subnet-Mask, Parameter-Request-List = ::Broadcast-Address, Parameter-Request-List = ::Time-Offset, Parameter-Request-List = ::Router-Address, Parameter-Request-List = ::Domain-Name, Parameter-Request-List = ::Domain-Name-Server, Parameter-Request-List = ::Domain-Search, Parameter-Request-List = ::Hostname, Parameter-Request-List = ::NETBIOS-Name-Servers, Parameter-Request-List = ::NETBIOS, Parameter-Request-List = ::Interface-MTU-Size, Parameter-Request-List = ::Classless-Static-Route, Parameter-Request-List = ::NTP-Servers, Relay-Agent-Information = { Circuit-Id = 0x313035323530, Remote-Id = 0x6e6f6e6578697374656e74 }, Network-Subnet = 10.11.19.2/32
+
 count
-match 13
+match 15