I had forgotten to cc the list<br><br>---------- Forwarded message ----------<br><span class="gmail_quote">From: <b class="gmail_sendername">Arne Van Theemsche</b> <<a href="mailto:arnevt@gmail.com">arnevt@gmail.com</a>
><br>Date: 22-sep-2006 9:06<br>Subject: Re: [Users] mediaproxy working, but not if asterisk is involved<br>To: <a href="mailto:daniel@voice-system.ro">daniel@voice-system.ro</a><br><br></span>the problem is that I don't even see the "reply received"... So for some reason the asterisk reply isn't passed through to the onreply_route. My theory is that asterisk doesn't respect the reply parameters somewhere, but it isn't clear to me where
<br><br>arne<br><br><br><div><span class="gmail_quote">2006/9/22, Daniel-Constantin Mierla <<a href="mailto:daniel@voice-system.ro" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">daniel@voice-system.ro
</a>>:</span><div><span class="e" id="q_10dd4587c76cea89_1"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Do you get "using mediaproxy" message in the logs? If not, that the<br>search() matches, I cannot sot right now what is wrong with the<br>expression. But you can move t_on_reply("1") into if*method=="INVITE")
<br>statement and replace the search condition with if (status =~<br>"(183)|(2[0-9][0-9])").<br><br>See:<br><a href="http://voip-info.org/wiki/view/OpenSER+And+Mediaproxy" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://voip-info.org/wiki/view/OpenSER+And+Mediaproxy
</a><br><br>Cheers,<br>Daniel<br><br><br>On 09/21/06 21:46, Arne Van Theemsche wrote:<br>> below is the transaction of the failed mediaproxy invite. I allready<br>> could tell that replies go through openser, but I don't see the reason
<br>> why ser doesn't see them as replies (and use the mediaproxy function).<br>><br>> as you can see, the invite from <ip client> to <ip asterisk> (through<br>> <ip OPENSER>, which is also ip of mediaproxy) goes in one direction
<br>> good (the ip in the SDP is changed from <ip client> to <ip openser>,<br>> but the return path en the OK (with it's SDP) is not changed<br>><br>> I did a tcpdump with a call between 2 clients, where the proxy works,
<br>> and the only difference I see is that in the reply of asterisk, there<br>> is no rinstance field in the contact header<br>><br>> thanks<br>> arne<br>><br>> U <ip client>:5060 -> <ip OPENSER>:5060
<br>> INVITE sip:701@<sip domain>;transport=UDP SIP/2.0..From: "arne"<br>> <sip:1002@<sip domain>>;tag=514a90c3-13c4-7a70a-1de331c0-5e4f..To:<br>> "701"< sip:701@sipgat
<br>
> <a href="http://e.evonet.be" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">e.evonet.be</a> <<a href="http://e.evonet.be" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://e.evonet.be</a>>>..Call-ID:<br>> 1064dc44-514a90c3-13c4-7a70a-1de331be-529@<ip<br>> <mailto:<a href="mailto:1064dc44-514a90c3-13c4-7a70a-1de331be-529@" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
1064dc44-514a90c3-13c4-7a70a-1de331be-529@</a>%3Cip><br>> client>..CSeq: 1 INVITE..Via: SIP/2.0/UDP <ip<br>> client>:5060;rport;branch=z9hG4bK-7a70a-1d<br>> e331c2-69dc..Max-Forwards: 70..Supported:
<br>> replaces,100rel,timer..Allow: INVITE, ACK, BYE, REFER, NOTIFY, CANCEL,<br>> OPTIONS, INFO, PRACK..User-Agent: Swissvoice IP1<br>> 0 SP v1.0.1 (Build 3) 3.0.5.1..Allow-Events: talk, hold,<br>> conference..Contact: "arne" <sip:1002@<ip
<br>> client>:5060;transport=UDP>..Session-Expires: 1800..Content-<br>> Type: application/sdp..Content-Length: 246....v=0..o=rtp/1 501514<br>> 501514 IN IP4 <ip client>..s=-..c=IN IP4 <ip client>..t=0 0..m=audio
<br>> 50000 RTP/AVP 18 0 8..<br>> a=fmtp:18 annexb=yes..a=ptime:40..a=SilenceSupp:on..a=rtpmap:18<br>> g729/8000..a=rtpmap:0 pcmu/8000..a=rtpmap:8 pcma/8000..a=sendrecv..<br>> #<br>><br>> U <ip OPENSER>:5060 -> <ip asterisk>:5060
<br>> INVITE sip:701@<sip domain>;transport=UDP SIP/2.0..Record-Route:<br>> <sip:<ip OPENSER>;lr=on;ftag=514a90c3-13c4-7a70a-1de331c0-5e4f>..From:<br>> "arne" < sip:1002@si<br>>
<a href="http://pgate.evonet.be" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">pgate.evonet.be</a><br>> <<a href="http://pgate.evonet.be" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://pgate.evonet.be</a>>>;tag=514a90c3-13c4-7a70a-1de331c0-5e4f..To:<br>> "701"<sip:701@<sip domain>>..Call-ID:
<br>> 1064dc44-514a90c3-13c4-7a70a-1de331be-529@<ip<br>> <mailto:<a href="mailto:1064dc44-514a90c3-13c4-7a70a-1de331be-529@" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">1064dc44-514a90c3-13c4-7a70a-1de331be-529@
</a>%3Cip> client>..C<br>> Seq: 1 INVITE..Via: SIP/2.0/UDP <ip OPENSER>;branch=0..Via:
<br>> SIP/2.0/UDP <ip<br>> client>:5060;rport=5060;branch=z9hG4bK-7a70a-1de331c2-69dc..Max-Forwards:<br>> 69..Supp<br>> orted: replaces,100rel,timer..Allow: INVITE, ACK, BYE, REFER,<br>> NOTIFY, CANCEL, OPTIONS, INFO, PRACK..User-Agent: Swissvoice IP10 SP
<br>> v1.0.1 (Build 3) 3.0.5.1..Allo<br>> w-Events: talk, hold, conference..Contact: "arne" <sip:1002@<ip<br>> client>:5060;transport=UDP>..Session-Expires: 1800..Content-Type:<br>> application/sdp..Content-Leng
<br>> th: 246....v=0..o=rtp/1 501514 501514 IN IP4 <ip client>..s=-..c=IN<br>> IP4 <ip OPENSER>..t=0 0..m=audio 60106 RTP/AVP 18 0 8..a=fmtp:18<br>> annexb=yes..a=ptime:40..a<br>> =SilenceSupp:on..a=rtpmap:18 g729/8000..a=rtpmap:0
<br>> pcmu/8000..a=rtpmap:8 pcma/8000..a=sendrecv..<br>> #<br>><br>> U <ip asterisk>:5060 -> <ip OPENSER>:5060<br>> SIP/2.0 100 Trying..Via: SIP/2.0/UDP <ip<br>> OPENSER>;branch=0;received=<ip OPENSER>..Via: SIP/2.0/UDP <ip
<br>> client>:5060;rport=5060;branch=z9hG4bK-7a70a-1de331c2-<br>> 69dc..From: "arne" <sip:1002@<sip<br>> domain>>;tag=514a90c3-13c4-7a70a-1de331c0-5e4f..To: "701"<sip:701@<sip
<br>> domain>>..Call-ID: 1064dc44-514a90c3-13c4-7a70<br>> a-1de331be-529@<ip <mailto:<a href="mailto:a-1de331be-529@" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">a-1de331be-529@
</a>%3Cip> client>..CSeq: 1<br>> INVITE..User-Agent: Asterisk PBX..Allow: INVITE, ACK, CANCEL, OPTIONS,
<br>> BYE, REFER, SUBSCRIBE, NOTIFY..Contact: <sip:701@<br>> <ip asterisk>>..Content-Length: 0....<br>> #<br>><br>> U <ip OPENSER>:5060 -> <ip client>:5060<br>> SIP/2.0 100 Trying..Via: SIP/2.0/UDP <ip
<br>> client>:5060;rport=5060;branch=z9hG4bK-7a70a-1de331c2-69dc..From:<br>> "arne" <sip:1002@<sip domain>>;tag=514a90c3-13c<br>> 4-7a70a-1de331c0-5e4f..To: "701"<sip:701@<sip domain>>..Call-ID:
<br>> 1064dc44-514a90c3-13c4-7a70a-1de331be-529@<ip<br>> <mailto:<a href="mailto:1064dc44-514a90c3-13c4-7a70a-1de331be-529@" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">1064dc44-514a90c3-13c4-7a70a-1de331be-529@
</a>%3Cip><br>> client>..CSeq: 1 INVITE..User-Agent: Asteri
<br>> sk PBX..Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE,<br>> NOTIFY..Contact: <sip:701@<ip asterisk>>..Content-Length: 0....<br>> #<br>><br>> U <ip asterisk>:5060 -> <ip OPENSER>:5060
<br>> SIP/2.0 200 OK..Via: SIP/2.0/UDP <ip OPENSER>;branch=0;received=<ip<br>> OPENSER>..Via: SIP/2.0/UDP <ip<br>> client>:5060;rport=5060;branch=z9hG4bK-7a70a-1de331c2-69dc<br>> ..Record-Route: <sip:<ip
<br>> OPENSER>;lr=on;ftag=514a90c3-13c4-7a70a-1de331c0-5e4f>..From: "arne"<br>> <sip:1002@<sip domain>>;tag=514a90c3-13c4-7a70a-1de331c0-5e4f<br>> ..To: "701"<sip:701@<sip domain>>;tag=as60ebd3fc..Call-ID:
<br>> 1064dc44-514a90c3-13c4-7a70a-1de331be-529@<ip<br>> <mailto:<a href="mailto:1064dc44-514a90c3-13c4-7a70a-1de331be-529@" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">1064dc44-514a90c3-13c4-7a70a-1de331be-529@
</a>%3Cip><br>> client>..CSeq: 1 INVITE..User-Agent: Asterisk PBX
<br>> ..Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE,<br>> NOTIFY..Contact: <sip:701@<ip asterisk>>..Content-Type:<br>> application/sdp..Content-Length: 188....v=<br>> 0..o=root 26276 26276 IN IP4 <ip asterisk>..s=session..c=IN IP4 <ip
<br>> asterisk>..t=0 0..m=audio 13434 RTP/AVP 0 8..a=rtpmap:0<br>> PCMU/8000..a=rtpmap:8 PCMA/8000..a=<br>> silenceSupp:off - - - -..<br>> #<br>><br>> U <ip OPENSER>:5060 -> <ip client>:5060
<br>> SIP/2.0 200 OK..Via: SIP/2.0/UDP <ip<br>> client>:5060;rport=5060;branch=z9hG4bK-7a70a-1de331c2-69dc..Record-Route:<br>> <sip:<ip OPENSER>;lr=on;ftag=514a90c3-13c4-7a70<br>> a-1de331c0-5e4f>..From: "arne" <sip:1002@<sip
<br>> domain>>;tag=514a90c3-13c4-7a70a-1de331c0-5e4f..To: "701"<sip:701@<sip<br>> domain>>;tag=as60ebd3fc..Call-ID:<br>> 1064dc44-514a90c3-13c4-7a70a-1de331be-529@<ip<br>> <mailto:
<a href="mailto:1064dc44-514a90c3-13c4-7a70a-1de331be-529@" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">1064dc44-514a90c3-13c4-7a70a-1de331be-529@</a>%3Cip><br>> client>..CSeq: 1 INVITE..User-Agent: Asterisk PBX..Allow: INVITE, ACK,
<br>> CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NO
<br>> TIFY..Contact: <sip:701@<ip asterisk>>..Content-Type:<br>> application/sdp..Content-Length: 188....v=0..o=root 26276 26276 IN IP4<br>> <ip asterisk>..s=session..c=IN IP4<br>> <ip asterisk>..t=0 0..m=audio 13434 RTP/AVP 0 8..a=rtpmap:0
<br>> PCMU/8000..a=rtpmap:8 PCMA/8000..a=silenceSupp:off - - - -..<br>> #<br>><br>><br>><br>><br>><br>> 2006/9/21, Daniel-Constantin Mierla <<a href="mailto:daniel@voice-system.ro" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
daniel@voice-system.ro
</a><br>> <mailto:<a href="mailto:daniel@voice-system.ro" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">daniel@voice-system.ro</a>>>:<br>><br>> Hello,<br>><br>> watch the network traffic with ngrep on your sip server. You can
<br>> see the
<br>> call flow which may help to identify the issue. You can paste it<br>> to the<br>> list and someone may give you hints.<br>><br>> Cheers,<br>> Daniel<br>><br>><br>> On 09/21/06 12:28, Arne Van Theemsche wrote:
<br>> > hi<br>> ><br>> > my users subscribe with openser, en asterisk is used as connectivity<br>> > to pstn<br>> ><br>> > i am now installing a mediaproxy, for all users, so every call goes
<br>> > via a mediaproxy.<br>> ><br>> > I'm doing this as follows (relevant statements only)<br>> ><br>> > in route<br>> ><br>> > #I installed the t_on_reply here to be sure that every reply
<br>> > gets parsed, but normally in the INVITE section should be enough?<br>> > t_on_reply("1");<br>> ><br>> > if (method==INVITE) {<br>> > use_media_proxy();
<br>> > }<br>> ><br>> ><br>> > onreply_route[1] {<br>> > log(-3,"reply received");<br>> > if (!search("^Content-Length:[ ]*0")) {
<br>> > log(-3,"using mediaproxy");<br>> > use_media_proxy();<br>> > };<br>> > }<br>> ><br>> ><br>> > the weird is, for all local users, this works fine, but as soon as
<br>> > asterisk is involved, the reply doesn't get triggered (not<br>> seeing the<br>> > "reply received" either, only when disconnecting the call). The call<br>> > get's established fine, asterisk is sending media to the
<br>> mediaproxy,<br>> > but the SDP towards the calling phone is not modified (since the<br>> > onreply isn't triggered)<br>> ><br>> > am I missing something here?<br>> >
<br>> > thanks<br>> > Arne<br>> ><br>> ><br>> ------------------------------------------------------------------------<br>><br>> ><br>> > _______________________________________________
<br>> > Users mailing list<br>> > <a href="mailto:Users@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Users@openser.org</a> <mailto:<a href="mailto:Users@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
Users@openser.org</a>><br>> > <a href="http://openser.org/cgi-bin/mailman/listinfo/users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://openser.org/cgi-bin/mailman/listinfo/users</a><br>> ><br>><br>><br></blockquote></span></div></div><br>