Table of Contents
List of Examples
A stun server working with the same port as SIP (5060) in order to gain accurate information. The benefit would be an exact external address in the case of NATs translating differently when given different destination ports.
The stun server will use 4 sockets: socket1 = ip1 : port1 socket2 = ip1 : port2 socket3 = ip2 : port1 socket4 = ip2 : port2
The sockets come from existing SIP sockets or are created.
socket1 will allways be the the SIP socket.
The server will create a separate process. This process will listen for data on created sockets. The server will register a callback function to SIP. This function is called when a specific (stun)header is found.
This stun implements rfc 3489 (and XOR_MAPPED_ADDRESS from rfc 5389)
MAPPED_ADDRESS, RESPONSE_ADDRESS, CHANGE_REQUEST, SOURCE_ADDRESS, CHANGED_ADDRESS, ERROR_CODE, UNKNOWN_ATTRIBUTES, REFLECTED_FROM, XOR_MAPPED_ADDRESS
Not supported attributes:
USERNAME, PASSWORD, MESSAGE_INTEGRITY, and associated ERROR_CODEs
The ip of the interface SIP is working on.
The port SIP is working on.
Another ip from another interface.