You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Only
IPAddress.parse('::ffff:1.2.3.4/120') is a mapped ipv6 value!
Only here it is allowed to handle it as an Mapped IPv6 Object with the following output:
=> "::ffff:1.2.3.4/120"
The text was updated successfully, but these errors were encountered:
if value =~ /:/
converted = value.gsub(/([0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3})/) { |a| IPAddr.new("::#{a}").to_string.slice(-9, 9) }
else
converted = value
end
IPAddress.parse(converted)
Hi guys,
i have found a bug.
It is allowed to use dot notation in ipv6. The following address is not a mapped ipv6 address.
IPAddress.parse('abcd:9234::1.2.3.4/96').to_string
I got a wrong output
=> ::ffff:9.2.3.4/96
But the correct output must be:
=> abcd:9234::102:304/96
Same problem here:
IPAddress.parse('::1.2.3.4/120').to_string
=> "::ffff:1.2.3.4/120"
Correct output is
=> ::102:304/120
Only
IPAddress.parse('::ffff:1.2.3.4/120') is a mapped ipv6 value!
Only here it is allowed to handle it as an Mapped IPv6 Object with the following output:
=> "::ffff:1.2.3.4/120"
The text was updated successfully, but these errors were encountered: