<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">Ciao Michele,<br>
per uscire con il contact corretto devi usare l'advertised_address
/ advertised_port se il serves ha solo un IP interno.<br>
Questo fa nascere vari problemi perché la correzione viene fatta
anche per verso i client interni.<br>
Non c'è il concetto di Lan come per asterisk, almeno finora.<br>
Nelle ultime versioni ho visto dei parametri in più quindi le cose
potrebbero essere migliorate.<br>
<br>
La miglior configurazione nel tuo caso sarebbe un server dual
homed con IP interno ed esterno.<br>
<br>
Ciao<br>
s<br>
<br>
<br>
<br>
<br>
<br>
Il 03/11/2015 10:43, Michele Pinassi ha scritto:<br>
</div>
<blockquote cite="mid:563881C4.1090807@unisi.it" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=windows-1252">
Hi all,<br>
<br>
i'm trying to setup enum (NRENUM) infrastructure for our
university. We have a public IP voip server, VOIP01, with a
private network for voip phones (172.20.x.x). To let RTP flow
through the private and public network, i set up a RTP Proxy:<br>
<br>
<i>onreply_route[enum_answer] {</i><i><br>
</i><i> if(has_body("application/sdp")) {</i><i><br>
</i><i> rtpproxy_answer();</i><i><br>
</i><i> }</i><i><br>
</i><i>}</i><i><br>
</i><i><br>
</i><i>onreply_route[enum_offer] {</i><i><br>
</i><i> if(has_body("application/sdp")) {</i><i><br>
</i><i> rtpproxy_offer();</i><i><br>
</i><i> }</i><i><br>
</i><i>}</i><i><br>
</i><i><br>
</i><i>route[enum] {</i><i><br>
</i><i> xlog("L_INFO","Route to ENUM
[$fd/$fu/$rd/$ru/$si/]\n");</i><i><br>
</i><i> </i><i><br>
</i><i> if (is_method("INVITE")) {</i><i><br>
</i><i> if(has_body("application/sdp")) {</i><i><br>
</i><i> if (rtpproxy_offer()) {</i><i><br>
</i><i> t_on_reply("enum_answer");</i><i><br>
</i><i> }</i><i><br>
</i><i> } else {</i><i><br>
</i><i> t_on_reply("enum_offer");</i><i><br>
</i><i> }</i><i><br>
</i><i> }</i><i><br>
</i><i> if (is_method("ACK") &&
has_body("application/sdp")) {</i><i><br>
</i><i> rtpproxy_answer();</i><i><br>
</i><i> }</i><i><br>
</i><i> </i><i><br>
</i><i> t_on_failure("pstn");</i><i><br>
</i><i><br>
</i><i> if(!t_relay()) {</i><i><br>
</i><i> sl_reply_error();</i><i><br>
</i><i> }</i><i><br>
</i><i> exit;</i><i><br>
</i><i>}</i><br>
<br>
<br>
but on establishing call, this is the tcpdump trace between VOIP01
and VOIP02 i get this:<br>
<br>
<i>IP VOIP01.5060 > VOIP02.5060: UDP, length 1170</i><i><br>
</i><i><br>
</i><i>INVITE sip:86472@VOIP02 SIP/2.0</i><i><br>
</i><i>Record-Route:
<sip:VOIP01;lr;ftag=gujliebxxu;did=a26.6c5c0e13></i><i><br>
</i><i>Via: SIP/2.0/UDP VOIP01:5060;branch=z9hG4bKe567.edebdee3.0</i><i><br>
</i><i>Via: SIP/2.0/UDP
172.20.1.47:57907;received=172.20.1.47;branch=z9hG4bK-7l3vckv00z2m;rport=57907</i><i><br>
</i><i>From: "Michele Pinassi"
<sip:5002@VOIP01:5060>;tag=gujliebxxu</i><i><br>
</i><i>To: <sip:009123886472@VOIP01:5060;user=phone></i><i><br>
</i><i>Call-ID: 313434363534333236353330393830-j09a5i32z5kd</i><i><br>
</i><i>CSeq: 2 INVITE</i><i><br>
</i><i>Max-Forwards: 69</i><i><br>
</i><i>User-Agent: snom760/8.7.5.17</i><i><br>
</i><i>Contact: <a moz-do-not-send="true"
class="moz-txt-link-rfc2396E"
href="mailto:sip:5002@172.20.1.47:57907"><sip:5002@172.20.1.47:57907></a>;reg-id=1</i><i><br>
</i><i>X-Serialnumber: 00041371928A</i><i><br>
</i><i>P-Key-Flags: resolution="31x13", keys="4"</i><i><br>
</i><i>Accept: application/sdp</i><i><br>
</i><i>Allow: INVITE, ACK, CANCEL, BYE, REFER, OPTIONS, NOTIFY,
SUBSCRIBE, PRACK, MESSAGE, INFO, UPDATE</i><i><br>
</i><i>Allow-Events: talk, hold, refer, call-info</i><i><br>
</i><i>Supported: timer, 100rel, replaces, from-change</i><i><br>
</i><i>Session-Expires: 3600</i><i><br>
</i><i>Min-SE: 90</i><i><br>
</i><i>Content-Type: application/sdp</i><i><br>
</i><i>Content-Length: 228</i><i><br>
</i><i><br>
</i><i>v=0</i><i><br>
</i><i>o=root 846474428 846474428 IN IP4 172.20.1.47</i><i><br>
</i><i>s=call</i><i><br>
</i><i>c=IN IP4 VOIP01</i><i><br>
</i><i>t=0 0</i><i><br>
</i><i>m=audio 63194 RTP/AVP 9 0 8</i><i><br>
</i><i>a=rtpmap:9 G722/8000</i><i><br>
</i><i>a=rtpmap:0 PCMU/8000</i><i><br>
</i><i>a=rtpmap:8 PCMA/8000</i><i><br>
</i><i>a=ptime:20</i><i><br>
</i><i>a=sendrecv</i><i><br>
</i><i>a=nortpproxy:yes</i><i><br>
</i><i><br>
</i><i>IP VOIP02.5060 > VOIP01.5060: UDP, length 722</i><i><br>
</i><i><br>
</i><i>SIP/2.0 100 Trying</i><i><br>
</i><i>Via: SIP/2.0/UDP
VOIP01:5060;branch=z9hG4bKe567.edebdee3.0;received=VOIP01;rport=5060</i><i><br>
</i><i>Via: SIP/2.0/UDP
172.20.1.47:57907;received=172.20.1.47;branch=z9hG4bK-7l3vckv00z2m;rport=57907</i><i><br>
</i><i>Record-Route:
<sip:VOIP01;lr;ftag=gujliebxxu;did=a26.6c5c0e13></i><i><br>
</i><i>From: "Michele Pinassi"
<sip:5002@VOIP01:5060>;tag=gujliebxxu</i><i><br>
</i><i>To: <sip:009123886472@VOIP01:5060;user=phone></i><i><br>
</i><i>Call-ID: 313434363534333236353330393830-j09a5i32z5kd</i><i><br>
</i><i>CSeq: 2 INVITE</i><i><br>
</i><i>Server: FPBX-2.11.0(11.7.0)</i><i><br>
</i><i>Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE,
NOTIFY, INFO, PUBLISH</i><i><br>
</i><i>Supported: replaces, timer</i><i><br>
</i><i>Session-Expires: 1800;refresher=uas</i><i><br>
</i><i>Contact: <sip:86472@VOIP02:5060></i><i><br>
</i><i>Content-Length: 0</i><i><br>
</i><i><br>
</i><i><br>
</i><i>IP VOIP02.5060 > VOIP01.5060: UDP, length 590</i><i><br>
</i><i><br>
</i><i>SIP/2.0 603 Declined</i><i><br>
</i><i>Via: SIP/2.0/UDP
VOIP01:5060;branch=z9hG4bKe567.edebdee3.0;received=VOIP01;rport=5060</i><i><br>
</i><i>Via: SIP/2.0/UDP
172.20.1.47:57907;received=172.20.1.47;branch=z9hG4bK-7l3vckv00z2m;rport=57907</i><i><br>
</i><i>From: "Michele Pinassi"
<sip:5002@VOIP01:5060>;tag=gujliebxxu</i><i><br>
</i><i>To:
<sip:009123886472@VOIP01:5060;user=phone>;tag=as15312d47</i><i><br>
</i><i>Call-ID: 313434363534333236353330393830-j09a5i32z5kd</i><i><br>
</i><i>CSeq: 2 INVITE</i><i><br>
</i><i>Server: FPBX-2.11.0(11.7.0)</i><i><br>
</i><i>Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE,
NOTIFY, INFO, PUBLISH</i><i><br>
</i><i>Supported: replaces, timer</i><i><br>
</i><i>Content-Length: 0</i><i><br>
</i><i><br>
</i><i><br>
</i><i>IP VOIP01.5060 > VOIP02.5060: UDP, length 375</i><i><br>
</i><i><br>
</i><i>ACK sip:86472@VOIP02 SIP/2.0</i><i><br>
</i><i>Via: SIP/2.0/UDP VOIP01:5060;branch=z9hG4bKe567.edebdee3.0</i><i><br>
</i><i>From: "Michele Pinassi"
<sip:5002@VOIP01:5060>;tag=gujliebxxu</i><i><br>
</i><i>Call-ID: 313434363534333236353330393830-j09a5i32z5kd</i><i><br>
</i><i>To:
<sip:009123886472@VOIP01:5060;user=phone>;tag=as15312d47</i><i><br>
</i><i>CSeq: 2 ACK</i><i><br>
</i><i>Max-Forwards: 70</i><i><br>
</i><i>User-Agent: VoIP Unisi.it</i><i><br>
</i><i>Content-Length: 0</i><br>
<br>
The main doubt is: <i>a=nortpproxy:yes</i> ...why ?<br>
<br>
Thanks, Michele<br>
<br>
<br>
<br>
<pre class="moz-signature" cols="72">--
Michele Pinassi
Responsabile Telefonia di Ateneo
Servizio Reti, Sistemi e Sicurezza Informatica - Università degli Studi di Siena
tel: 0577.(23)5000 - <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:centralino@unisi.it">centralino@unisi.it</a>
Per trovare una soluzione rapida ai tuoi problemi tecnici consulta le FAQ di Ateneo, <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.faq.unisi.it">http://www.faq.unisi.it</a> </pre>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a class="moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
<br>
</body>
</html>