0
votes

I was able to register users into my Ejabberd server, and I think I changed something. Now I can't register users at all and i am not getting any error.

I alert the status when i start the registration process, and it just calls 1 then 11 then 10. I am not sure what they mean, and if there is anywhere I can see the definition for them so I can know the error that it is calling.

My registration code should be correct because I can register users into my Openfire server. But it suddenly stopped working while registering in Ejabberd on my localhost and on EC2. So I think I have changed some settings that I shouldn't have.

My register access rules in the configuration:

[{all,allow}]

Here is my code:

         function Onregister(){
  var jid = document.getElementById("jid").value;


         var password=document.getElementById("pass").value;
 var connection = new Strophe.Connection(
  "http://clarkhos-macbook-pro.local:5280/http-bind/");

var callback = function (status) {alert(status);
    if (status === Strophe.Status.REGISTER) {
        connection.register.fields.username =  jid;
        connection.register.fields.name =  jid;
        connection.register.fields.password = password;
        connection.register.submit();
    } else if (status === Strophe.Status.REGISTERED) {
        console.log("registered!");
        connection.authenticate();

    } else if (status === Strophe.Status.CONNECTED) {
        $(document).trigger('connected');
    } 
};



connection.register.connect("clarkhos-macbook-pro.local", callback, 60, 1);

         }

Thanks for your time

Edit:

Also I tried uninstalling the whole ejabberd server in my local machine and re-installed it. Still can't register new users, it has status 1 then 11 then 10 as before.

1
The solution here is obvious: find and change back the settings you changed just before this started happening.AStopher
I tried, all i did was i added a new module, i removed it, then i restarted the server again, but it isnt working still. The thing is i am not sure that when i added the new module, if it had changed other settings automatically which i didnt know.John

1 Answers

0
votes

To mitigate registration attacks on ejabberd, ejabberd has a parameter that limit the number of registration performed from a given IP address.

If you want to change the default setting to relax that constrains during development, you should look into the registration_timeout global parameter. It is documented on mod_register.