[SR-Users] fix_nated_contact NAT rtpproxy problems

Vik Killa vipkilla at gmail.com
Thu Jun 25 22:54:39 CEST 2015


Hello,
We are trying to get Kamailio working as an SBC using rtpproxy();
The config seems to work except with some carriers, kamailio does not
recognize the ACK because it does not match the contact header of the OK

I've been trying to figure out how to get kamailio to send the OK back
using the public IP address but I cannot figure out how.
I've tried using various deployments of the nathelper module such as
fix_nated_contact()
set_contact_alias()

No matter what though, Kamailio will not change the contact header it
receives from FS before sending it back to the carriers.

This has become frustrating as I read tutorials that showed this is
possible, yet I am unable.
Thank you.
/V
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20150625/b27093c4/attachment.html>
-------------- next part --------------

U 2015/06/25 15:40:09.095946 99.12.125.162:5060 -> 2.43.7.157:5060

INVITE sip:500 at 3.local SIP/2.0.
CSeq: 1 INVITE.
Via: SIP/2.0/UDP 192.168.16.120:5060;branch=z9hG4bKb0421938-f90f-1910-9836-8851fb4369e9;rport.
User-Agent: Ekiga/4.0.2.
From: "TEST" <sip:1000 at 3.local>;tag=643e1938-f90f-1910-9834-8851fb4369e9.
Call-ID: 643e1938-f90f-1910-9835-8851fb4369e9 at EV.
Supported: 100rel,replaces.
To: <sip:500 at 3.local>.
Contact: "TEST" <sip:ekiga at 192.168.16.120>.
Allow: INVITE,ACK,OPTIONS,BYE,CANCEL,SUBSCRIBE,NOTIFY,REFER,MESSAGE,INFO,PING,PRACK.
Content-Length: 256.
Content-Type: application/sdp.
Max-Forwards: 70.
.
v=0.
o=- 1435261202 1 IN IP4 192.168.16.120.
s=Ekiga/4.0.2.
c=IN IP4 192.168.16.120.
t=0 0.
m=audio 5082 RTP/AVP 0 8 101.
a=sendrecv.
a=rtpmap:0 PCMU/8000/1.
a=rtpmap:8 PCMA/8000/1.
a=rtpmap:101 telephone-event/8000.
a=fmtp:101 0-16,32,36.
a=maxptime:240.


U 2015/06/25 15:40:09.098884 2.43.7.157:5060 -> 99.12.125.162:5060

SIP/2.0 100 trying -- your call is important to us.
CSeq: 1 INVITE.
Via: SIP/2.0/UDP 192.168.16.120:5060;branch=z9hG4bKb0421938-f90f-1910-9836-8851fb4369e9;rport=5060;received=99.12.125.162.
From: "TEST" <sip:1000 at 3.local>;tag=643e1938-f90f-1910-9834-8851fb4369e9.
Call-ID: 643e1938-f90f-1910-9835-8851fb4369e9 at EV.
To: <sip:500 at 3.local>.
Server: kamailio (4.4.0-dev1 (x86_64/linux)).
Content-Length: 0.
.


U 2015/06/25 15:40:09.115025 2.43.7.157:5060 -> 99.12.125.162:5060

SIP/2.0 200 OK.
Via: SIP/2.0/UDP 192.168.16.120:5060;received=99.12.125.162;branch=z9hG4bKb0421938-f90f-1910-9836-8851fb4369e9;rport=5060.
Record-Route: <sip:2.43.7.157;lr;ftag=643e1938-f90f-1910-9834-8851fb4369e9;nat=yes>.
From: "TEST" <sip:1000 at 3.local>;tag=643e1938-f90f-1910-9834-8851fb4369e9.
To: <sip:500 at 3.local>;tag=5cF0vyUt2KQSH.
Call-ID: 643e1938-f90f-1910-9835-8851fb4369e9 at EV.
CSeq: 1 INVITE.
Contact: <sip:500 at 192.168.0.11:5060;transport=udp>.
User-Agent: FreeSWITCH-mod_sofia/1.7.0+git~20150611T050046Z~67ed8f4260~64bit.
Accept: application/sdp.
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY, PUBLISH, SUBSCRIBE.
Supported: timer, path, replaces.
Allow-Events: talk, hold, conference, presence, as-feature-event, dialog, line-seize, call-info, sla, include-session-description, presence.winfo, message-summary, refer.
Content-Type: application/sdp.
Content-Disposition: session.
Content-Length: 240.
Remote-Party-ID: "500" <sip:500 at 3.local>;party=calling;privacy=off;screen=no.
.
v=0.
o=FreeSWITCH 1435241875 1435241876 IN IP4 2.43.7.157.
s=FreeSWITCH.
c=IN IP4 2.43.7.157.
t=0 0.
m=audio 35522 RTP/AVP 0 101.
a=rtpmap:0 PCMU/8000.
a=rtpmap:101 telephone-event/8000.
a=fmtp:101 0-16.
a=ptime:20.
a=nortpproxy:yes.


U 2015/06/25 15:40:09.125027 99.12.125.162:5060 -> 2.43.7.157:5060

ACK sip:500 at 192.168.0.11:5060;transport=udp SIP/2.0.
Route: <sip:2.43.7.157;lr;nat=yes;ftag=643e1938-f90f-1910-9834-8851fb4369e9>.
CSeq: 1 ACK.
Via: SIP/2.0/UDP 192.168.16.120:5060;branch=z9hG4bK304f1938-f90f-1910-9836-8851fb4369e9;rport.
From: "TEST" <sip:1000 at 3.local>;tag=643e1938-f90f-1910-9834-8851fb4369e9.
Call-ID: 643e1938-f90f-1910-9835-8851fb4369e9 at EV.
To: <sip:500 at 3.local>;tag=5cF0vyUt2KQSH.
Contact: "TEST" <sip:ekiga at 192.168.16.120>.
Content-Length: 0.
Max-Forwards: 70.
.


More information about the sr-users mailing list