[Freeswitch-users] CURL directory issue

Kevin Green kevin at johnnyvoip.com
Thu Aug 6 08:48:08 PDT 2009


Try returning the full information on the register. It may be that the
variables are read onto the user profile upon registration and since you are
only supplying a dumbed down version for registration the variables aren't
being read and cached.

Regards,
   Kevin Green

On Thu, Aug 6, 2009 at 7:24 AM, Jim Page <jim.page at redmatter.com> wrote:

> Afternoon All
>
> I wonder if someone (perhaps even the illustrious intralanman) could help
> me out with a problem I am experiencing with a CURL directory.
>
> In the interests of understanding how the mechanism works, I am using a
> super-braindead php script to return info about a specific set of users. I
> plan to move to something more sophisticated once the proof of concept is
> complete, possibly based on intralanman's scripts.
>
> The basic problem is that all works fine (boot, register, voicemail etc),
> except that user's <variables> seem not to be being read correctly, eg
> 'toll_allow' and 'user_context'. Here's a typical user XML message I am
> returning:
>
> <document type="freeswitch/xml">
>  <section name="directory">
>   <domain name="pbx.redmatter.com">
>    <params>
>      <param name="dial-string" value="{presence_id=${dialed_user}@
> ${dialed_domain}}${sofia_contact(${dialed_user}@${dialed_domain})}"/>
>    </params>
>
>    <variables>
>      <variable name="record_stereo" value="true"/>
>      <variable name="default_gateway" value="$${default_provider}"/>
>      <variable name="default_areacode" value="$${default_areacode}"/>
>      <variable name="transfer_fallback_extension" value="operator"/>
>    </variables>
>
>    <groups>
>      <group name="default">
>        <users>            <user id="1009" cidr="172.30.99.0/24">
>               <params>
>                 <param name="password" value="$${default_password}"/>
>                 <param name="vm-password" value="1009"/>
>                 <param name="vm-email-all-messages" value="true"/>
>                 <param name="vm-attach-file" value="true"/>
>                 <param name="vm-mailto" value="1009 at redmatter.com"/>
>                 <param name="vm-keep-local-after-email" value="true"/>
>                 <param name="vm_message_ext" value="mp3"/>
>               </params>
>               <variables>
>                 <variable name="toll_allow"
> value="domestic,international,local"/>
>                 <variable name="accountcode" value="1009"/>
>                 <variable name="user_context" value="default"/>
>                 <variable name="effective_caller_id_name" value="Extension
> 1009"/>
>                 <variable name="effective_caller_id_number" value="1009"/>
>                 <variable name="outbound_caller_id_name"
> value="$${outbound_caller_name}"/>
>                 <variable name="outbound_caller_id_number"
> value="$${outbound_caller_id}"/>
>                 <variable name="callgroup" value="techsupport"/>
>               </variables>
>             </user>        </users>
>      </group>
>    </groups>
>   </domain>
>  </section>
> </document>
>
> I return this kind of message in all cases except the
> (sip_auth_method=="REGISTER") request message where I return
>
> <document type="freeswitch/xml">
>  <section name="directory">
>    <domain name="pbx.redmatter.com">
>      <user id="1007">
>        <params>
>          <param name="password" value="1234"/>
>        </params>
>      </user>
>    </domain>
>  </section>
> </document>
>
> Also it's probably worth mentioning that I have removed all trace of xml
> from conf/directory and I don't believe there is a conflict happening there.
>
> The phones register correctly. The trouble is they don't operate on the
> correct dialplan context (I fixed that by hardcoding the internal gateway to
> dialplan default), but the 'toll_allow' variable is now not working so that
> outbound calls fail, which is what made me think that the user variables are
> being ignored.
>
> Freeswitch version is 1.0.4, built by me and running on a dell 1950 running
> Centos 5.3 x86_64. HTTP application is running on standard Centos 5.3
> apache/php.
>
> Any ideas gratefully and humbly received.
>
> All the best
> Jim
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20090806/96693f47/attachment-0002.html 


More information about the FreeSWITCH-users mailing list