Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Block Internet Access Unless Connect To VPN?
I use NordVPN which has a CLI app available to use. I like using the app since it is easy to connect to any server and it works on IPv4 and IPv6 unlike the built in VPN settings in most Linux distro settings.

Is there a way to block all internet access unless you are connected to a VPN? I know when I was using NordVPN on Windows 10 I was able to enable a setting in the NordVPN windows app which will block the internet unless I was connect to NordVPN.

I have found some solutions but they require you to insert the IP address of the VPN server you want to whitelist so it can connect to the VPN. The problem for me is that since I use the CLI app, it will always connect to a random server everyday which means the IP address changes daily and I like this since it is not wise to connect to the same server all the time.

Any help will be most appreciated! Smile
In another post, someone share me this Gufw profile that you can use to have it so your internet connection will be blocked unless your connected to a vpn. But this will also block Tor (OnionShare, Brave browser Tor tabs, Tor browser) when there is no VPN connection.

Does anyone know of a way to expand on this profile to make it so Tor connections will be allowed weather you are connected to a vpn or not?

Forum Jump:

Users browsing this thread: 1 Guest(s)