Hi Anthony,<div><br></div><div>this is what I see in the debug:</div><div><br></div><div><div>Dialplan: sofia/external/16469NNNNNN Regex (FAIL) [DIDtest] ${sip_to_user}(011390NNNNNNNNNN;phone-context=+39) =~ /^(\+?|\+1?|1?|011?)(390NNNNNNNNNN).$/ break=on-false</div>
<div><br></div><div>and then it moves on to another dialplan xml file.</div><div><br></div><div>please note that info app shows: </div><div><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; color: rgb(80, 0, 80); "><div>
<div><font class="Apple-style-span" color="#000000"><br></font></div><div><font class="Apple-style-span" color="#000000">variable_sip_to_user: [011390NNNNNNNNNN;phone-context=+39]</font></div><div><font class="Apple-style-span" color="#000000"><br>
</font></div><div><font class="Apple-style-span" color="#000000">shouldn&#39;t this actually match??</font></div><div><font class="Apple-style-span" color="#000000"><br></font></div><div><font class="Apple-style-span" color="#000000">Oh and yes, the copy of FS is pretty old but this is a production system which gets 24 / 7 traffic so the upgrade is being pushed and pushed :(</font></div>
<div><font class="Apple-style-span" color="#000000"><br></font></div><div><font class="Apple-style-span" color="#000000">you think this is simply because it&#39;s an old build?</font></div><div><font class="Apple-style-span" color="#000000"><br>
</font></div><div><font class="Apple-style-span" color="#000000">Thanks</font></div><div><font class="Apple-style-span" color="#000000">RR</font></div><div><font class="Apple-style-span" color="#000000"><br></font></div></div>
</span></div><br><div class="gmail_quote">On Tue, May 25, 2010 at 4:49 PM, Anthony Minessale <span dir="ltr">&lt;<a href="mailto:anthony.minessale@gmail.com">anthony.minessale@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
did you turn up the debug (press f8 or type console loglevel debug)<div>The debug logs will show the data being passed into the regex and the results.</div><div><br></div><div>P.S.</div><div>I hope only your example is from years ago and not your copy of FS.</div>

<div><div><div></div><div class="h5"><br><br><div class="gmail_quote">On Tue, May 25, 2010 at 3:40 PM, David Ponzone <span dir="ltr">&lt;<a href="mailto:david.ponzone@gmail.com" target="_blank">david.ponzone@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">Which means there is no @ in the sip: part of the SIP To field. Only in the phone-context part.<div>FS uses the @ to split the strings into pieces, and then in your case, it fails as one is missing.</div>

<div><div><br><div> <span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Helvetica;font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><div style="word-wrap:break-word">

<span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Helvetica;font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><div style="word-wrap:break-word">

<div><font face="&#39;Helvetica Neue&#39;"><font color="#1C00FF">David Ponzone  </font><font color="#000000" size="3"><span style="font-size:12px">Direction Technique</span></font></font></div><div><font face="&#39;Helvetica Neue&#39;"><font size="3"><span style="font-size:13px">email: <a href="mailto:david.ponzone@ipeva.fr" target="_blank">david.ponzone@ipeva.fr</a></span></font></font></div>

<div><font face="&#39;Helvetica Neue&#39;"><font size="3"><span style="font-size:13px">tel:      01 74 03 18 97</span></font></font></div><div><font face="&#39;Helvetica Neue&#39;"><font size="3"><span style="font-size:13px">gsm:   06 66 98 76 34</span></font></font></div>

<div><font face="&#39;Helvetica Neue&#39;"><br></font></div><div><font color="#1C00FF" face="&#39;Helvetica Neue&#39;">Service Client<span> </span></font><font face="&#39;Helvetica Neue&#39;"><font color="#FF0000">IP</font></font><font color="#1C00FF" face="&#39;Helvetica Neue&#39;">eva</font></div>

<div><font color="#1C00FF" face="&#39;Helvetica Neue&#39;"><span style="color:rgb(0, 0, 0);font-family:Helvetica"><div><font face="&#39;Helvetica Neue&#39;"><font size="3"><span style="font-size:13px">tel:      0811 46 26 26</span></font></font></div>

<div><font face="&#39;Helvetica Neue&#39;" size="3"><span style="font-size:13px"><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;color:rgb(0, 34, 243)"><span style="text-decoration:underline"><a>www.ipeva.fr</a></span><span style="color:rgb(101, 104, 149)">  -   <span style="color:rgb(0, 34, 243);text-decoration:underline"><a>www.ipeva-studio.com</a></span></span></div>

<div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;color:rgb(0, 34, 243)"><span style="text-decoration:underline"><br></span></div><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;color:rgb(0, 34, 243)">

<span><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;text-align:justify;color:rgb(192, 192, 192)"><i>Ce message et toutes les pièces jointes sont confidentiels et établis à l&#39;intention exclusive de ses destinataires. Toute utilisation ou diffusion non autorisée est interdite. Tout message électronique est susceptible d&#39;altération. </i><b><i>IPeva</i></b><i> décline toute responsabilité au titre de ce message s&#39;il a été altéré, déformé ou falsifié. Si vous n&#39;êtes pas destinataire de ce message, merci de le détruire immédiatement et d&#39;avertir l&#39;expéditeur.</i></div>

<div style="text-decoration:underline;text-align:justify"><font color="#C0C0C0"><i><br></i></font></div></span></div></span></font></div></span></font></div></div></span><br></div></span><br> </div><br></div><div><div>Le 25/05/2010 à 22:28, RR a écrit :</div>

<div><div></div><div><br><blockquote type="cite">Hi Guys,<div><br></div><div>Thanks for the quick feedback</div><div><br></div><div>David, no we&#39;re getting the full URI with the domain part intact, just nothing before the &quot;&lt;&quot; braces</div>

<div><br></div><div> Michael, I already tried the info app and we get</div><div><br></div><div><div>variable_sip_to_user: [011390NNNNNNNNNN;phone-context=+39]</div><div>variable_sip_to_uri: [011390NNNNNNNNNN;<a href="mailto:phone-context=+39@208.xx.xxx.xxx" target="_blank">phone-context=+39@208.xx.xxx.xxx</a>:5060]</div>

 <div><br></div><div>Thanks</div><div>RR</div></div><div><br><br><div class="gmail_quote">On Tue, May 25, 2010 at 4:12 PM, Michael Collins <span dir="ltr">&lt;<a href="mailto:msc@freeswitch.org" target="_blank">msc@freeswitch.org</a>&gt;</span> wrote:<br>

 <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br><br><div class="gmail_quote"><div>On Tue, May 25, 2010 at 12:48 PM, RR <span dir="ltr">&lt;<a href="mailto:ranjtech@gmail.com" target="_blank">ranjtech@gmail.com</a>&gt;</span> wrote:<br>

 <blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204, 204, 204);padding-left:1ex"> Hello I want to follow up on this example from YEARS ago. I had tried using the variable &quot;destination_number&quot; but that didn&#39;t work, and I figured that it was because the To: header doesn&#39;t have the destination_number but has just the URI, so I thought I&#39;d use sip_to_user instead.<div>

 <br></div><div>We have calls coming in with the following info in the INVITE</div><div><br></div><div>From: &quot;16469NNNNNN&quot; &lt;<a>sip:16469NNNNNN;phone-context=+1@67.1x.xxx.xxx:5060;user=phone</a>&gt;;tag=SDru6fc01-gK0c10a887.</div>

 <div>To: &lt;<a>sip:011390NNNNNNNNNN;phone-context=+39@xxx.xxx.xxx.xxx:5060;user=phone</a>&gt;.</div><div>(N and x are obviously being masked for privacy)</div><div><br></div><div>I use this info in the dialplan like so</div>

<div> <br></div><div><div>&lt;include&gt;</div><div>  &lt;extension name=&quot;DIDtest&quot;&gt;</div><div>    &lt;condition field=&quot;ani&quot; expression=&quot;^(\+?|\+1?|1?)(6469NNNNNN).*$&quot; break=&quot;never&quot;&gt;</div>

 <div>        &lt;action application=&quot;set&quot; data=&quot;effective_caller_id_number=$2&quot;/&gt;</div><div>        &lt;action application=&quot;set&quot; data=&quot;effective_caller_id_name=$2&quot;/&gt;</div><div>

     &lt;/condition&gt;</div><div>    &lt;condition field=&quot;${sip_to_user}&quot; expression=&quot;^(\+?|\+1?|1?|011?)(390NNNNNNNNNN).$&quot; break=&quot;never&quot;&gt;</div><div>        &lt;action application=&quot;set&quot; data=&quot;continue_on_fail=false&quot;/&gt;</div>

 <div>        &lt;action application=&quot;set&quot; data=&quot;hangup_after_bridge=true&quot;/&gt;</div><div>        &lt;action application=&quot;set&quot; data=&quot;domain_name=$${domain}&quot;/&gt;</div><div>        &lt;action application=&quot;set&quot; data=&quot;bypass_media=true&quot;/&gt;</div>

 <div>        &lt;action application=&quot;bridge&quot; data=&quot;{sip_invite_domain=${sip_from_host}}sofia/gateway/blade2/$2&quot;/&gt;</div><div>    &lt;/condition&gt;</div><div>  &lt;/extension&gt;</div><div>&lt;/include&gt;</div>

 <div><br></div></div><div>However, the calls aren&#39;t passing the condition in this dialplan and thus not being forwarded to &quot;blade2&quot; server. In fact, even the 011 is not being stripped off. </div><div><br></div>

 <div>What am I doing wrong?</div></blockquote></div><div><br>Create a quick test extension that only does an info dump. (See 9992 in default.xml for an example.) Make a call, look at the info dump, and make sure that what you think you are getting is really what you are getting. :)<br>

 <br>-MC<br></div></div><br> <br>_______________________________________________<br> FreeSWITCH-users mailing list<br> <a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>

 <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>

 <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br> <br></blockquote></div><br></div> _______________________________________________<br>FreeSWITCH-users mailing list<br><a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>

<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>

<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br></blockquote></div></div></div><br></div></div><br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br><br clear="all"><br></div></div>-- <br><div class="im">Anthony Minessale II<br><br>FreeSWITCH <a href="http://www.freeswitch.org/" target="_blank">http://www.freeswitch.org/</a><br>ClueCon <a href="http://www.cluecon.com/" target="_blank">http://www.cluecon.com/</a><br>
</div>
Twitter: <a href="http://twitter.com/FreeSWITCH_wire" target="_blank">http://twitter.com/FreeSWITCH_wire</a><div class="im"><br><br>AIM: anthm<br><a href="mailto:MSN%3Aanthony_minessale@hotmail.com" target="_blank">MSN:anthony_minessale@hotmail.com</a><br>
</div><div class="im">GTALK/JABBER/<a href="mailto:PAYPAL%3Aanthony.minessale@gmail.com" target="_blank">PAYPAL:anthony.minessale@gmail.com</a><br></div>
IRC: <a href="http://irc.freenode.net" target="_blank">irc.freenode.net</a> #freeswitch<div class="im"><br><br>FreeSWITCH Developer Conference<br><a href="mailto:sip%3A888@conference.freeswitch.org" target="_blank">sip:888@conference.freeswitch.org</a><br>
</div><div class="im"><a href="mailto:googletalk%3Aconf%2B888@conference.freeswitch.org" target="_blank">googletalk:conf+888@conference.freeswitch.org</a><br></div>
pstn:+19193869900<br>
</div>
<br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br></div>