Hi,

I would like to learn how a VPN works, but all I could google up were
phrases like "VPN creates a private tunnel/road/connection between two points/LAN, piggybacked on the internet, and making both LAN appear like a single one." However, the above does not explain anything useful at all, at least for me =(.

I think I can better understand if someone can do a step-by-step "packet walkthrough" when a request is sent from LAN-A-client-1 to LAN-B-client-1. This could also show the difference versus P2P (e.g torrent) connections. Appreciate it very much. Thanks!

As an example, and a wild guess, this is how it could go:
1. LAN-A-client-1 creates a packet set for a destination VPN-IP
2. packet is "intercepted" and process by LAN-A-client-1-VPN-client
3. LAN-A-client-1-VPN-client sees that VPN-IP is not on LAN-A.
4. LAN-A-client-1-VPN-client encrypts packet, appending with VPN-IP in headers.
5. LAN-A-client-1-VPN-client modify destination IP to VPN-SERVER IP
6. LAN-A-client-1-VPN-client sends packet to LAN-A-router
7. LAN-A-router reads destination VPN-SERVER IP
8. LAN-A-router sends the packet over the internet to the VPN-SERVER IP
9. The internet does its usual stuff: dns resolution, filter,.. etc etc.
10. VPN-SERVER recieves packet, decrypts and read the destination VPN-IP (virtual) from headers.
11. VPN-SERVER translates VPN-IP to LAN-B IP
12. VPN-SERVER reconstruct packet, send out to internet again, destination set to LAN-B IP (external IP of LAN-B)
13. LAN-B gateway/router recieves the packet and [insert task], routes to LAN-B-client-1.
14. end.

Recommended Answers

All 2 Replies

Thanks rch1231, but I have already been to that site, and it is not explaining anything useful. The whole page can be summarized in by the phrase i gave in my opening post. (Actually, I use that website for many other topics, but somehow it is pretty bad at explaining VPN)

Most similar "How VPN works" like this one, is really "What VPN can do".

I wish to understand the process of how it is really working, including the tunneling what happens to a TCP/IP request/packet after it has been generated by an application, targetted at a LAN client which physically is in another LAN.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.