<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    On 3/16/2012 5:58 PM, Brian Foster wrote:
    <blockquote
cite="mid:CAKV-jFxH2UcoOXt8JxzDPiELuOracLPrkQNRcsFho4kik-ZkLw@mail.gmail.com"
      type="cite">
      <p>The toll_allow variable.would be defined in the actual user xml
        file located in /usr/local/freeswitch/conf/directory. Then you
        would evaluate that variable in the dialplan that would end up
        making the bridge to your gateway. </p>
      <p>-BDF</p>
      <div class="gmail_quote">On Mar 16, 2012 5:21 AM, "Miha" &lt;<a
          moz-do-not-send="true" href="mailto:miha@softnet.si">miha@softnet.si</a>&gt;
        wrote:<br type="attribution">
        <blockquote class="gmail_quote" style="margin:0 0 0
          .8ex;border-left:1px #ccc solid;padding-left:1ex">
          Hi @Gabriel,<br>
          <br>
          I was looking on wiki how to define new xml or document where
          I will<br>
          have my restricted numbers.<br>
          Where are domestic,international,local defined?<br>
          <br>
          Thanks!<br>
          Miha<br>
          <br>
          On 3/10/2012 11:23 PM, Gabriel Gunderson wrote:<br>
          &gt; On Fri, Mar 9, 2012 at 7:37 AM, Miha Zoubek&lt;<a
            moz-do-not-send="true" href="mailto:miha@softnet.si">miha@softnet.si</a>&gt;
          &nbsp;wrote:<br>
          &gt;&gt; what is the bast way to block destination number for
          certain user.<br>
          &gt;&gt; Is it possible to do it in user/dir?<br>
          &gt; Ultimately, it would be a dialplan configuration, but you
          could set<br>
          &gt; the variable that you match in the directory. See the
          example of<br>
          &gt; 'toll_allow' in the default FreeSWITCH configuration...<br>
          &gt;<br>
          &gt;<br>
          &gt; This is set on a per-user basis in the DIRECTORY:<br>
          &gt;<br>
          &gt; &lt;variable name="toll_allow"
          value="domestic,international,local"/&gt;<br>
          &gt;<br>
          &gt;<br>
          &gt;<br>
          &gt; But it's considered while evaluating the DIALPLAN:<br>
          &gt;<br>
          &gt; &lt;extension name="<a moz-do-not-send="true"
            href="http://local.example.com" target="_blank">local.example.com</a>"&gt;<br>
          &gt; &nbsp; &nbsp;&lt;condition field="${toll_allow}"
          expression="local"/&gt;<br>
          &gt; &nbsp; &nbsp;&lt;condition field="destination_number"
          expression="^(\d{7})$"&gt;<br>
          &gt; &nbsp; &nbsp; &nbsp;&lt;action application="set"<br>
          &gt;
          data="effective_caller_id_number=${outbound_caller_id_number}"/&gt;<br>
          &gt; &nbsp; &nbsp; &nbsp;&lt;action application="set"<br>
          &gt;
          data="effective_caller_id_name=${outbound_caller_id_name}"/&gt;<br>
          &gt; &nbsp; &nbsp; &nbsp;&lt;action application="bridge"<br>
          &gt;
          data="sofia/gateway/${default_gateway}/1${default_areacode}$1"/&gt;<br>
          &gt; &nbsp; &nbsp;&lt;/condition&gt;<br>
          &gt; &lt;/extension&gt;<br>
          &gt;<br>
          &gt;<br>
          &gt;<br>
          &gt; You could easily do something similar by having a list of
          numbers that<br>
          &gt; they can't call listed in the directory (maybe something
          like<br>
          &gt; 'restricted_numbers') and check to make sure the
          destination doesn't<br>
          &gt; match it in the dialplan.<br>
          &gt;<br>
          &gt; Good luck!<br>
          &gt;<br>
          &gt;<br>
          &gt; Gabe<br>
          &gt;<br>
          &gt;
_________________________________________________________________________<br>
          &gt; Professional FreeSWITCH Consulting Services:<br>
          &gt; <a moz-do-not-send="true"
            href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
          &gt; <a moz-do-not-send="true"
            href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
          &gt;<br>
          &gt; FreeSWITCH-powered IP PBX: The CudaTel Communication
          Server<br>
          &gt; <a moz-do-not-send="true" href="http://www.cudatel.com"
            target="_blank">http://www.cudatel.com</a><br>
          &gt;<br>
          &gt; Official FreeSWITCH Sites<br>
          &gt; <a moz-do-not-send="true"
            href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
          &gt; <a moz-do-not-send="true"
            href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
          &gt; <a moz-do-not-send="true" href="http://www.cluecon.com"
            target="_blank">http://www.cluecon.com</a><br>
          &gt;<br>
          &gt; FreeSWITCH-users mailing list<br>
          &gt; <a moz-do-not-send="true"
            href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
          &gt; <a moz-do-not-send="true"
            href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users"
            target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
          &gt; UNSUBSCRIBE:<a moz-do-not-send="true"
            href="http://lists.freeswitch.org/mailman/options/freeswitch-users"
            target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
          &gt; <a moz-do-not-send="true"
            href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
          &gt;<br>
          <br>
          <br>
_________________________________________________________________________<br>
          Professional FreeSWITCH Consulting Services:<br>
          <a moz-do-not-send="true"
            href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
          <a moz-do-not-send="true"
            href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
          <br>
          FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
          <a moz-do-not-send="true" href="http://www.cudatel.com"
            target="_blank">http://www.cudatel.com</a><br>
          <br>
          Official FreeSWITCH Sites<br>
          <a moz-do-not-send="true" href="http://www.freeswitch.org"
            target="_blank">http://www.freeswitch.org</a><br>
          <a moz-do-not-send="true" href="http://wiki.freeswitch.org"
            target="_blank">http://wiki.freeswitch.org</a><br>
          <a moz-do-not-send="true" href="http://www.cluecon.com"
            target="_blank">http://www.cluecon.com</a><br>
          <br>
          FreeSWITCH-users mailing list<br>
          <a moz-do-not-send="true"
            href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
          <a moz-do-not-send="true"
            href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users"
            target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
          UNSUBSCRIBE:<a moz-do-not-send="true"
            href="http://lists.freeswitch.org/mailman/options/freeswitch-users"
            target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
          <a moz-do-not-send="true" href="http://www.freeswitch.org"
            target="_blank">http://www.freeswitch.org</a><br>
        </blockquote>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
<a class="moz-txt-link-abbreviated" href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a>

FreeSWITCH-powered IP PBX: The CudaTel Communication Server
<a class="moz-txt-link-freetext" href="http://www.cudatel.com">http://www.cudatel.com</a>

Official FreeSWITCH Sites
<a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://wiki.freeswitch.org">http://wiki.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://www.cluecon.com">http://www.cluecon.com</a>

FreeSWITCH-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a>
UNSUBSCRIBE:<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a>
<a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a>
</pre>
    </blockquote>
    Thank you Brian!<br>
    <br>
    Regards,<br>
    Miha<br>
  </body>
</html>