[OpenSIPS-Users] OpenSIPs mhomed + rtpproxy + nated UAC = problem with SDP

OCEANET - Cédric BASSAGET cedric at oceanet.com
Fri Apr 5 09:05:30 CEST 2013


Hi Ovidiu,

It does not change anything, I've already tried.

Here's the routing scenario the call goes through (simplified) :

route[uac_nat]
{
     if (is_method("INVITE") && has_body("application/sdp"))
     {
                 force_rport();
                 if(engage_rtp_proxy("feir"))
                 {
                         t_on_reply("uac_nat");
                 }
     }
}

onreply_route[uac_nat]
{
                 xlog("onreply_route, call initiator seems to be behind 
nat");
                 rtpproxy_answer("fier");
}

usrloc looks good :
Contact:: 
<sip:1000 at 10.7.59.1:1029>;q=;expires=150;flags=0x0;cflags=0x300;socket=<udp:10.7.59.2:5060>;methods=0xFFFFFFFF;*received=<sip:10.7.59.1:1028*>;user_agent=<Oceanet-test>

Cédric
Le 04/04/2013 18:32, Ovidiu Sas a écrit :
> You need to use "ie" on offer and "ei" on answer on one call direction.
> For the opposite call direction, use "ei" on offer an "ie" on answer.
>
> Regards,
> Ovidiu Sas
>
> On Thu, Apr 4, 2013 at 12:24 PM, OCEANET - Cédric BASSAGET
> <cedric at oceanet.com> wrote:
>> Hello,
>>
>> For my first post on this mailing list, I'm trying to make opensips working
>> in this scheme (that's a lab test, so don't take care of my "public" ip
>> addresses) :
>>
>> UAC (asterisk) <---------------------> routeur(nat) <------------------>
>> opensips (mhomed) <----------> sip privoder
>> 10.10.1.1                               10.10.1.254 / 10.7.59.1
>> 10.7.59.2 / 10.0.95.10                  10.0.95.1
>>
>> mhomed is set to 1
>> I have a rtpproxy set in bridge mode on my opensips, like this :
>> /usr/local/bin/rtpproxy -p /var/run/rtpproxy.pid -u rtpproxy -d DBUG
>> LOG_LOCAL5 -m 10000 -M 20000 -l 10.0.95.10 10.7.59.2 -s udp:127.0.0.1 9999
>>
>> I'm trying to establish a call from my asterisk to a public phone number,
>> but I have a problem with SDP reply (200 OK) , from my opensips to my UAC.
>> SDP c= value is still 10.0.95.10, instead of 10.7.59.2. That's the only
>> thing that is not correct in the SIP session. I can't find why c= value is
>> not correct in the 200 OK.
>>
>> I use engage_rtp_proxy("fr"), but I tried with many combinations
>> (rtpproxy_offer / answer, params=fier, params=feir).
>>
>> If somebody has already been in this situation, I would appreciate his help.
>> Thanks for your replies, please tell me if you need more captures or
>> anything else
>>
>> Here's a short description of SIP requests, seen from OpenSIPS :
>>
>>
>> ##### INVITE FROM MY UAC TO OPENSIPS ###############
>> U 2013/04/04 18:18:09.621724 10.7.59.1:1028 -> 10.7.59.2:5060
>> INVITE sip:0604596002 at 10.7.59.2 SIP/2.0
>> Via: SIP/2.0/UDP 10.7.59.1:1029;branch=z9hG4bK13253a27;rport
>> Max-Forwards: 70
>> From: "100" <sip:0970559990 at 10.7.59.1:1029>;tag=as747d5e5b
>> To: <sip:0604596002 at 10.7.59.2>
>> Contact: <sip:0970559990 at 10.7.59.1:1029>
>> Call-ID: 211f651b7793be045c9c25880e1df4ac at 10.10.1.1:5060
>> CSeq: 102 INVITE
>> User-Agent: Oceanet-test
>> Date: Thu, 04 Apr 2013 16:12:34 GMT
>> Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO,
>> PUBLISH
>> Supported: replaces
>> Content-Type: application/sdp
>> Content-Length: 282
>>
>> v=0
>> o=root 1416933599 1416933599 IN IP4 10.10.1.1
>> s=Asterisk PBX 1.8.20.1
>> c=IN IP4 10.7.59.1
>> t=0 0
>> m=audio 17282 RTP/AVP 9 0 101
>> a=rtpmap:9 G722/8000
>> a=rtpmap:0 PCMU/8000
>> a=rtpmap:101 telephone-event/8000
>> a=fmtp:101 0-16
>> a=silenceSupp:off - - - -
>> a=ptime:20
>> a=sendrecv
>>
>> #####INVITE FROM OPENSIPS TO PROVIDER ###############
>> U 2013/04/04 18:18:09.622378 10.0.95.10:5060 -> 10.0.95.1:5060
>> INVITE sip:0604596002 at 10.0.95.1 SIP/2.0
>> Via: SIP/2.0/UDP 10.0.95.10;branch=z9hG4bKbd97.ced0f0b2.0
>> Max-Forwards: 69
>> From: "100" <sip:0970559990 at 10.7.59.1:1029>;tag=as747d5e5b
>> To: <sip:0604596002 at 10.7.59.2>
>> Contact: <sip:10.0.95.10;did=b0b.7e82f333>
>> Call-ID: 211f651b7793be045c9c25880e1df4ac at 10.10.1.1:5060
>> CSeq: 102 INVITE
>> User-Agent: Oceanet-test
>> Date: Thu, 04 Apr 2013 16:12:34 GMT
>> Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO,
>> PUBLISH
>> Supported: replaces
>> Content-Type: application/sdp
>> Content-Length: 283
>>
>> v=0
>> o=root 1416933599 1416933599 IN IP4 10.10.1.1
>> s=Asterisk PBX 1.8.20.1
>> c=IN IP4 10.0.95.10
>> t=0 0
>> m=audio 19392 RTP/AVP 9 0 101
>> a=rtpmap:9 G722/8000
>> a=rtpmap:0 PCMU/8000
>> a=rtpmap:101 telephone-event/8000
>> a=fmtp:101 0-16
>> a=silenceSupp:off - - - -
>> a=ptime:20
>> a=sendrecv
>>
>> ##### REPLY FROM PROVIDER TO OPENSIPS ###############
>> U 2013/04/04 18:18:16.327567 10.0.95.1:5060 -> 10.0.95.10:5060
>> SIP/2.0 200 OK
>> Via: SIP/2.0/UDP 10.0.95.10;branch=z9hG4bKbd97.ced0f0b2.0
>> Call-ID: 211f651b7793be045c9c25880e1df4ac at 10.10.1.1:5060
>> From: "100" <sip:0970559990 at 10.7.59.1:1029>;tag=as747d5e5b
>> To: <sip:0604596002 at 10.7.59.2>;tag=a94c095b773be1dd6e8d668a785a9c84530b7132
>> Contact: <sip:10.0.95.1;did=b0b.c3c431b5>
>> CSeq: 102 INVITE
>> Server: Dialogic-SIP/10.5.3.360 ACKBAR 0
>> Allow: INVITE, BYE, REGISTER, ACK, OPTIONS, CANCEL, SUBSCRIBE, NOTIFY, INFO,
>> REFER, UPDATE
>> Supported: path, replaces, timer, tdialog
>> Accept: application/sdp, application/dtmf-relay, text/plain
>> Content-Type: application/sdp
>> Content-Length: 238
>>
>> v=0
>> o=Dialogic_SDP 2521466 0 IN IP4 91.213.145.116
>> s=Dialogic-SIP
>> c=IN IP4 10.0.95.3
>> t=0 0
>> m=audio 10018 RTP/AVP 0 101
>> a=rtpmap:0 PCMU/8000
>> a=rtpmap:101 telephone-event/8000
>> a=fmtp:101 0-15
>> a=silenceSupp:off - - - -
>> a=ptime:20
>>
>> #### REPLY FROM OPENSIPS TO UAC WITH WRONG SDP ################
>> U 2013/04/04 18:18:16.328296 10.7.59.2:5060 -> 10.7.59.1:1028
>> SIP/2.0 200 OK
>> Via: SIP/2.0/UDP 10.7.59.1:1029;branch=z9hG4bK13253a27;rport
>> Call-ID: 211f651b7793be045c9c25880e1df4ac at 10.10.1.1:5060
>> From: "100" <sip:0970559990 at 10.7.59.1:1029>;tag=as747d5e5b
>> To: <sip:0604596002 at 10.7.59.2>;tag=a94c095b773be1dd6e8d668a785a9c84530b7132
>> Contact: <sip:10.7.59.2;did=b0b.7e82f333>
>> CSeq: 102 INVITE
>> Server: Dialogic-SIP/10.5.3.360 ACKBAR 0
>> Allow: INVITE, BYE, REGISTER, ACK, OPTIONS, CANCEL, SUBSCRIBE, NOTIFY, INFO,
>> REFER, UPDATE
>> Supported: path, replaces, timer, tdialog
>> Accept: application/sdp, application/dtmf-relay, text/plain
>> Content-Type: application/sdp
>> Content-Length: 239
>>
>> v=0
>> o=Dialogic_SDP 2521466 0 IN IP4 91.213.145.116
>> s=Dialogic-SIP
>> c=IN IP4 10.0.95.10
>> t=0 0
>> m=audio 11526 RTP/AVP 0 101
>> a=rtpmap:0 PCMU/8000
>> a=rtpmap:101 telephone-event/8000
>> a=fmtp:101 0-15
>> a=silenceSupp:off - - - -
>> a=ptime:20
>>
>>
>> Cédric
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>
>


-- 
OCEANET
---------------------------------------------------------------
[AGENCE DU MANS]
7, rue des Frênes
ZAC de la Pointe
72190 SARGE LES LE MANS
[t] +33 (0)2.43.50.26.50
[f] +33 (0)2.43.72.21.14

[AGENCE D'ANGERS]
5, rue Fleming
Angers Technopole
49066 ANGERS
[t] +33 (0)2.41.19.28.65
[f] +33 (0)2.52.19.22.00

http://www.oceanet.com
http://www.oceanet-telecom.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20130405/0ae7d367/attachment-0001.htm>


More information about the Users mailing list