openvpn-gui
openvpn-gui copied to clipboard
[Request] Network lock
Can u add a network lock option where if enabled and open vpn is running, it blocks all network and internet access, when its not connected to a vpn. Thanks
Doing this in a reliable and generic way is hard. Further it would need admin rights while the GUI is supposed to be run with limited privileges.
In my view this is the job of the firewall. You can easily block all traffic through the LAN adapter except to the VPN servers/ports using a couple of lines of firewall rules. Then network access will become available only when the VPN tunnel is up.
Doing this in a reliable and generic way is hard but not impossible. The principle should be similar to block-outside-dns
. AFAIK AzireVPN client does this, maybe we should port the code from there.
Windscribe VPN client has this feature, and it allows importing of custom configs. See here: https://blog.windscribe.com/windscribe-1-83-win-mac-changelog-6ae00c0e07cd