diff options
author | Asbjørn Sloth Tønnesen <ast@2e8.dk> | 2019-07-18 18:44:18 +0000 |
---|---|---|
committer | Asbjørn Sloth Tønnesen <ast@2e8.dk> | 2019-07-18 18:44:18 +0000 |
commit | ecf033ea15c312f6153ca761ee329058de5de918 (patch) | |
tree | 0165bebca91b7d3b10efb0229892dd24577ca9ac | |
parent | e92fb277616ede376d81853c052bc399c198e15d (diff) | |
download | lua-inet-ecf033ea15c312f6153ca761ee329058de5de918.tar.gz lua-inet-ecf033ea15c312f6153ca761ee329058de5de918.tar.xz lua-inet-ecf033ea15c312f6153ca761ee329058de5de918.zip |
add another well-known mixed network
Signed-off-by: Asbjørn Sloth Tønnesen <ast@2e8.dk>
-rw-r--r-- | README.rst | 9 | ||||
-rw-r--r-- | lua/inet/init.lua | 3 |
2 files changed, 10 insertions, 2 deletions
@@ -47,7 +47,14 @@ IPv6 mixed notation configuration should use mixed notation, ie. last 32 bits formatted as IPv4, as per `RFC 5952`_ section 5. -Initially the set only contains the well-known ``::ffff:0.0.0.0/96`` network. +Initially the set contains these well-known networks: + +:: + + inet.mixed_networks:list() -- returns { + inet('::ffff:0:0/96'), -- RFC 5156 + inet('64:ff9b::/96'), -- RFC 6052 + } Common ``inet*`` API -------------------- diff --git a/lua/inet/init.lua b/lua/inet/init.lua index a504ddd..1bb0121 100644 --- a/lua/inet/init.lua +++ b/lua/inet/init.lua @@ -12,7 +12,8 @@ end do local mixed_networks = set.new() - mixed_networks:add(new_inet('::ffff:0.0.0.0/96')) + mixed_networks:add(new_inet('::ffff:0:0/96')) -- RFC 5156 + mixed_networks:add(new_inet('64:ff9b::/96')) -- RFC 6052 M.mixed_networks = mixed_networks core.set_mixed_networks(mixed_networks) end |