<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Hello,<br>
<br>
A return code of -4 means that the Register request is lacking auth
credentials. This is normal for the first Register request coming
from an UA, but after the 401 challenge, the UA should send another
Register with the appropriate credentials. If you get this error two
times in a row for the same UA, it means that you are dealing with
some broken UAs that do not properly handle Register authorisation
requests.<br>
<br>
Regards,<br>
<pre class="moz-signature" cols="72">Vlad Paiu
OpenSIPS Developer</pre>
<br>
On 09/05/2011 08:37 PM, <a class="moz-txt-link-abbreviated" href="mailto:magnusadilsom@gmail.com">magnusadilsom@gmail.com</a> wrote:
<blockquote cite="mid:4E6508BD.4080500@gmail.com" type="cite">
<span id="result_box" class="" lang="en"><span class="hps">Hi</span><span
class="">, I'm</span> <span class="hps">new to</span> <span
class="hps">OpenSIPS</span><span class="">,</span> <span
class="hps">set
up</span> <span class="hps">only</span> <span class="hps">load_balance
and
REGISTER<br>
<br>
</span></span><span id="result_box" class="short_text" lang="en"><span
class="hps">but I have</span> <span class="hps">a</span> <span
class="hps">problem with the registration.<br>
<br>
</span></span><span id="result_box" class="short_text" lang="en"><span
class="hps">returns error</span> <span class="hps">some users
"</span></span>Please
send new Register with
auth info 1000<span id="result_box" class="short_text" lang="en"><span
class="hps">"<br>
<br>
i use mysql for register users<br>
</span></span><span id="result_box" class="short_text" lang="en"><span
class="hps"><br>
</span></span><span id="result_box" class="" lang="en"><span
class="hps"><br>
</span></span> if (is_method("REGISTER")) {<br>
if (!www_authorize("", "subscriber")) {<br>
if ($retcode < 0) {<br>
switch ($retcode) {<br>
case - 4:<br>
xlog("L_INFO", "Please send new Register
with
auth info $fU");<br>
www_challenge("", "0");<br>
exit;<br>
case - 2:<br>
xlog("L_INFO", "Wrong password for user
$fU");<br>
sl_send_reply("401", "Wrong password");<br>
break;<br>
case - 1:<br>
xlog("L_INFO", "User doesnt exist $fU");<br>
sl_send_reply("401", "User doesnt exist");<br>
break;<br>
}<br>
}<br>
}<br>
if (!save("location")) {<br>
sl_send_reply("408", "Requeste timeout");<br>
exit;<br>
} <br>
exit;<br>
}<br>
<br>
<br>
__________ Información de ESET Smart Security, versión de la base
de firmas de virus 6438 (20110905) __________<br>
<br>
ESET Smart Security ha comprobado este mensaje.<br>
<br>
<a moz-do-not-send="true" href="http://www.eset.com">http://www.eset.com</a><br>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a class="moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
</body>
</html>