linux-cli-community
linux-cli-community copied to clipboard
[BUG] is_valid_ip checks an IPv4 format, IPv6 fails
Describe the bug While trying to add an IPv6 address in split tunneling it rejects it as invalid.
To Reproduce Steps to reproduce the behavior:
- sudo protonvpn configure
-
- Split Tunneling
- Enable split tunneling? [y/N]: y
- try to add
::1 - invalid IP
Expected behavior Accept IPv6 addresses. If not, clarify that only IPv4 is supported for now.
Error Messages/Program Output/Log Messages (~/.pvpn-cli/pvpn-cli.log)
[!] Invalid IP
Please enter an IP or CIDR to exclude from VPN.
Desktop (please complete the following information):
- OS: Ubuntu 20.04.2 LTS
- Python Version: 3.8.5
- ProtonVPN-CLI Version: v2.2.6
Additional context
If IPv6 is supported seems like is_valid_ip in utils.py should also match IPv6 address format with another regex.