Internet Communications Using SIP : Delivering VoIP and Multimedia Services With Session Initiation Protocol {2Nd Ed.}

(Steven Felgate) #1
Figure 10.1 Unsuccessful session setup through NAT

Of these three problems identified, only this first one has a solution in SIP. A
proxy or user agent (UA) receiving this request would compare the IP address
in the Viaheader to the IP address from which the packet was received. If the
two are different (as they would be if a NAT is present), the correct IP address
is added to the Viaheader with a received=parameter listing the actual IP
address. This IP address would be used to route the response successfully back
to user A, provided the NAT maintains the same binding between the private
IP address and public IP address. (This is not a problem if TCP is used as the
transport. When a TCP connection is opened, the NAT creates the binding
between the private IP address and port number and the assigned public IP
address and port number. When the connection closes, the NAT removes the
binding.) However, no easy solution exists for the other two problems.
The second problem could be solved by a persistent TCP connection for the
duration of the session. This would mean that the Contactheader would
never be used to route future requests (such as a re-INVITEor BYE), since
there would always be an open TCP connection.
A possible solution to the third problem has been proposed [5] that involves
making RTP flows symmetric. For the case where only one endpoint is behind
a NAT, RTP packet flow will be possible in at least one direction. This is so
because the SDP of the endpoint outside the NAT will contain a correct glob-
ally routable IP address and port number. The use of symmetric RTP would

SIP User Agent A NAT Network A


  1. RTP Packets to 100.101.102.103

  2. INVITE
    Via: 10.1.2.3
    Contact: [email protected]
    SDP 10.1.2.3

  3. ACK


SIP can negotiate
NAT but SDP A
contains private IP
address – RTP fails.
Requests sent by B
to A’s Contact URI
Solution isSTUN and also fail.

TURN
protocols!

UCP
Scenario

(TCP also
works)

SIP User Agent B


  1. 180 Ringing
    Via: 10.1.2.3; received= 1.2.3.4
    Contact: [email protected]

  2. RTP Packets to 10.1.2.3 ??
    7. BYE [email protected] ??

  3. 200 OK
    Via: 10.1.2.3; received= 1.2.3.4
    Contact: [email protected]
    SDP 100.101.102.103c


176 Chapter 10

Free download pdf