hackerschoice / gsocket

Connect like there is no firewall. Securely.
https://www.gsocket.io
BSD 2-Clause "Simplified" License
1.53k stars 129 forks source link

Please document how NAT traversal works #14

Closed jgoerzen closed 3 years ago

jgoerzen commented 3 years ago

Hi,

I just discovered this and it looks fantastic! Could you please document how the TCP nat traversal works? I was previously aware of UDP methods, but not TCP methods where both ends were behind NAT/firewall. It would be fantastic to understand how it works.

thanks!

SkyperTHC commented 3 years ago

Both workstations establish an outgoing connection to the relay server. The relay server then forwards traffic between the two connected sockets. There are no incoming connections. Means that NAT does not need to be 'pierced'.

jgoerzen commented 3 years ago

Ah, I missed the relay server in the description. My fault. Sorry.