Hi there. Any progress on this????. Looks like quite serious.




On 03/11/14 12:25, lui...@gmail.com wrote:
> Hello prosodiers:
> 
> Today i found a problem with prosodyctl and the register function. I
> have a jabber server running prosody 0.9.6 with a web interface that use
> prosodyctl in order to register accounts with a browser. The problem is
> that prosodyctl register doesn't take care of already registered
> accounts and if you try to use it with registered accounts the behaviour
> is to overwrite the password with the new one rather than throw an error.
> 
> I’m wrote a small patch to util.prosodyctl.lua in order to warn about
> the registered accounts, I think that patch here is the correct place,
> util.prosodyctl.adduser should take care of that.
> 
> 
> 
> *** prosodyctl.lua      2014-11-03 12:18:29.454778944 +0100
> --- /datos/prosody/lib/util/prosodyctl.lua      2014-11-03
> 12:02:37.008468870 +0100
> ***************
> *** 147,156 ****
>                 usermanager.initialize_host(host);
>         end
> 
> !       local ok, errmsg = usermanager.create_user(user, password, host);
> !       if not ok then
> !               return false, errmsg;
> !       end
>         return true;
>   end
> 
> --- 147,163 ----
>                 usermanager.initialize_host(host);
>         end
> 
> !       local exists, usererrmsg = _M.user_exists(params);
> !
> !       if not exists then
> !       local ok, errmsg = usermanager.create_user(user, password, host);
> !       if not ok then
> !               return false, errmsg;
> !       end
> !     else
> !         return false, "user-already-exists";
> !     end
> !
>         return true;
>   end
> 
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "prosody-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to prosody-dev+unsubscr...@googlegroups.com
> <mailto:prosody-dev+unsubscr...@googlegroups.com>.
> To post to this group, send email to prosody-dev@googlegroups.com
> <mailto:prosody-dev@googlegroups.com>.
> Visit this group at http://groups.google.com/group/prosody-dev.
> For more options, visit https://groups.google.com/d/optout.

-- 
Jesús Cea Avión                         _/_/      _/_/_/        _/_/_/
j...@jcea.es - http://www.jcea.es/     _/_/    _/_/  _/_/    _/_/  _/_/
Twitter: @jcea                        _/_/    _/_/          _/_/_/_/_/
jabber / xmpp:j...@jabber.org  _/_/  _/_/    _/_/          _/_/  _/_/
"Things are not so easy"      _/_/  _/_/    _/_/  _/_/    _/_/  _/_/
"My name is Dump, Core Dump"   _/_/_/        _/_/_/      _/_/  _/_/
"El amor es poner tu felicidad en la felicidad de otro" - Leibniz

-- 
You received this message because you are subscribed to the Google Groups 
"prosody-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to prosody-dev+unsubscr...@googlegroups.com.
To post to this group, send email to prosody-dev@googlegroups.com.
Visit this group at http://groups.google.com/group/prosody-dev.
For more options, visit https://groups.google.com/d/optout.

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to