NATDetectServer Class Reference

#include <NATDetectServer.h>

Inheritance diagram for NATDetectServer:

Inheritance graph
[legend]
Collaboration diagram for NATDetectServer:

Collaboration graph
[legend]

List of all members.

Public Types

enum  Reply { kReply_Pending = 0, kReply_Success, kReply_Timeout }
enum  { kDefaultPort = 3003, kDefaultPortOther = 3004 }

Public Member Functions

bool Start (const XPAddress &address=XPAddress(kDefaultPort), const XPAddress &addressOther=XPAddress(kDefaultPortOther))
virtual void CallbackGotNATDetectProbe (const XPAddress &address) const


Detailed Description

A stateless server that responds to query packets with the encoded public IP address of the source. Two instances of this server should be run each on their own separate IP address (in total four IP address:port pairs are used) to allow the NATDetectClient to deduce the NAT type. Assuming a setup with two IP addresses 88.208.234.187 and 88.208.234.188:
A multihomed machine with two or more public IP addresses could use: RLSrvNATDetect.exe /i /s -addr 88.208.234.187:3003 -addr2 88.208.234.187:3004 -addr 88.208.234.188:3003 -addr2 88.208.234.188:3004
A setup with one public IP address for each machine would need to use two machines: RLSrvNATDetect.exe /i /s -addr 88.208.234.187:3003 -addr2 88.208.234.187:3004
RLSrvNATDetect.exe /i /s -addr 88.208.234.188:3003 -addr2 88.208.234.188:3004

Generated on Sat Jun 28 22:02:33 2008 for ReplicaNet and RNLobby by  doxygen 1.5.3