]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Add tests to validate ipv4->ipv6 example (#3069)
authorJorge Pereira <jpereira@users.noreply.github.com>
Thu, 24 Oct 2019 18:22:34 +0000 (15:22 -0300)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Thu, 24 Oct 2019 18:22:34 +0000 (14:22 -0400)
src/tests/unit/dhcpv6_rfc3319.txt

index fb5528df1da65c060ff64a2ab52006cfcab80f00..5e13e59417f82f73abb4ba50f4febe2c5f5aecb7 100644 (file)
@@ -27,6 +27,11 @@ match 00 15 00 1c 03 77 77 77 07 65 78 61 6d 70 6c 65 03 63 6f 6d 00 03 66 74 70
 #  3.2 SIP Servers IPv6 Address List
 #
 
+# convert ipv4 to ipv6
+# e.g: 0:0:0:0:0:ffff:102:304
+encode-pair SIP-Server-Address = 1.2.3.4
+match 00 16 00 10 00 00 00 00 00 00 00 00 00 00 ff ff 01 02 03 04
+
 # short ipv6
 encode-pair SIP-Server-Address = 2001:4860:4860::8888
 match 00 16 00 10 20 01 48 60 48 60 00 00 00 00 00 00 00 00 88 88
@@ -42,4 +47,4 @@ encode-pair SIP-Server-Address = 2001:0db8:85a3:0000:0000:8a2e:0370:7334, SIP-Se
 match 00 16 00 30 20 01 0d b8 85 a3 00 00 00 00 8a 2e 03 70 73 34 20 01 0d b8 85 a3 00 00 00 00 8a 2e 03 70 73 35 20 01 48 60 48 60 00 00 00 00 00 00 00 00 88 88
 
 count
-match 16
+match 18