AW: [IRCServices] Settings for nicks in nickserv.c

Yusuf Iskenderoglu uhc0 at rz.uni-karlsruhe.de
Mon May 21 18:30:04 PDT 2001


Hello;

> I've almost succeeded (I think), in implementing
> mysql-support in the services. The only things it does now
> is importing nick-info and channel-info from a
> mysql-database (where the information is registered over
> web).

Nice, though I did not know that you have been asked to do so.

> However I seem to have a few problems when setting
> channel-permissions for the imported nicks. I think this is
> because I don't set the correct values for each nick. 

To understand, how a nickinfo is built, you only need nickserv.h
and nothing else. I do not see any complexity.

> I've set the flags correctly for each nick/channel, but when
> I set the accesslevel for a nick to -2 (nojoin), the nick is
> still able to join the channel. Has this something to do
> with the following code ? :
> [snip]
> 		    if (ni->accesscount) {
> 		      char **access;
> 			access = smalloc(sizeof(char *) * ni->accesscount);
> 			ni->access = access;
> 			for (j = 0; j < ni->accesscount; j++, access++) {
> 			    SAFE(read_string(access, f));
> 			}
> 		    }
> [/snip] 

Obviously, you do not understand, how services is working.
Nickname access lists do NOT have anything to do with the
access list of a channel. They are only used, to check whether a
nick has to be killed, if not identified to nickserv.

That the nick is able to join shows clearly that the nojoin setting
you appearently made is mixed up with something else. 
Maybe you mixed the values of leves settings whilst reading from
the database ?

> I think this routine sets the mask or something to the nick,
> or am I barking up the wrong tree with this one ?

Please do read /nickserv help access
before asking this question.

> I cannot set the usermask to the user since all nicks are
> read from the db (it doesn't save yet), or has this nothing
> to do with my problems ?

The usermask is set via the NICK received from the irc server.
The usermask of the last seen is read from the database.

> I hope someone can help me out here; I'm not too far away I
> think.

Please do try to understand how services works, before
trying to modify it in a way that nothing works.

> Btw. Is there some (extensive) documentation for the
> services anywhere ?

You only need the include files, to understand the
structure of *infos. To understand what commands are doing,
you do need to read the helpfiles.

> Sincerely,
> Johan Grasmo

Regards;
yusuf


----------------------------------------------------------------------
| Yusuf Iskenderoglu                | You get to meet all sorts,     |
| eMail - uhc0 at rz.uni-karlsruhe.de  | in this line of work...        |
| eMail - s_iskend at ira.uka.de       |                                |
| ICQ UIN : 20587464 \ TimeMr14C    |                                |
----------------------------------------------------------------------