I've been searching high and low for how exactly OpenVPN implements tun mode (l3 - routing). I've found a load of generic articles that explain the high-level view, but am looking for something a bit more detailed. I'd like to know how the tunneling procedure is actually implemented. Is it similar in nature to GRE?
In my particular implementation right now (I am just learning), I have an OpenVPN for Windows (not Open Access Server) running on a Windows Server 2019 instance. I then likewise installed it on my W10 lab laptop. As such, both devices are on the same LAN, but on different subnets. I have been able to get everything working properly, now I am just trying to understand how it works. I get the basics of what is going on - that packets are being encapsulated in packets - but I'd like a little more detail on how exactly that process is taking place.
I've run a route print (netstat -r) on both my server and my laptop. Here's what I see on my laptop:
Code: Select all
Network Destination Netmask Gateway Interface Metric
192.168.50.1 255.255.255.255 192.168.50.5 192.168.50.6 25
192.168.50.4 255.255.255.252 On-link 192.168.50.6 281
192.168.50.6 255.255.255.255 On-link 192.168.50.6 281
192.168.50.7 255.255.255.255 On-link 192.168.50.6 281