开发者

NAT traversal without an external server

I have been reading about TURN and STUN servers because I would like to develop a browser-to-browser application so that BrowserA (behind a NAT) could communicate with BrowserB (behind a NAT). In this case, I think I should use TURN protocol.

My question: 开发者_如何学Gois there any other solution that does NOT require an external phisical server? A just-software solution would be simply perfect.

THANKS


Answer is no.

Explanation: NAT stands for Network Address Translation. It means translation of the 'private' IP of your device which is valid only on the LAN (Local Area Network) into a 'public' IP address which valid on the WAN (i.e., the wild wild part of the Internet that is on the other side of your NAT).

The problem is that the translated address is only visible from outside your LAN. Hence, you need a reachable device out there to read it and sent it back to you (or other peers).

You will always need a server/central peer to help establishing a connection between two peers located behind different NATs when they both have a private IP addresses.


http://samy.pl/pwnat/ works without an intermediary but also moving this question to serverfault might help :)


Thanks. Let's imagine that BrowserA (the one who starts the communication) knows the public IP of BrowserB, but not the other way round. It is the same answer for this question?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜