Stun Server
Compliant with the latest RFCs including 5389, 5769, and 5780
discover the local host's own external IP address
|
#include <stunsocketthread.h>
Public Member Functions | |
CStunSocketThread () | |
~CStunSocketThread () | |
HRESULT | Init (CStunSocket *arrayOfFourSockets, TransportAddressSet *pTSA, IStunAuth *pAuth, SocketRole rolePrimaryRecv, boost::shared_ptr< RateLimiter > &_spRateLimiter) |
HRESULT | Start () |
HRESULT | SignalForStop (bool fPostMessages) |
HRESULT | WaitForStopAndClose () |
Private Member Functions | |
void | Run () |
CStunSocket * | WaitForSocketData () |
HRESULT | InitThreadBuffers () |
void | UninitThreadBuffers () |
HRESULT | ProcessRequestAndSendResponse () |
void | ClearSocketArray () |
Static Private Member Functions | |
static void * | ThreadFunction (void *pThis) |
Private Attributes | |
CStunSocket * | _arrSendSockets |
std::vector< CStunSocket * > | _socks |
bool | _fNeedToExit |
pthread_t | _pthread |
bool | _fThreadIsValid |
int | _rotation |
TransportAddressSet | _tsa |
CRefCountedPtr< IStunAuth > | _spAuth |
CStunMessageReader | _reader |
CRefCountedBuffer | _spBufferReader |
CRefCountedBuffer | _spBufferIn |
CRefCountedBuffer | _spBufferOut |
StunMessageIn | _msgIn |
StunMessageOut | _msgOut |
boost::shared_ptr< RateLimiter > | _spLimiter |
Definition at line 29 of file stunsocketthread.h.
CStunSocketThread::CStunSocketThread | ( | ) |
Definition at line 27 of file stunsocketthread.cpp.
CStunSocketThread::~CStunSocketThread | ( | ) |
Definition at line 38 of file stunsocketthread.cpp.
|
private |
Definition at line 44 of file stunsocketthread.cpp.
HRESULT CStunSocketThread::Init | ( | CStunSocket * | arrayOfFourSockets, |
TransportAddressSet * | pTSA, | ||
IStunAuth * | pAuth, | ||
SocketRole | rolePrimaryRecv, | ||
boost::shared_ptr< RateLimiter > & | _spRateLimiter | ||
) |
Definition at line 50 of file stunsocketthread.cpp.
|
private |
Definition at line 105 of file stunsocketthread.cpp.
|
private |
Definition at line 377 of file stunsocketthread.cpp.
|
private |
Definition at line 275 of file stunsocketthread.cpp.
HRESULT CStunSocketThread::SignalForStop | ( | bool | fPostMessages | ) |
Definition at line 157 of file stunsocketthread.cpp.
HRESULT CStunSocketThread::Start | ( | ) |
Definition at line 136 of file stunsocketthread.cpp.
|
staticprivate |
Definition at line 217 of file stunsocketthread.cpp.
|
private |
Definition at line 124 of file stunsocketthread.cpp.
|
private |
Definition at line 224 of file stunsocketthread.cpp.
HRESULT CStunSocketThread::WaitForStopAndClose | ( | ) |
Definition at line 196 of file stunsocketthread.cpp.
|
private |
Definition at line 53 of file stunsocketthread.h.
|
private |
Definition at line 56 of file stunsocketthread.h.
|
private |
Definition at line 58 of file stunsocketthread.h.
|
private |
Definition at line 71 of file stunsocketthread.h.
|
private |
Definition at line 72 of file stunsocketthread.h.
|
private |
Definition at line 57 of file stunsocketthread.h.
|
private |
Definition at line 67 of file stunsocketthread.h.
|
private |
Definition at line 60 of file stunsocketthread.h.
|
private |
Definition at line 54 of file stunsocketthread.h.
|
private |
Definition at line 64 of file stunsocketthread.h.
|
private |
Definition at line 69 of file stunsocketthread.h.
|
private |
Definition at line 70 of file stunsocketthread.h.
|
private |
Definition at line 68 of file stunsocketthread.h.
|
private |
Definition at line 74 of file stunsocketthread.h.
|
private |
Definition at line 62 of file stunsocketthread.h.