JamesClonk / vultr

:penguin: Vultr CLI and API client library
https://jamesclonk.github.io/vultr/
MIT License
379 stars 75 forks source link

lib: fix unmarshalling ipv6 ::/0 #48

Closed squat closed 7 years ago

squat commented 7 years ago

If you log into Vultr console and create an IPv6 firewall rule for ::/0 then in the CLI you do:

vultr firewall rule list <firewall group ID>

you incorrectly get a IPv4 CIDR like so:

RULE_NUM        ACTION  PROTOCOL        PORT    NETWORK
1               accept  tcp             80    0.0.0.0/0

This PR fixes this issue and adds a test to validate.

squat commented 7 years ago

Ping @JamesClonk

JamesClonk commented 7 years ago

thanks! 👍