Turn on debug from fs_cli:<div>xml_curl debug_on</div><div><br></div><div>Get a debug trace of what's happening and post the console log and the reply xml file to <a href="http://pastebin.freeswitch.org">pastebin.freeswitch.org</a>. (Note that the xml_curl debug will give you the full path to the xml log file.)</div>
<div><br></div><div>-MC<br><br><div class="gmail_quote">On Sun, Dec 18, 2011 at 9:02 PM, rakib 0000 <span dir="ltr"><<a href="mailto:rakib0000@hotmail.com">rakib0000@hotmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><div dir="ltr">
Hello list,<br><br>I'm a newbie FreeSwitch user, trying to learn how
mod_xml_curl works. I've done the basics things mentioned in FreeSwitch
wiki pages about using mod_xml_curl. Now my plan to use mod_xml_curl for
user registration. So, what I've done is - I wrote a server end
application which reads POST request from mod_xml_curl and tries to find
whether it's a valid post request (REGISTER) or not. If the request is a
REGISTER request - then the application extracts the user id, domain.
Then, it queries the database and extracts password and creates xml
response. One of my sample response are like below (the following
response has been taken from /tmp):<br><br><?xml version="1.0" encoding="UTF-8" standalone="no"?><br> <document type="freeswitch/xml"><br> <section name="directory"><br>
<domain name="192.168.0.108"><br> <groups><br> <group name="default"><br> <users><br> <user id="1100"><br> <params><br> <param name="password" value="sakib"/><br>
</params><br> <variables><br> <variable name="user_context" value="default"/><br> </variables><br> </user><br> </users><br>
</group><br> </groups><br> </domain><br> </section><br> </document><br><br>With above response, I didn't had any luck. It fails to register, with following response:<br><br>2011-12-18 14:51:29.253474 [WARNING] sofia_reg.c:2446 Can't find user [<a href="mailto:1100@192.168.0.108" target="_blank">1100@192.168.0.108</a>]<br>
You must define a domain called '192.168.0.108' in your directory and add a user with the id="1100" attribute<br>and you must configure your device to use the proper domain in it's authentication credentials.<br>
<br>To
figure it out, I've tried in different ways too. Like, I've used the
above response patterns to create a user under conf/directory/default/
directory, but didn't work. Then I tried the following xml response
pattern :<br><br><include><br> <user id="1003"><br> <params><br> <param name="password" value="$${default_password}"/><br> </params><br> <variables><br>
<variable name="user_context" value="default"/><br> </variables><br> </user><br></include><br><br>with
the above xml I manage to create a user and authenticate perfectly.
But, I've modified my server end application to give a that kind of
response, but didn't work though. I've copied the server response (from
the content dumped under /tmp) to create an user under
conf/directory/default/ directory - but it works. So, my question is
what am I missing here? FreeSwitch tries to get the response from the
server, it gets the response too, but somehow not interpreting the
response (or something else?) and gives "can't find user" error. Any
hint's , suggestion will be very helpful. (note, I'm not using any
webserver here.)<br><br>Thanks in advance,<br>Rakib                                            </div></div>
</blockquote></div><br></div>