isV6Format() returns true for IPv4 addresses
Opened this issue · 2 comments
WRMSRwasTaken commented
Hi,
isV6Format()
returns true for non IPv6 mapped IPv4 adresses:
console.log(require('ip').isV6Format('8.8.8.8')); //true
Using Version 1.1.4
on Node v7.3.0
Redsandro commented
Was going to report the same.
ip.isV4Format('127.0.0.1') // true
ip.isV6Format('127.0.0.1') // true
ip.isV4Format('::1') // false
ip.isV6Format('::1') // true
ip 1.1.4
on node 4.2.6
Jolg42 commented
Same for me, I switched to https://github.com/LinusU/is-my-ip-valid