Hi, On 04/11/2019 05:16, Leroy Tennison via Openvpn-users wrote: > I previously believed that all IP network communication was done at > layer 2 via arp and transmitting to the MAC address of the system > responding for it's IP address. Then I realized that OpenVPN doesn't > have MAC addresses, so how does communication coming into an OpenVPN > server from a non-OpenVPN interface get to OpenVPN's tun interface? Is > there a Linux facility to examine the routing table and transfer the > inbound packet to the interface irrespective of MAC address? If so, can > you tell me what it is or point me to some documentation about it? > Thanks for the help. >
Communication between different networks (i.e. interfaces) is always performed by means of "routing", hence by looking at the routing table of the system. The latter, based on the destination address (normally), will decide where to route the packets. The fact that the tun interface is L2 or L3 based does not affect this mechanism. Being L2 or L3 only changes the way packets traverses the tun interface. However, everything changes if you "bridge" interfaces together. Here you are creating a big single network. In this case all the "forwarding" happens at L2 and packets do not enter the routing table at all (unless they have to leave the bridge interface - then routing takes place again). But for this to happen all participating interfaces must be Ethernet/L2 based (i.e. TAP). In any case, this is not OpenVPN related, but much more about how routing/forwarding works. You can easily google for this terms and find a lot of literature. Regards, -- Antonio Quartulli _______________________________________________ Openvpn-users mailing list Openvpn-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-users