[Freeswitch-users] [mod_xml_curl] Only accept if Return Password is blank
Jack
jack at livecall.com
Wed Sep 14 19:57:53 MSD 2011
Sorry, the param should not include the backslashes.
When it reaches Freeswitch it shoud look like this:
*<param name="password" value="1234"/>*
On 9/14/2011 8:50 AM, Jack wrote:
> When I check my database and I have no matching entry I return this to
> FS from curl
>
> "<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\r\n" +
> "<document type=\"freeswitch/xml\">\r\n" +
> " <section name=\"directory\">\r\n" +
> " <result status=\"not found\"/>\r\n" +
> " </section>\r\n" +
> "</document>\r\n"
> if it is found I return all information that would be in the static
> directory xml for that user.
> You should also be returning the password, FreeSwitch checks it
> against what is sent from your client to authenticate.
> This is probably why it works when use a blank password.
>
> this scenario works like a charm for me.
> Jack
>
> On 9/14/2011 2:02 AM, rendyfrx wrote:
>> Hi,
>> I'm trying to setup freeswitch to authenticate SIP client login (SIP
>> register) to my backend database via php, example: username=65972932222,
>> pwd=1234
>> As I couldn't really find sample return that suit my need, so I tried with
>> below xml return. Problem is if the password is blank, then it will
>> accepted, but if I change to simple password 1234 as xml return below, I
>> will get SIP/2.0 403 Forbidden.
>>
>> xml return :
>>
>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>> <document type="freeswitch/xml">
>> <section name="directory" description="User Directory">
>> <domain name="10.1.1.47">
>> <user id="6597293279">
>> <params>
>> *<param name=\"password\" value="1234"/>*
>> </params>
>> </user>
>> </domain>
>> </section>
>>
>> I tried add in groups, but it doesn't have any impact.
>> The bindings' auth-scheme value is "basic", mod_xml_curl will call another
>> server (LAN) and it will validate and return the xml above.
>>
>> Anybody can advise what I might be missing here?
>> Thanks in advance
>>
>>
>> --
>> View this message in context:http://freeswitch-users.2379917.n2.nabble.com/mod-xml-curl-Only-accept-if-Return-Password-is-blank-tp6791769p6791769.html
>> Sent from the freeswitch-users mailing list archive at Nabble.com.
>>
>>
>> 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
>>
>>
>
>
> 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/20110914/7a8f44d2/attachment.html
Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users
mailing list