<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2873" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff background="">
<DIV><FONT face=Arial size=2>Hello, </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>i am using rtpproxy with openser to act as a RTP 
bridge to IP-SS7 gateway.&nbsp;IP-SS7 GW should not be exposed to external 
clients directly.&nbsp;</FONT></DIV>
<DIV><FONT face=Arial size=2>Architecture diagram is like this:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face="Courier New" size=2>|UA1|--SIP/RTP---|</FONT></DIV>
<DIV><FONT face="Courier New" size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
&nbsp;&nbsp; |------------------|&nbsp;&nbsp;&nbsp; </FONT><FONT 
face="Courier New" size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
|-----------|&nbsp; </FONT></DIV>
<DIV><FONT face="Courier New" size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
&nbsp;&nbsp; | OpenSer+RTPProxy |&nbsp;--SIP/RTP-- | IP-SS7-GW | </FONT></DIV>
<DIV><FONT face="Courier New" 
size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|------------------|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|-----------|</FONT></DIV>
<DIV><FONT face="Courier New" size=2>|UA2|--SIP/RTP---|</FONT></DIV>
<DIV><FONT face="Courier New" size=2></FONT>&nbsp;</DIV>
<DIV><FONT face="Courier New" size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Problem is when i try to send fax RTP packets 
destined for UA2 from IP-SS7 GW&nbsp;are sent directly. </FONT></DIV>
<DIV><FONT face=Arial size=2>They should go through RTPProxy, otherwise media 
ports does not &nbsp;match.</FONT></DIV>
<DIV><FONT face=Arial size=2>onreply route&nbsp;looks like:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>onreply_route[1] {<BR>&nbsp;&nbsp;&nbsp; if 
(isflagset(6) &amp;&amp; status =~ "(183)|2[0-9][0-9]") 
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
fix_nated_contact();<BR>&nbsp;&nbsp;&nbsp; }</FONT></DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; 
force_rtp_proxy();<BR>}<BR></FONT></DIV>
<DIV><FONT face=Arial size=2>each request is record_route()'ed before it is sent 
to be routed back through proxy.</FONT></DIV>
<DIV><FONT face=Arial size=2>I noticed that OpenSer removes top most via header 
in 200 OK&nbsp;&nbsp;messages:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>200 OK message for re-Invite received by 
OpenSer:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; SIP/2.0 200 
OK\r\n<BR>&nbsp;&nbsp;&nbsp; From: 
&lt;sip:870000049@sp2.ntt.lt&gt;;tag=4fbb0552\r\n<BR>&nbsp;&nbsp;&nbsp; To: 
&lt;sip:70000050@sp2.ntt.lt&gt;;tag=0-13c4-444c9fc6-f4eac-fdd\r\n<BR>&nbsp;&nbsp;&nbsp; 
Call-ID: </FONT><A 
href="mailto:cc36b0-0-13c4-444c9fc6-f4eac-2c87@sp2.ntt.lt\r\n"><FONT face=Arial 
size=2>cc36b0-0-13c4-444c9fc6-f4eac-2c87@sp2.ntt.lt\r\n</FONT></A><BR><FONT 
face=Arial size=2>&nbsp;&nbsp;&nbsp; CSeq: 666497904 
INVITE\r\n<BR>&nbsp;&nbsp;&nbsp; Via: SIP/2.0/UDP 
84.32.0.18;branch=z9hG4bKf67f.2aeace41.0\r\n<BR>&nbsp;&nbsp;&nbsp; Via: 
SIP/2.0/UDP 
84.32.0.7:5060;branch=z9hG4bK444cbbfca6214604dc9\r\n<BR>&nbsp;&nbsp;&nbsp; 
Supported: 100rel\r\n<BR>&nbsp;&nbsp;&nbsp; User-Agent: 
SIP-RG\r\n<BR>&nbsp;&nbsp;&nbsp; Contact: 
&lt;sip:70000050@84.32.134.143&gt;\r\n<BR>&nbsp;&nbsp;&nbsp; Content-Type: 
application/sdp\r\n<BR>&nbsp;&nbsp;&nbsp; Content-Length: 
317\r\n<BR>&nbsp;&nbsp;&nbsp; \r\n<BR>&nbsp;&nbsp;&nbsp; 
v=0\r\n<BR>&nbsp;&nbsp;&nbsp; o=SIP-N-TA 0 0 IN IP4 
84.32.134.143\r\n<BR>&nbsp;&nbsp;&nbsp; s=5420868F 0000 5420868F 0000 01 
0\r\n<BR>&nbsp;&nbsp;&nbsp; c=IN IP4 84.32.134.143\r\n<BR>&nbsp;&nbsp;&nbsp; t=0 
0\r\n<BR>&nbsp;&nbsp;&nbsp; m=image 4008 udptl t38\r\n<BR>&nbsp;&nbsp;&nbsp; 
c=IN IP4 84.32.134.143\r\n<BR>&nbsp;&nbsp;&nbsp; 
a=T38FaxVersion:0\r\n<BR>&nbsp;&nbsp;&nbsp; 
a=T38MaxBitRate:14400\r\n<BR>&nbsp;&nbsp;&nbsp; 
a=T38FaxFillBitRemoval:0\r\n<BR>&nbsp;&nbsp;&nbsp; 
a=T38FaxTranscodingMMR:0\r\n<BR>&nbsp;&nbsp;&nbsp; 
a=T38FaxTranscodingJBIG:0\r\n<BR>&nbsp;&nbsp;&nbsp; 
a=T38FaxRateManagement:transferredTCF\r\n</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>200 OK message sent to IP-SS7 GW by 
OpenSer:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>SIP/2.0 200 OK</FONT></DIV>
<DIV><FONT face=Arial size=2>From: 
&lt;sip:870000049@sp2.ntt.lt&gt;;tag=4fbb0552</FONT></DIV>
<DIV><FONT face=Arial size=2>To: 
&lt;sip:70000050@sp2.ntt.lt&gt;;tag=0-13c4-444c9fc6-f4eac-fdd</FONT></DIV>
<DIV><FONT face=Arial size=2>Call-ID: </FONT><A 
href="mailto:cc36b0-0-13c4-444c9fc6-f4eac-2c87@sp2.ntt.lt"><FONT face=Arial 
size=2>cc36b0-0-13c4-444c9fc6-f4eac-2c87@sp2.ntt.lt</FONT></A></DIV>
<DIV><FONT face=Arial size=2>CSeq: 666497904 INVITE</FONT></DIV>
<DIV><FONT face=Arial size=2>Via: SIP/2.0/UDP 
84.32.0.7:5060;branch=z9hG4bK444cbbfca6214604dc9</FONT></DIV>
<DIV><FONT face=Arial size=2>Supported: 100rel</FONT></DIV>
<DIV><FONT face=Arial size=2>User-Agent: SIP-RG</FONT></DIV>
<DIV><FONT face=Arial size=2>Contact: 
&lt;sip:70000050@84.32.134.143&gt;</FONT></DIV>
<DIV><FONT face=Arial size=2>Content-Type: application/sdp</FONT></DIV>
<DIV><FONT face=Arial size=2>Content-Length: 333</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>v=0</FONT></DIV>
<DIV><FONT face=Arial size=2>o=SIP-N-TA 0 0 IN IP4 84.32.134.143</FONT></DIV>
<DIV><FONT face=Arial size=2>s=5420868F 0000 5420868F 0000 01 0</FONT></DIV>
<DIV><FONT face=Arial size=2>c=IN IP4 84.32.134.143</FONT></DIV>
<DIV><FONT face=Arial size=2>t=0 0</FONT></DIV>
<DIV><FONT face=Arial size=2>m=image 39246 udptl t38</FONT></DIV>
<DIV><FONT face=Arial size=2>c=IN IP4 84.32.0.18</FONT></DIV>
<DIV><FONT face=Arial size=2>a=T38FaxVersion:0</FONT></DIV>
<DIV><FONT face=Arial size=2>a=T38MaxBitRate:14400</FONT></DIV>
<DIV><FONT face=Arial size=2>a=T38FaxFillBitRemoval:0</FONT></DIV>
<DIV><FONT face=Arial size=2>a=T38FaxTranscodingMMR:0</FONT></DIV>
<DIV><FONT face=Arial size=2>a=T38FaxTranscodingJBIG:0</FONT></DIV>
<DIV><FONT face=Arial size=2>a=T38FaxRateManagement:transferredTCF</FONT></DIV>
<DIV><FONT face=Arial size=2>a=nortpproxy:yes</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>In this message there is no indication that is came 
from SIP&nbsp;proxy (no record-route, no via header), then IP-SS7 GW sends ACK 
message directly.</FONT></DIV>
<DIV><FONT face=Arial size=2>This, i suppose, is normal thing, is it? Problem is 
that </FONT><FONT face=Arial size=2>IP-SS7 also sends RTP traffic to UA2 
directly. This probably happens because of two 'c=' fields in SDP.</FONT></DIV>
<DIV><FONT face=Arial size=2>OpenSer changes only one in&nbsp; media part. 
</FONT><FONT face=Arial size=2>Is there a way to change 'c=' field in SDP not 
only on media part? </FONT></DIV>
<DIV><FONT face=Arial size=2>Which should take precedence if both can't be 
changed?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>regards, </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Antanas Masevicius</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV></BODY></HTML>