in-band registration only from particular user?

Is it possible to only allow in-band registration from a particular user? The approach I am looking at is:

1) Connect to Ejabberd using an already registered username and password.
2) From this connection send a request to create a new username with a new password using in-band registration.

If this is possible would I set up the config file as follows:

{acl, adminjid, {user, "admin", "domain.org"}}.

{modules,
[

{mod_register, [{access, register}, [{allow, adminjid}] ] }

] }

If the above doesn't work, is it possible to make in-band registration dependent on a secret key being sent?

In mod_register add this

In mod_register add this option: {access_from, registerfrom},
And add those definitions to allow only tomyre@domain.org to register accounts:
{access, registerfrom, [{allow, registerers}, {deny, all}]}.
{acl, registerers, {user, "tomyre", "domain.org"}}.

Syndicate content