[OpenSIPS-Users] udp or tcp for nat traversal?

Bogdan-Andrei Iancu bogdan at opensips.org
Wed Oct 15 09:13:00 CEST 2014


Hi George,

If your OpenSIPS fails to reach the UAC is because of two reasons:
     - NAT pinhole is closed - but if pinging is done, it shouldn't be
     - opensips is trying to contact UAC via wrong IP:port - can you 
confirm that when calling the UAC, OpenSIPS sends the INVITE to same IP 
and port as where the pingings are coming from ?

TCP works as this part is "automatically" resolved because of the 
connection (where the other pipe is known).

Regards,

Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com

On 15.10.2014 03:24, george wu wrote:
>
> Hi, Bogdan-Andrei:
>
> For udp, it fails when reaching the UAC even though the UAC keeps 
> pinging the server all the time.
>
> For tcp, although it works. I find something interesting.
> Only when the client pings the server, the invite message is sent to 
> the UAC.
> In my understanding, the server should be able to send message to the 
> UAC since the
> tcp connection is open. Actually the sip server is unable to send 
> message to the UAC.
>
> About the firewall type, I use opensipsctl ul show/rm to check.
> I find every time when it register, i get the same ip/portmost of time.
> But occasionally it might get different ip/port.
> I believe it is nat within a cone.
>
> I am using ice, the ice only work after the first invite message is 
> delivered to the peer.
> My ice with mediaproxy works perfectly.
>
>
> George Wu
>
> At 2014-10-15 00:22:46, "Bogdan-Andrei Iancu" <bogdan at opensips.org> wrote:
>
>     Hi George,
>
>     NAT traversal is not only about pinging, but also about
>     mangling/correcting the SIP traffic (from private IPs perspective)
>     and ensuring the RTP flow.
>
>     So you need to be sure that all 3 points are addressed.
>
>     TCP versus UDP - there is only a difference at IP transport
>     level...like datagram versus connection, and their implications at
>     NAT level (being able to reach the device behind the nat).
>     Otherwise it;s the same.
>
>     For UDP, can you see what fails ? the registration? reaching the
>     UAC ?
>
>     Regards,
>
>     Bogdan-Andrei Iancu
>     OpenSIPS Founder and Developer
>     http://www.opensips-solutions.com
>
>     On 14.10.2014 18:37, george wu wrote:
>>     My experience is for two uac (linphone) behind a firewall,
>>     tcp/tls will always work.
>>     udp will never work.
>>
>>     for both tcp/udp, my uac will send keep alive every 10 seconds.
>>     I don't understand what makes those difference.
>>     Can any one  share your experience?
>>
>>     George Wu
>>
>>
>>
>>
>>
>>
>>     _______________________________________________
>>     Users mailing list
>>     Users at lists.opensips.org
>>     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20141015/c9d4ea4a/attachment.htm>


More information about the Users mailing list