Anope IRC Services

Anope Support => 1.8.x/1.7.x Support (Read Only) => Topic started by: woodsier on August 02, 2009, 10:12:44 AM

Title: Dissallow people to register nicks? - Possible?
Post by: woodsier on August 02, 2009, 10:12:44 AM
Hi guys.

I am testing a project at the moment - When a user registers on my website I have a script that will write registration details of that user automatically to the anope database, just as if that user registered through nickserv.

I was wondering if there was a way to dissallow people from registering nicks directly through nickserv, but still be able to identify, group and such.

Cheers
Title: Re: Dissallow people to register nicks? - Possible?
Post by: Charles Kingsley on August 02, 2009, 10:20:09 AM
You could unload ns_register which might work.

How are you writing the information into the database?
Title: Re: Dissallow people to register nicks? - Possible?
Post by: woodsier on August 02, 2009, 10:33:24 AM
I actually haven't gotten that far - I wasn't going to start until I was certain it was possible.

I was thinking I would just simulate how nickserv registers, but through some PHP/SQL. Would it be possible to explain if this is feasible?
Title: Re: Dissallow people to register nicks? - Possible?
Post by: Charles Kingsley on August 02, 2009, 10:58:59 AM
In the current capacity writing to the MySQL database will be fruitless as anope will dump over the top of it when it saves. (It only 'optionally' reads once from the sql on start up otherwise it just writes).

The current method is up for a rehash in 1.9.x but at the moment your best bet I would imagine is some socket system which via php or so connects to IRC as the user and performs the same /ns register command as a normal user would do which ultimately would then be written to the sql if you wanted your site to authenticate this way or so.

The other method possible at the moment is using an ldap module on 1.9.x which allows anope to directly authenticate to an ldap server (which in turn your site could authenticate to also and allow a sign up). This is something Rob on the team had created when we started looking at ldap for Anope.

Finally, there is an old xmlrpc module around which will help with the first idea with opening a socket or so but I'm not sure of it's location at this time.
Title: Re: Dissallow people to register nicks? - Possible?
Post by: woodsier on August 09, 2009, 05:08:12 AM
Thanks for the reply mate!

In the interests of keeping with the stable branch, I think the php solution sounds fantastic. I'll be giving it a stab over the next few weeks!