Thread: [IRC-Dev CVS] [CVS] Module ircd-ircdev: Change committed (Page 5)
Brought to you by:
zolty
From: Toni G. <zo...@us...> - 2005-05-23 08:53:21
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-23 08:53:14 UTC Modified files: TODO.es Log message: actualizacion ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.24 ircd-ircdev/TODO.es:1.25 --- ircd-ircdev/TODO.es:1.24 Mon May 16 03:18:57 2005 +++ ircd-ircdev/TODO.es Mon May 23 01:53:04 2005 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.24 2005/05/16 10:18:57 zolty Exp $ +# $Id: TODO.es,v 1.25 2005/05/23 08:53:04 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -41,7 +41,6 @@ - [S] Comando SVSVHOST para cambiar la virtualhost. Estudiar alguna forma de propagarse en el burst. - [S] Comando /IDENTIFY y autentificacion NICK nick clave. - - [S] Comprobar el comando OPMODE haga lo que hacia el SAMODE de Terraircu. PRIORIDAD BAJA ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-05-23 08:59:10
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-23 08:58:47 UTC Modified files: ChangeLog ChangeLog.es include/patchlevel.h ircd/s_conf.c ircd/s_serv.c ircd/s_user.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-05-23 Toni García <zo...@ir...> 1.0.alpha36 * Arreglos URGENTES ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.37 ircd-ircdev/ChangeLog:1.38 --- ircd-ircdev/ChangeLog:1.37 Mon May 16 04:31:19 2005 +++ ircd-ircdev/ChangeLog Mon May 23 01:58:36 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.37 2005/05/16 11:31:19 zolty Exp $ +# $Id: ChangeLog,v 1.38 2005/05/23 08:58:36 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-05-23 Toni García <zo...@ir...> 1.0.alpha36 + * URGENT bugfixes + 2005-05-16 Toni García <zo...@ir...> 1.0.alpha35 * Testing tools Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.37 ircd-ircdev/ChangeLog.es:1.38 --- ircd-ircdev/ChangeLog.es:1.37 Mon May 16 04:31:19 2005 +++ ircd-ircdev/ChangeLog.es Mon May 23 01:58:36 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.37 2005/05/16 11:31:19 zolty Exp $ +# $Id: ChangeLog.es,v 1.38 2005/05/23 08:58:36 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-05-23 Toni García <zo...@ir...> 1.0.alpha36 + * Arreglos URGENTES + 2005-05-16 Toni García <zo...@ir...> 1.0.alpha35 * Utilidades de Testing Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.36 ircd-ircdev/include/patchlevel.h:1.37 --- ircd-ircdev/include/patchlevel.h:1.36 Mon May 16 04:31:20 2005 +++ ircd-ircdev/include/patchlevel.h Mon May 23 01:58:37 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.36 2005/05/16 11:31:20 zolty Exp $ + * $Id: patchlevel.h,v 1.37 2005/05/23 08:58:37 zolty Exp $ * */ -#define PATCHLEVEL ".alpha35" +#define PATCHLEVEL ".alpha36" #define RELEASE "1.0" Index: ircd-ircdev/ircd/s_conf.c diff -u ircd-ircdev/ircd/s_conf.c:1.16 ircd-ircdev/ircd/s_conf.c:1.17 --- ircd-ircdev/ircd/s_conf.c:1.16 Mon May 16 03:17:27 2005 +++ ircd-ircdev/ircd/s_conf.c Mon May 23 01:58:37 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief ircd configuration file driver - * @version $Id: s_conf.c,v 1.16 2005/05/16 10:17:27 zolty Exp $ + * @version $Id: s_conf.c,v 1.17 2005/05/23 08:58:37 zolty Exp $ */ #include "config.h" @@ -1118,6 +1118,7 @@ * added a check against the user's IP address to find_gline() -Kev */ send_reply(cptr, SND_EXPLICIT | ERR_YOUREBANNEDCREEP, ":%s.", GlineReason(agline)); + return -2; } return 0; Index: ircd-ircdev/ircd/s_serv.c diff -u ircd-ircdev/ircd/s_serv.c:1.11 ircd-ircdev/ircd/s_serv.c:1.12 --- ircd-ircdev/ircd/s_serv.c:1.11 Mon May 16 03:17:27 2005 +++ ircd-ircdev/ircd/s_serv.c Mon May 23 01:58:37 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Miscellaneous server support functions. - * @version $Id: s_serv.c,v 1.11 2005/05/16 10:17:27 zolty Exp $ + * @version $Id: s_serv.c,v 1.12 2005/05/23 08:58:37 zolty Exp $ */ #include "config.h" @@ -140,9 +140,6 @@ feature_bool(FEAT_HUB) ? "h" : "", *(cli_info(&me)) ? cli_info(&me) : "IRCers United"); -#if defined(DDB) - /* ddb_burst(cptr); */ -#endif /* * Don't charge this IP# for connecting * XXX - if this comes from a server port, it will not have been added Index: ircd-ircdev/ircd/s_user.c diff -u ircd-ircdev/ircd/s_user.c:1.18 ircd-ircdev/ircd/s_user.c:1.19 --- ircd-ircdev/ircd/s_user.c:1.18 Mon May 16 03:17:27 2005 +++ ircd-ircdev/ircd/s_user.c Mon May 23 01:58:37 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Miscellaneous user-related helper functions. - * @version $Id: s_user.c,v 1.18 2005/05/16 10:17:27 zolty Exp $ + * @version $Id: s_user.c,v 1.19 2005/05/23 08:58:37 zolty Exp $ */ #include "config.h" @@ -822,8 +822,9 @@ * Esta comprobacion solo se va a hacer si * el usuario es local y no esta haciendo nick flood. */ - if (MyConnect(cptr) && !IsIdentify(flags) && (ddb = ddb_find_key(DDB_NICKDB, (char *)nick)) - && (CurrentTime >= cli_nextnick(cptr))) + if (!IsServer(cptr) && MyConnect(cptr) && !IsIdentify(flags) + && (ddb = ddb_find_key(DDB_NICKDB, (char *)nick)) + && (CurrentTime >= cli_nextnick(sptr))) { const char *name; int nick_forbid = 0; @@ -996,11 +997,11 @@ * if client is on any channels where it is currently * banned. If so, do not allow the nick change to occur. */ - if (MyUser(sptr) && !IsRenamed(flags)) + if (MyUser(sptr)) { const char* channel_name; struct Membership *member; - if ((channel_name = find_no_nickchange_channel(sptr))) { + if ((channel_name = find_no_nickchange_channel(sptr)) && !IsRenamed(flags)) { return send_reply(cptr, ERR_BANNICKCHANGE, channel_name); } /* @@ -1011,7 +1012,7 @@ * however, allow to do two nick changes immediately after another * before limiting the nick flood. -Run */ - if (CurrentTime < cli_nextnick(cptr)) + if ((CurrentTime < cli_nextnick(cptr)) && !IsRenamed(flags)) { cli_nextnick(cptr) += 2; send_reply(cptr, ERR_NICKTOOFAST, parv[1], ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-05-25 16:56:43
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-25 16:56:35 UTC Modified files: ChangeLog ChangeLog.es include/channel.h include/ddb.h include/handlers.h include/msg.h include/patchlevel.h include/send.h include/supported.h ircd/Makefile.in ircd/channel.c ircd/ddb.c ircd/ddb_events.c ircd/hash.c ircd/m_join.c ircd/m_kick.c ircd/m_mode.c ircd/m_names.c ircd/m_whois.c ircd/parse.c ircd/s_user.c ircd/send.c ircd/whocmds.c Added files: ircd/m_bmode.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-05-25 Toni García <zo...@ir...> 1.0.alpha37 * Canales registrados (con modo +r) * Modo owner/founder (+q) * Tabla c de Canales ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.38 ircd-ircdev/ChangeLog:1.39 --- ircd-ircdev/ChangeLog:1.38 Mon May 23 01:58:36 2005 +++ ircd-ircdev/ChangeLog Wed May 25 09:56:22 2005 @@ -1,10 +1,15 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.38 2005/05/23 08:58:36 zolty Exp $ +# $Id: ChangeLog,v 1.39 2005/05/25 16:56:22 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-05-25 Toni García <zo...@ir...> 1.0.alpha37 + * Registered channels (with mode +r) + * Owner/founder mode (+q) + * Channel table c + 2005-05-23 Toni García <zo...@ir...> 1.0.alpha36 * URGENT bugfixes Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.38 ircd-ircdev/ChangeLog.es:1.39 --- ircd-ircdev/ChangeLog.es:1.38 Mon May 23 01:58:36 2005 +++ ircd-ircdev/ChangeLog.es Wed May 25 09:56:22 2005 @@ -1,10 +1,15 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.38 2005/05/23 08:58:36 zolty Exp $ +# $Id: ChangeLog.es,v 1.39 2005/05/25 16:56:22 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-05-25 Toni García <zo...@ir...> 1.0.alpha37 + * Canales registrados (con modo +r) + * Modo owner/founder (+q) + * Tabla c de Canales + 2005-05-23 Toni García <zo...@ir...> 1.0.alpha36 * Arreglos URGENTES Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.9 ircd-ircdev/include/channel.h:1.10 --- ircd-ircdev/include/channel.h:1.9 Wed Mar 9 10:12:32 2005 +++ ircd-ircdev/include/channel.h Wed May 25 09:56:23 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Channel management and maintenance. - * @version $Id: channel.h,v 1.9 2005/03/09 18:12:32 zolty Exp $ + * @version $Id: channel.h,v 1.10 2005/05/25 16:56:23 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -91,9 +91,18 @@ */ #define CHFL_DELAYED 0x40000 /**< User's join message is delayed */ +#if defined(DDB) || defined(SERVICES) +#define CHFL_OWNER 0x10000 /**< Channel owner */ + +#define CHFL_OVERLAP (CHFL_OWNER | CHFL_CHANOP | CHFL_VOICE) +#define CHFL_BANVALIDMASK (CHFL_BANVALID | CHFL_BANNED) +#define CHFL_VOICED_OR_OPPED (CHFL_OWNER | CHFL_CHANOP | CHFL_VOICE) +#else + #define CHFL_OVERLAP (CHFL_CHANOP | CHFL_VOICE) #define CHFL_BANVALIDMASK (CHFL_BANVALID | CHFL_BANNED) #define CHFL_VOICED_OR_OPPED (CHFL_CHANOP | CHFL_VOICE) +#endif /* Channel Visibility macros */ @@ -108,8 +117,12 @@ #define MODE_KEY 0x0100 /**< +k Keyed */ #define MODE_BAN 0x0200 /**< +b Ban */ #define MODE_LIMIT 0x0400 /**< +l Limit */ -#define MODE_REGONLY 0x0800 /**< Only +r users may join */ +#define MODE_REGONLY 0x0800 /**< +R Only +r users may join */ #define MODE_DELJOINS 0x1000 /**< New join messages are delayed */ +#if defined(DDB) || defined(SERVICES) +#define MODE_REGCHAN 0x2000 /**< +r Channel registered */ +#define MODE_OWNER CHFL_OWNER /**< +q Channel owner */ +#endif #define MODE_SAVE 0x20000 /**< save this mode-with-arg 'til * later */ #define MODE_FREE 0x40000 /**< string needs to be passed to @@ -130,6 +143,15 @@ #define infochanmodes feature_bool(FEAT_OPLEVELS) ? "AbiklmnopstUvrD" : "biklmnopstvrD" /** Available Channel modes that take parameters */ #define infochanmodeswithparams feature_bool(FEAT_OPLEVELS) ? "AbkloUv" : "bklov" +#elif defined(DDB) || defined(SERVICES) +/** mode flags which take another parameter (With PARAmeterS) + */ +#define MODE_WPARAS (MODE_OWNER|MODE_CHANOP|MODE_VOICE|MODE_BAN|MODE_KEY|MODE_LIMIT) + +/** Available Channel modes */ +#define infochanmodes "biklmnopstvrRDq" +/** Available Channel modes that take parameters */ +#define infochanmodeswithparams "bklovq" #else /** mode flags which take another parameter (With PARAmeterS) */ @@ -225,24 +247,21 @@ struct Membership* next_channel; /**< Next channel this user is on */ struct Membership* prev_channel; /**< Previous channel this user is on*/ unsigned int status; /**< Flags for op'd, voice'd, etc */ -#if defined(UNDERNET) unsigned short oplevel; /**< Op level */ -#endif }; -#if defined(UNDERNET) #define MAXOPLEVELDIGITS 3 #define MAXOPLEVEL 999 -#endif #define IsZombie(x) ((x)->status & CHFL_ZOMBIE) /**< see \ref zombie */ #define IsDeopped(x) ((x)->status & CHFL_DEOPPED) #define IsBanned(x) ((x)->status & CHFL_BANNED) #define IsBanValid(x) ((x)->status & CHFL_BANVALID) +#if defined(DDB) || defined(SERVICES) +#define IsChanOwner(x) ((x)->status & CHFL_OWNER) +#endif #define IsChanOp(x) ((x)->status & CHFL_CHANOP) -#if defined(UNDERNET) #define OpLevel(x) ((x)->oplevel) -#endif #define HasVoice(x) ((x)->status & CHFL_VOICE) #define IsServOpOk(x) ((x)->status & CHFL_SERVOPOK) #define IsBurstJoined(x) ((x)->status & CHFL_BURST_JOINED) @@ -261,8 +280,11 @@ #define SetZombie(x) ((x)->status |= CHFL_ZOMBIE) #if defined(UNDERNET) #define SetChannelManager(x) ((x)->status |= CHFL_CHANNEL_MANAGER) -#define SetOpLevel(x, v) (void)((x)->oplevel = (v)) #endif +#if defined(DDB) || defined(SERVICES) +#define SetChanOwner(x) ((x)->status |= CHFL_OWNER) +#endif +#define SetOpLevel(x, v) (void)((x)->oplevel = (v)) #define SetUserParting(x) ((x)->status |= CHFL_USER_PARTING) #define SetDelayedJoin(x) ((x)->status |= CHFL_DELAYED) @@ -272,6 +294,9 @@ #define ClearServOpOk(x) ((x)->status &= ~CHFL_SERVOPOK) #define ClearBurstJoined(x) ((x)->status &= ~CHFL_BURST_JOINED) #define ClearDelayedJoin(x) ((x)->status &= ~CHFL_DELAYED) +#if defined(DDB) || defined(SERVICES) +#define ClearChanOwner(x) ((x)->status &= ~CHFL_OWNER) +#endif /** Mode information for a channel */ struct Mode { @@ -344,6 +369,9 @@ struct Client *mb_source; /**< Source of MODE changes */ struct Client *mb_connect; /**< Connection of MODE changes */ struct Channel *mb_channel; /**< Channel they affect */ +#if defined(DDB) + char *mb_botname; /**< Nick Bot of MODE changes */ +#endif unsigned int mb_dest; /**< Destination of MODE changes */ unsigned int mb_count; /**< Number of modes w/args */ struct { @@ -370,6 +398,9 @@ #define MODEBUF_DEST_HACK4 0x08000 /**< Send a HACK(4) notice, TS == 0 */ #define MODEBUF_DEST_NOKEY 0x10000 /**< Don't send the real key */ +#if defined(DDB) +#define MODEBUF_DEST_BOTMODE 0x20000 /**< Mode send by Bot */ +#endif #define MB_TYPE(mb, i) ((mb)->mb_modeargs[(i)].mbm_type) #define MB_UINT(mb, i) ((mb)->mb_modeargs[(i)].mbm_arg.mbma_uint) @@ -433,6 +464,9 @@ extern void remove_user_from_channel(struct Client *sptr, struct Channel *chptr); extern void remove_user_from_all_channels(struct Client* cptr); +#if defined(DDB) || defined(SERVICES) +extern int is_chan_owner(struct Client *cptr, struct Channel *chptr); +#endif extern int is_chan_op(struct Client *cptr, struct Channel *chptr); extern int is_zombie(struct Client *cptr, struct Channel *chptr); extern int has_voice(struct Client *cptr, struct Channel *chptr); Index: ircd-ircdev/include/ddb.h diff -u ircd-ircdev/include/ddb.h:1.8 ircd-ircdev/include/ddb.h:1.9 --- ircd-ircdev/include/ddb.h:1.8 Mon May 16 03:17:26 2005 +++ ircd-ircdev/include/ddb.h Wed May 25 09:56:23 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Distributed DataBases structures, macros and functions. - * @version $Id: ddb.h,v 1.8 2005/05/16 10:17:26 zolty Exp $ + * @version $Id: ddb.h,v 1.9 2005/05/25 16:56:23 zolty Exp $ */ #ifndef INCLUDED_ddb_h #define INCLUDED_ddb_h @@ -49,6 +49,8 @@ #define DDB_INIT 'a' /** Channels table of %DDB Distributed Databases. */ #define DDB_CHANDB 'c' +/** Channels table (nicks) of %DDB Distributed Databases. */ +#define DDB_CHANDB2 'd' /** Ilines table of %DDB Distributed Databases. */ #define DDB_ILINEDB 'i' /** Nicks table of %DDB Distributed Databases. */ @@ -73,6 +75,8 @@ */ /** Nickname of virtual bot for nicks registers */ #define DDB_NICKSERV "NickServ" +/** Nickname of virtual bot for channel bot */ +#define DDB_CHANSERV "ChanServ" /** Describes a key on one table. Index: ircd-ircdev/include/handlers.h diff -u ircd-ircdev/include/handlers.h:1.12 ircd-ircdev/include/handlers.h:1.13 --- ircd-ircdev/include/handlers.h:1.12 Sat Apr 2 11:47:34 2005 +++ ircd-ircdev/include/handlers.h Wed May 25 09:56:23 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Declarations for all protocol message handler functions. - * @version $Id: handlers.h,v 1.12 2005/04/02 19:47:34 zolty Exp $ + * @version $Id: handlers.h,v 1.13 2005/05/25 16:56:23 zolty Exp $ */ #ifndef INCLUDED_handlers_h #define INCLUDED_handlers_h @@ -198,6 +198,7 @@ extern int ms_admin(struct Client*, struct Client*, int, char*[]); extern int ms_asll(struct Client*, struct Client*, int, char*[]); extern int ms_away(struct Client*, struct Client*, int, char*[]); +extern int ms_bmode(struct Client*, struct Client*, int, char*[]); extern int ms_burst(struct Client*, struct Client*, int, char*[]); extern int ms_clearmode(struct Client*, struct Client*, int, char*[]); extern int ms_connect(struct Client*, struct Client*, int, char*[]); Index: ircd-ircdev/include/msg.h diff -u ircd-ircdev/include/msg.h:1.12 ircd-ircdev/include/msg.h:1.13 --- ircd-ircdev/include/msg.h:1.12 Sat Apr 2 11:47:34 2005 +++ ircd-ircdev/include/msg.h Wed May 25 09:56:23 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Command and token declarations and structures. - * @version $Id: msg.h,v 1.12 2005/04/02 19:47:34 zolty Exp $ + * @version $Id: msg.h,v 1.13 2005/05/25 16:56:23 zolty Exp $ */ #ifndef INCLUDED_msg_h #define INCLUDED_msg_h @@ -378,6 +378,10 @@ #define TOK_DBQ "DBQ" #define CMD_DBQ MSG_DBQ, TOK_DBQ +#define MSG_BMODE "BMODE" /* BMODE */ +#define TOK_BMODE "BM" +#define CMD_BMODE MSG_BMODE, TOK_BMODE + #define MSG_GHOST "GHOST" /* GHOST */ #define TOK_GHOST "GHOST" #define CMD_GHOST MSG_GHOST, TOK_GHOST Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.37 ircd-ircdev/include/patchlevel.h:1.38 --- ircd-ircdev/include/patchlevel.h:1.37 Mon May 23 01:58:37 2005 +++ ircd-ircdev/include/patchlevel.h Wed May 25 09:56:23 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.37 2005/05/23 08:58:37 zolty Exp $ + * $Id: patchlevel.h,v 1.38 2005/05/25 16:56:23 zolty Exp $ * */ -#define PATCHLEVEL ".alpha36" +#define PATCHLEVEL ".alpha37" #define RELEASE "1.0" Index: ircd-ircdev/include/send.h diff -u ircd-ircdev/include/send.h:1.7 ircd-ircdev/include/send.h:1.8 --- ircd-ircdev/include/send.h:1.7 Thu Mar 31 04:58:03 2005 +++ ircd-ircdev/include/send.h Wed May 25 09:56:23 2005 @@ -21,7 +21,7 @@ */ /** @file send.h * @brief Send messages to certain targets. - * @version $Id: send.h,v 1.7 2005/03/31 12:58:03 zolty Exp $ + * @version $Id: send.h,v 1.8 2005/05/25 16:56:23 zolty Exp $ */ #ifndef INCLUDED_send_h #define INCLUDED_send_h @@ -56,10 +56,12 @@ */ extern void sendrawto_one(struct Client *to, const char *pattern, ...); +#if defined(DDB) /* Send a bot command to one client */ -extern void sendcmdbotto_one(char *botname, const char *cmd, +extern void sendcmdbotto_one(const char *botname, const char *cmd, const char *tok, struct Client *to, const char *pattern, ...); +#endif /* Send a command to one client */ extern void sendcmdto_one(struct Client *from, const char *cmd, @@ -89,6 +91,17 @@ struct Client *one, const char *pattern, ...); +#if defined(DDB) +/* Send bot command to all channel users on this server */ +extern void sendcmdbotto_channel_butserv_butone(const char *botmode, + const char *cmd, + const char *tok, + struct Channel *to, + struct Client *one, + unsigned int skip, + const char *pattern, ...); +#endif + /* Send command to all channel users on this server */ extern void sendcmdto_channel_butserv_butone(struct Client *from, const char *cmd, Index: ircd-ircdev/include/supported.h diff -u ircd-ircdev/include/supported.h:1.7 ircd-ircdev/include/supported.h:1.8 --- ircd-ircdev/include/supported.h:1.7 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/supported.h Wed May 25 09:56:23 2005 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: supported.h,v 1.7 2005/01/10 12:22:00 zolty Exp $ + * $Id: supported.h,v 1.8 2005/05/25 16:56:23 zolty Exp $ * */ #ifndef INCLUDED_supported_h @@ -73,7 +73,11 @@ #define FEATURESVALUES1 AWAYLEN, CHANNELLEN, NICKLEN, feature_int(FEAT_NICKLEN), TOPICLEN -#define FEATURESVALUES2 "b,k,l,imnpstrD", feature_bool(FEAT_LOCAL_CHANNELS) ? "#&" : "#", "(ov)@+", "@+" +#if defined(DDB) || defined(SERVICES) +#define FEATURESVALUES2 "b,k,l,imnpstrRD", feature_bool(FEAT_LOCAL_CHANNELS) ? "#&" : "#", "(qov).@+", ".@+" +#else +#define FEATURESVALUES2 "b,k,l,imnpstRD", feature_bool(FEAT_LOCAL_CHANNELS) ? "#&" : "#", "(ov)@+", "@+" +#endif #define FEATURESVALUES3 feature_int(FEAT_MAXCHANNELSPERUSER), feature_int(FEAT_MAXBANS), \ MAXTARGETS, MAXMODEPARAMS, feature_int(FEAT_MAXSILES), \ Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.26 ircd-ircdev/ircd/Makefile.in:1.27 --- ircd-ircdev/ircd/Makefile.in:1.26 Mon May 16 03:17:26 2005 +++ ircd-ircdev/ircd/Makefile.in Wed May 25 09:56:23 2005 @@ -18,7 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.26 2005/05/16 10:17:26 zolty Exp $ +# $Id: Makefile.in,v 1.27 2005/05/25 16:56:23 zolty Exp $ #### Start of system configuration section. #### @@ -95,6 +95,7 @@ ddb.c \ ddb_db_native.c \ ddb_events.c\ + m_bmode.c \ m_db.c \ m_dbq.c \ m_ghost.c \ Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.21 ircd-ircdev/ircd/channel.c:1.22 --- ircd-ircdev/ircd/channel.c:1.21 Mon May 16 04:22:50 2005 +++ ircd-ircdev/ircd/channel.c Wed May 25 09:56:24 2005 @@ -21,12 +21,13 @@ */ /** @file * @brief Channel management and maintanance - * @version $Id: channel.c,v 1.21 2005/05/16 11:22:50 zolty Exp $ + * @version $Id: channel.c,v 1.22 2005/05/25 16:56:24 zolty Exp $ */ #include "config.h" #include "channel.h" #include "client.h" +#include "ddb.h" #include "destruct_event.h" #include "hash.h" #include "ircd.h" @@ -272,6 +273,13 @@ schedule_destruct_event_1m(chptr); /* Get rid of it in approximately 4-5 minutes */ else schedule_destruct_event_48h(chptr); /* Get rid of it in approximately 48 hours */ + +#elif defined(DDB) + chptr->users = 0; + + if (!chptr->mode.mode & MODE_REGCHAN) + destruct_channel(chptr); + #else destruct_channel(chptr); #endif @@ -296,7 +304,9 @@ assert(0 == chptr->members); #if 0 -/* FIXME-ZOLTAN BORRAR!! ¿? */ +/* FIXME-ZOLTAN BORRAR!! + * Esto es listado de canales de /list, si se borra... se borra + * del list pendiente, pero parece ser que no es necesario ¿? */ /* Channel became (or was) empty: Remove channel */ if (is_listed(chptr)) { @@ -471,9 +481,7 @@ member->user = who; member->channel = chptr; member->status = flags; -#if defined(UNDERNET) member->oplevel = oplevel; -#endif member->next_member = chptr->members; if (member->next_member) @@ -600,6 +608,26 @@ remove_user_from_channel(cptr, chan->channel); } +#if defined(DDB) || defined(SERVICES) +/** Check if this user is a legitimate chan owner + * + * @param cptr Client to check + * @param chptr Channel to check + * + * @returns True if the user is a chan owner (And not a zombie), False otherwise. + * @see \ref zombie + */ +int is_chan_owner(struct Client *cptr, struct Channel *chptr) +{ + struct Membership* member; + assert(chptr); + if ((member = find_member_link(chptr, cptr))) + return (!IsZombie(member) && IsChanOwner(member)); + + return 0; +} +#endif /* defined(DDB) || defined(SERVICES) */ + /** Check if this user is a legitimate chanop * * @param cptr Client to check @@ -697,7 +725,6 @@ if (member->channel->mode.mode & MODE_MODERATED) return 0; #if defined(UNDERNET) - /* TODO */ /* If only logged in users may join and you're not one, you can't speak. */ if (member->channel->mode.mode & MODE_REGONLY && !IsAccount(member->user)) return 0; @@ -822,8 +849,12 @@ *mbuf++ = 'i'; if (chptr->mode.mode & MODE_NOPRIVMSGS) *mbuf++ = 'n'; - if (chptr->mode.mode & MODE_REGONLY) +#if defined(DDB) || defined(SERVICES) + if (chptr->mode.mode & MODE_REGCHAN) *mbuf++ = 'r'; +#endif + if (chptr->mode.mode & MODE_REGONLY) + *mbuf++ = 'R'; if (chptr->mode.mode & MODE_DELJOINS) *mbuf++ = 'D'; else if (MyUser(cptr) && (chptr->mode.mode & MODE_WASDELJOINS)) @@ -868,7 +899,6 @@ *mbuf = '\0'; } -#if defined(UNDERNET) /** Compare two members oplevel * * @param mp1 Pointer to a pointer to a membership @@ -886,7 +916,6 @@ return 0; return (member1->oplevel < member2->oplevel) ? -1 : 1; } -#endif /* UNDERNET */ /* send "cptr" a full list of the modes for channel chptr. * @@ -898,8 +927,20 @@ void send_channel_modes(struct Client *cptr, struct Channel *chptr) { /* The order in which modes are generated is now mandatory */ +#if defined(DDB) || defined(SERVICES) + static unsigned int current_flags[8] = + { 0, + CHFL_VOICE, + CHFL_CHANOP, + CHFL_CHANOP | CHFL_VOICE, + CHFL_OWNER, + CHFL_OWNER | CHFL_VOICE, + CHFL_OWNER | CHFL_CHANOP, + CHFL_OWNER | CHFL_CHANOP | CHFL_VOICE }; +#else static unsigned int current_flags[4] = { 0, CHFL_VOICE, CHFL_CHANOP, CHFL_CHANOP | CHFL_VOICE }; +#endif int first = 1; int full = 1; int flag_cnt = 0; @@ -1077,7 +1118,11 @@ } /* loop over 0,+v,+o,+ov */ #else /* !UNDERNET */ - for (first = 1; flag_cnt < 4; +#if defined(DDB) || defined(SERVICES) + for (first = 1; flag_cnt < 8; +#else + for (first = 1; flag_cnt < 4; +#endif member = chptr->members, new_mode = 1, flag_cnt++) { for (; member; member = member->next_member) @@ -1087,7 +1132,7 @@ current_flags[flag_cnt]) continue; /* Skip members with different flags */ if (msgq_bufleft(mb) < NUMNICKLEN + 4) - /* The 4 is a possible ",:ov" */ + /* The 5 is a possible ",:qov" */ { full = 1; /* Make sure we continue after sending it so far */ @@ -1106,9 +1151,13 @@ { new_mode = 0; if (IsVoicedOrOpped(member)) { - char tbuf[4] = ":"; + char tbuf[5] = ":"; int loc = 1; +#if defined(DDB) || defined(SERVICES) + if (IsChanOwner(member)) + tbuf[loc++] = 'q'; +#endif if (IsChanOp(member)) tbuf[loc++] = 'o'; if (HasVoice(member)) @@ -1354,10 +1403,13 @@ if (chptr->mode.limit && chptr->users >= chptr->mode.limit) return overrideJoin + ERR_CHANNELISFULL; + if ((chptr->mode.mode & MODE_REGONLY) && #if defined(UNDERNET) - if ((chptr->mode.mode & MODE_REGONLY) && !IsAccount(sptr)) - return overrideJoin + ERR_NEEDREGGEDNICK; + !IsAccount(sptr)) +#elif defined(DDB) || defined(SERVICES) + !IsNickRegistered(sptr)) #endif + return overrideJoin + ERR_NEEDREGGEDNICK; if (find_ban(sptr, chptr->banlist)) return overrideJoin + ERR_BANNEDFROMCHAN; @@ -1422,7 +1474,11 @@ return NULL; len = strlen(chname); +#if defined(DDB) + if ((!cptr || MyUser(cptr)) && len > CHANNELLEN) +#else if (MyUser(cptr) && len > CHANNELLEN) +#endif { len = CHANNELLEN; *(chname + CHANNELLEN) = '\0'; @@ -1440,7 +1496,11 @@ GlobalChannelList->prev = chptr; chptr->prev = NULL; chptr->next = GlobalChannelList; +#if defined(DDB) + chptr->creationtime = (!cptr || MyUser(cptr)) ? TStime() : (time_t) 0; +#else chptr->creationtime = MyUser(cptr) ? TStime() : (time_t) 0; +#endif GlobalChannelList = chptr; hAddChannel(chptr); } @@ -1689,9 +1749,13 @@ MODE_TOPICLIMIT, 't', MODE_INVITEONLY, 'i', MODE_NOPRIVMSGS, 'n', - MODE_REGONLY, 'r', - MODE_DELJOINS, 'D', - MODE_WASDELJOINS, 'd', +#if defined(DDB) || defined(SERVICES) + MODE_REGCHAN, 'r', +/* MODE_OWNER, 'q', */ +#endif + MODE_REGONLY, 'R', + MODE_DELJOINS, 'D', + MODE_WASDELJOINS, 'd', /* MODE_KEY, 'k', */ /* MODE_BAN, 'b', */ MODE_LIMIT, 'l', @@ -1764,13 +1828,36 @@ bufptr_i = &rembuf_i; } +#if defined(DDB) || defined(SERVICES) + if (MB_TYPE(mbuf, i) & (MODE_OWNER | MODE_CHANOP | MODE_VOICE)) { +#else if (MB_TYPE(mbuf, i) & (MODE_CHANOP | MODE_VOICE)) { +#endif tmp = strlen(cli_name(MB_CLIENT(mbuf, i))); if ((totalbuflen - IRCD_MAX(5, tmp)) <= 0) /* don't overflow buffer */ MB_TYPE(mbuf, i) |= MODE_SAVE; /* save for later */ else { - bufptr[(*bufptr_i)++] = MB_TYPE(mbuf, i) & MODE_CHANOP ? 'o' : 'v'; + char mode_char = 0; +#if defined(DDB) || defined(SERVICES) + switch(MB_TYPE(mbuf, i) & (MODE_OWNER | MODE_CHANOP | MODE_VOICE)) +#else + switch(MB_TYPE(mbuf, i) & (MODE_CHANOP | MODE_VOICE)) +#endif + { +#if defined(DDB) || defined(SERVICES) + case MODE_OWNER: + mode_char = 'q'; + break; +#endif + case MODE_CHANOP: + mode_char = 'o'; + break; + case MODE_VOICE: + mode_char = 'v'; + break; + } + bufptr[(*bufptr_i)++] = mode_char; totalbuflen -= IRCD_MAX(5, tmp) + 1; } #if defined(UNDERNET) @@ -1855,7 +1942,11 @@ } /* deal with clients... */ +#if defined(DDB) || defined(SERVICES) + if (MB_TYPE(mbuf, i) & (MODE_OWNER | MODE_CHANOP | MODE_VOICE)) +#else if (MB_TYPE(mbuf, i) & (MODE_CHANOP | MODE_VOICE)) +#endif build_string(strptr, strptr_i, cli_name(MB_CLIENT(mbuf, i)), 0, ' '); /* deal with bans... */ @@ -1919,10 +2010,21 @@ addbuf_i ? "+" : "", addbuf, remstr, addstr); if (mbuf->mb_dest & MODEBUF_DEST_CHANNEL) - sendcmdto_channel_butserv_butone(app_source, CMD_MODE, mbuf->mb_channel, NULL, 0, - "%H %s%s%s%s%s%s", mbuf->mb_channel, - rembuf_i ? "-" : "", rembuf, - addbuf_i ? "+" : "", addbuf, remstr, addstr); + { +#if defined(DDB) + if (mbuf->mb_dest & MODEBUF_DEST_BOTMODE) + sendcmdbotto_channel_butserv_butone(ddb_get_botname(mbuf->mb_botname), + CMD_MODE, mbuf->mb_channel, NULL, 0, + "%H %s%s%s%s%s%s", mbuf->mb_channel, + rembuf_i ? "-" : "", rembuf, + addbuf_i ? "+" : "", addbuf, remstr, addstr); + else +#endif /* defined(DDB) */ + sendcmdto_channel_butserv_butone(app_source, CMD_MODE, mbuf->mb_channel, NULL, 0, + "%H %s%s%s%s%s%s", mbuf->mb_channel, + rembuf_i ? "-" : "", rembuf, + addbuf_i ? "+" : "", addbuf, remstr, addstr); + } } /* Now are we supposed to propagate to other servers? */ @@ -1952,7 +2054,11 @@ } /* deal with modes that take clients */ +#if defined(DDB) || defined(SERVICES) + if (MB_TYPE(mbuf, i) & (MODE_OWNER | MODE_CHANOP | MODE_VOICE)) +#else if (MB_TYPE(mbuf, i) & (MODE_CHANOP | MODE_VOICE)) +#endif build_string(strptr, strptr_i, NumNick(MB_CLIENT(mbuf, i)), ' '); /* deal with modes that take strings */ @@ -1998,6 +2104,15 @@ mbuf->mb_channel, addbuf_i ? "-" : "", addbuf, rembuf_i ? "+" : "", rembuf, addstr, remstr, mbuf->mb_channel->creationtime); +#if defined(DDB) + } else if (mbuf->mb_dest & MODEBUF_DEST_BOTMODE) { + sendcmdto_serv_butone(mbuf->mb_source, CMD_BMODE, mbuf->mb_connect, + "%s %H %s%s%s%s%s%s %Tu", mbuf->mb_botname, mbuf->mb_channel, + rembuf_i ? "-" : "", rembuf, addbuf_i ? "+" : "", + addbuf, remstr, addstr, + (mbuf->mb_dest & MODEBUF_DEST_HACK4) ? 0 : + mbuf->mb_channel->creationtime); +#endif /* defined(DDB) */ } else { /* * We're propagating a normal MODE command to the rest of the network; @@ -2075,6 +2190,9 @@ mbuf->mb_source = source; mbuf->mb_connect = connect; mbuf->mb_channel = chan; +#if defined(DDB) + mbuf->mb_botname = 0; +#endif mbuf->mb_dest = dest; mbuf->mb_count = 0; @@ -2100,6 +2218,9 @@ mode &= (MODE_ADD | MODE_DEL | MODE_PRIVATE | MODE_SECRET | MODE_MODERATED | MODE_TOPICLIMIT | MODE_INVITEONLY | MODE_NOPRIVMSGS | MODE_REGONLY | +#if defined(DDB) || defined(SERVICES) +/* MODE_REGCHAN | */ +#endif MODE_DELJOINS | MODE_WASDELJOINS); if (!(mode & ~(MODE_ADD | MODE_DEL))) /* don't add empty modes... */ @@ -2245,8 +2366,12 @@ #endif /* MODE_BAN, 'b', */ MODE_LIMIT, 'l', - MODE_REGONLY, 'r', - MODE_DELJOINS, 'D', +#if defined(DDB) || defined(SERVICES) + MODE_REGCHAN, 'r', +/* MODE_OWNER, 'q', */ +#endif + MODE_REGONLY, 'R', + MODE_DELJOINS, 'D', 0x0, 0x0 }; unsigned int add; @@ -3205,12 +3330,20 @@ if (IsDelayedJoin(member)) RevealDelayedJoin(member); member->status |= (state->cli_change[i].flag & +#if defined(DDB) || defined(SERVICES) + (MODE_OWNER |MODE_CHANOP | MODE_VOICE)); +#else (MODE_CHANOP | MODE_VOICE)); +#endif if (state->cli_change[i].flag & MODE_CHANOP) ClearDeopped(member); } else member->status &= ~(state->cli_change[i].flag & +#if defined(DDB) || defined(SERVICES) + (MODE_OWNER | MODE_CHANOP | MODE_VOICE)); +#else (MODE_CHANOP | MODE_VOICE)); +#endif } /* accumulate the change */ @@ -3285,8 +3418,12 @@ #endif MODE_BAN, 'b', MODE_LIMIT, 'l', - MODE_REGONLY, 'r', - MODE_DELJOINS, 'D', +#if defined(DDB) || defined(SERVICES) + MODE_OWNER, 'q', + MODE_REGCHAN, 'r', +#endif + MODE_REGONLY, 'R', + MODE_DELJOINS, 'D', MODE_ADD, '+', MODE_DEL, '-', 0x0, 0x0 @@ -3373,6 +3510,21 @@ mode_parse_ban(&state, flag_p); break; +#if defined(DDB) || defined(SERVICES) +# if defined(DDB) + case 'r': + break; +# endif + case 'q': + if (!IsServer(cptr) || (state.dir == MODE_ADD && + !(mbuf->mb_dest & MODEBUF_DEST_BOTMODE))) + /* state.flags |= MODE_PARSE_NOTADD; */ + break; + + mode_parse_client(&state, flag_p); + break; +#endif + case 'o': /* deal with ops/voice */ case 'v': mode_parse_client(&state, flag_p); @@ -3570,6 +3722,11 @@ sendcmdto_serv_butone(jbuf->jb_source, CMD_JOIN, jbuf->jb_connect, "%u:%H %Tu", oplevel, chan, chan->creationtime); else +#elif defined(DDB) + if (flags & CHFL_OWNER) + sendcmdto_serv_butone(jbuf->jb_source, CMD_JOIN, jbuf->jb_connect, + "0:%H %Tu", chan, chan->creationtime); + else #endif sendcmdto_serv_butone(jbuf->jb_source, CMD_JOIN, jbuf->jb_connect, "%H %Tu", chan, chan->creationtime); @@ -3585,6 +3742,17 @@ sendcmdto_channel_butserv_butone((chan->mode.apass[0] ? &me : jbuf->jb_source), CMD_MODE, chan, NULL, 0, "%H +o %C", chan, jbuf->jb_source); +#elif defined(DDB) + if (flags & CHFL_OWNER) + { + char *botname = ddb_get_botname(DDB_CHANSERV); + + sendcmdbotto_channel_butserv_butone(botname, CMD_MODE, chan, NULL, 0, + "%H +q %C", chan, jbuf->jb_source); + } + else if (flags & CHFL_CHANOP) + sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan, NULL, 0, "%H +o %C", + chan, jbuf->jb_source); #else if (flags & CHFL_CHANOP) sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan, NULL, 0, "%H +o %C", Index: ircd-ircdev/ircd/ddb.c diff -u ircd-ircdev/ircd/ddb.c:1.9 ircd-ircdev/ircd/ddb.c:1.10 --- ircd-ircdev/ircd/ddb.c:1.9 Mon May 16 03:17:26 2005 +++ ircd-ircdev/ircd/ddb.c Wed May 25 09:56:24 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Implementation of Distributed DataBase. - * @version $Id: ddb.c,v 1.9 2005/05/16 10:17:26 zolty Exp $ + * @version $Id: ddb.c,v 1.10 2005/05/25 16:56:24 zolty Exp $ */ #include "config.h" @@ -202,6 +202,8 @@ * The lengths MUST be powers of 2 and do not have * to be superior to HASHSIZE. */ + ddb_resident_t... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-05-26 10:34:30
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-26 10:34:23 UTC Modified files: ChangeLog ChangeLog.es include/patchlevel.h ircd/channel.c ircd/ddb_events.c ircd/m_burst.c ircd/m_kick.c ircd/m_mode.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-05-26 Toni García <zo...@ir...> 1.0.alpha38 * Fix de bugs de la release anterior ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.39 ircd-ircdev/ChangeLog:1.40 --- ircd-ircdev/ChangeLog:1.39 Wed May 25 09:56:22 2005 +++ ircd-ircdev/ChangeLog Thu May 26 03:34:12 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.39 2005/05/25 16:56:22 zolty Exp $ +# $Id: ChangeLog,v 1.40 2005/05/26 10:34:12 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-05-26 Toni García <zo...@ir...> 1.0.alpha38 + * Fix bugs last release. + 2005-05-25 Toni García <zo...@ir...> 1.0.alpha37 * Registered channels (with mode +r) * Owner/founder mode (+q) Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.39 ircd-ircdev/ChangeLog.es:1.40 --- ircd-ircdev/ChangeLog.es:1.39 Wed May 25 09:56:22 2005 +++ ircd-ircdev/ChangeLog.es Thu May 26 03:34:13 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.39 2005/05/25 16:56:22 zolty Exp $ +# $Id: ChangeLog.es,v 1.40 2005/05/26 10:34:13 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-05-26 Toni García <zo...@ir...> 1.0.alpha38 + * Fix de bugs de la release anterior + 2005-05-25 Toni García <zo...@ir...> 1.0.alpha37 * Canales registrados (con modo +r) * Modo owner/founder (+q) Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.38 ircd-ircdev/include/patchlevel.h:1.39 --- ircd-ircdev/include/patchlevel.h:1.38 Wed May 25 09:56:23 2005 +++ ircd-ircdev/include/patchlevel.h Thu May 26 03:34:13 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.38 2005/05/25 16:56:23 zolty Exp $ + * $Id: patchlevel.h,v 1.39 2005/05/26 10:34:13 zolty Exp $ * */ -#define PATCHLEVEL ".alpha37" +#define PATCHLEVEL ".alpha38" #define RELEASE "1.0" Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.22 ircd-ircdev/ircd/channel.c:1.23 --- ircd-ircdev/ircd/channel.c:1.22 Wed May 25 09:56:24 2005 +++ ircd-ircdev/ircd/channel.c Thu May 26 03:34:13 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Channel management and maintanance - * @version $Id: channel.c,v 1.22 2005/05/25 16:56:24 zolty Exp $ + * @version $Id: channel.c,v 1.23 2005/05/26 10:34:13 zolty Exp $ */ #include "config.h" @@ -230,10 +230,10 @@ * * @param chptr The channel to subtract one from. * - * defined(UNDERNET) + * defined(UNDERNET) || defined(DDB) * @returns true (1) if channel still has members. * false (0) if the channel is now empty. - * !defined(UNDERNET) + * else * Returns: true (1) if channel still exists * false (0) if the channel was destroyed */ @@ -277,7 +277,7 @@ #elif defined(DDB) chptr->users = 0; - if (!chptr->mode.mode & MODE_REGCHAN) + if (!(chptr->mode.mode & MODE_REGCHAN)) destruct_channel(chptr); #else @@ -303,28 +303,6 @@ assert(0 == chptr->members); -#if 0 -/* FIXME-ZOLTAN BORRAR!! - * Esto es listado de canales de /list, si se borra... se borra - * del list pendiente, pero parece ser que no es necesario ¿? */ - /* Channel became (or was) empty: Remove channel */ - if (is_listed(chptr)) - { - int i; - for (i = 0; i <= HighestFd; i++) - { - struct Client *acptr = 0; - if ((acptr = LocalClientArray[i]) && cli_listing(acptr) && - (cli_listing(acptr))->chptr == chptr) - { - list_next_channels(acptr, 1); - break; /* Only one client can list a channel */ - } - } - } -*/ -#endif - /* * Now, find all invite links from channel structure */ Index: ircd-ircdev/ircd/ddb_events.c diff -u ircd-ircdev/ircd/ddb_events.c:1.5 ircd-ircdev/ircd/ddb_events.c:1.6 --- ircd-ircdev/ircd/ddb_events.c:1.5 Wed May 25 09:56:24 2005 +++ ircd-ircdev/ircd/ddb_events.c Thu May 26 03:34:13 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Events of Distributed DataBases. - * @version $Id: ddb_events.c,v 1.5 2005/05/25 16:56:24 zolty Exp $ + * @version $Id: ddb_events.c,v 1.6 2005/05/26 10:34:13 zolty Exp $ */ #include "config.h" @@ -78,9 +78,12 @@ { struct Channel *chptr; struct Client *founder; - char *botname = &me; - -// botname = ddb_get_botname(DDB_CHANSERV); + char *botname; + + if (ddb_count_table[DDB_CONFIGDB]) + botname = ddb_get_botname(DDB_CHANSERV); + else + botname = cli_name(&me); if (content) { Index: ircd-ircdev/ircd/m_burst.c diff -u ircd-ircdev/ircd/m_burst.c:1.10 ircd-ircdev/ircd/m_burst.c:1.11 --- ircd-ircdev/ircd/m_burst.c:1.10 Mon Apr 11 01:45:00 2005 +++ ircd-ircdev/ircd/m_burst.c Thu May 26 03:34:13 2005 @@ -19,7 +19,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: m_burst.c,v 1.10 2005/04/11 08:45:00 zolty Exp $ + * $Id: m_burst.c,v 1.11 2005/05/26 10:34:13 zolty Exp $ * */ @@ -125,7 +125,7 @@ case 'l': ++parv; break; - case 'r': + case 'R': result |= MODE_REGONLY; break; } @@ -263,6 +263,8 @@ && (!(check_modes & MODE_INVITEONLY) || IsAnOper(member->user)) #if defined(UNDERNET) && (!(check_modes & MODE_REGONLY) || IsAccount(member->user))) +#elif defined (DDB) || defined(SERVICES) + && (!(check_modes & MODE_REGONLY) || IsNickRegistered(member->user))) #else ) #endif @@ -479,7 +481,13 @@ #else for (current_mode = base_mode; *ptr; ptr++) { +#if defined(DDB) || defined(SERVICES) + if (*ptr == 'q') /* has owner status */ + current_mode = (current_mode & ~(CHFL_DEOPPED | CHFL_DELAYED)) | CHFL_OWNER; + else if (*ptr == 'o') /* has oper status */ +#else if (*ptr == 'o') /* has oper status */ +#endif current_mode = (current_mode & ~(CHFL_DEOPPED | CHFL_DELAYED)) | CHFL_CHANOP; else if (*ptr == 'v') /* has voice status */ current_mode = (current_mode & ~CHFL_DELAYED) | CHFL_VOICE; @@ -544,6 +552,10 @@ #else nickstr[nickpos++] = ':'; /* add a specifier */ +#if defined(DDB) || defined(SERVICES) + if (current_mode & CHFL_OWNER) + nickstr[nickpos++] = 'q'; +#endif if (current_mode & CHFL_CHANOP) nickstr[nickpos++] = 'o'; if (current_mode & CHFL_VOICE) @@ -580,6 +592,10 @@ /* first deal with channel members */ for (member = chptr->members; member; member = member->next_member) { if (member->status & CHFL_BURST_JOINED) { /* joined during burst */ +#if defined(DDB) || defined(SERVICES) + if (member->status & CHFL_OWNER) + modebuf_mode_client(mbuf, MODE_ADD | CHFL_OWNER, member->user); +#endif #if defined(UNDERNET) if ((member->status & CHFL_CHANOP) && !(member->status & CHFL_BURST_ALREADY_OPPED)) #else @@ -600,6 +616,8 @@ member->status = (member->status #if defined(UNDERNET) & ~(CHFL_CHANNEL_MANAGER | CHFL_CHANOP | CHFL_VOICE)) +#elif defined(DDB) || defined(SERVICES) + & ~(CHFL_OWNER | CHFL_CHANOP | CHFL_VOICE)) #else & ~(CHFL_CHANOP | CHFL_VOICE)) #endif Index: ircd-ircdev/ircd/m_kick.c diff -u ircd-ircdev/ircd/m_kick.c:1.9 ircd-ircdev/ircd/m_kick.c:1.10 --- ircd-ircdev/ircd/m_kick.c:1.9 Wed May 25 09:56:24 2005 +++ ircd-ircdev/ircd/m_kick.c Thu May 26 03:34:13 2005 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: m_kick.c,v 1.9 2005/05/25 16:56:24 zolty Exp $ + * $Id: m_kick.c,v 1.10 2005/05/26 10:34:13 zolty Exp $ * */ @@ -124,7 +124,7 @@ #if defined(DDB) || defined(SERVICES) if (!(member2 = find_member_link(chptr, sptr)) || IsZombie(member2) - || !(IsChanOp(member2) || IsChanOwner(member2))) + || !(IsChanOwner(member2) || IsChanOp(member2))) #else if (!(member2 = find_member_link(chptr, sptr)) || IsZombie(member2) || !IsChanOp(member2)) @@ -227,8 +227,13 @@ * here), if kicker is not on channel, or if kicker is not a channel * operator, bounce the kick */ +#if defined(DDB) || defined(SERVICES) + if (!IsServer(sptr) && member && cli_from(who) != cptr && !IsService(cli_user(sptr)->server) && + (!(sptr_link = find_member_link(chptr, sptr)) || !(IsChanOwner(sptr_link) || IsChanOp(sptr_link)))) { +#else if (!IsServer(sptr) && member && cli_from(who) != cptr && (!(sptr_link = find_member_link(chptr, sptr)) || !IsChanOp(sptr_link))) { +#endif sendto_opmask_butone(0, SNO_HACK2, "HACK: %C KICK %H %C %s", sptr, chptr, who, comment); Index: ircd-ircdev/ircd/m_mode.c diff -u ircd-ircdev/ircd/m_mode.c:1.7 ircd-ircdev/ircd/m_mode.c:1.8 --- ircd-ircdev/ircd/m_mode.c:1.7 Wed May 25 09:56:24 2005 +++ ircd-ircdev/ircd/m_mode.c Thu May 26 03:34:13 2005 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: m_mode.c,v 1.7 2005/05/25 16:56:24 zolty Exp $ + * $Id: m_mode.c,v 1.8 2005/05/26 10:34:13 zolty Exp $ * */ @@ -205,7 +205,16 @@ NULL); } else { #if defined(DDB) || defined(SERVICES) - if (!(member = find_member_link(chptr, sptr)) || !(IsChanOwner(member) + if (IsService(cli_user(sptr)->server)) { + modebuf_init(&mbuf, sptr, cptr, chptr, + (MODEBUF_DEST_CHANNEL | /* Send mode to clients */ + MODEBUF_DEST_SERVER)); /* Send mode to servers */ + mode_parse(&mbuf, cptr, sptr, chptr, parc - 2, parv + 2, + (MODE_PARSE_SET | /* Set the mode */ + MODE_PARSE_STRICT | /* Interpret it strictly */ + MODE_PARSE_FORCE), /* And force it to be accepted */ + NULL); + } else if (!(member = find_member_link(chptr, sptr)) || !(IsChanOwner(member) || IsChanOp(member))) { #else if (!(member = find_member_link(chptr, sptr)) || !IsChanOp(member)) { ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-05-26 12:46:18
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-26 12:46:07 UTC Modified files: TODO.es Log message: Actualizacion TODO ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.25 ircd-ircdev/TODO.es:1.26 --- ircd-ircdev/TODO.es:1.25 Mon May 23 01:53:04 2005 +++ ircd-ircdev/TODO.es Thu May 26 05:45:57 2005 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.25 2005/05/23 08:53:04 zolty Exp $ +# $Id: TODO.es,v 1.26 2005/05/26 12:45:57 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -63,6 +63,8 @@ - [G] Mirar el tema de control de Ilines por rangos, el tema es que con un /64 actualmente deja X clones para cada IP de ese rango, deberia haber alguna forma de que sea por rango. + - [D] Soporte de levels, mlock, topic, entrymsg de canales en la DDB. + - [G] Modo HalfOp (+h). [18:11:32] <Tor> quote opmode torcum #opers,#lala [18:11:38] <Tor> quote opmode #opers +nk lalala @@ -232,5 +234,4 @@ * Default: "ntCN" AUTOCHANMODES_LIST should contain the default channelmodes (e.g. -"ntCN") which will - be set by default on new channels. +"ntCN") which will be set by default on new channels. ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-05-26 15:50:14
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-26 15:50:06 UTC Modified files: TODO.es Log message: Actualizacion TODO ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.26 ircd-ircdev/TODO.es:1.27 --- ircd-ircdev/TODO.es:1.26 Thu May 26 05:45:57 2005 +++ ircd-ircdev/TODO.es Thu May 26 08:49:56 2005 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.26 2005/05/26 12:45:57 zolty Exp $ +# $Id: TODO.es,v 1.27 2005/05/26 15:49:56 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -22,14 +22,14 @@ notices de auth y dnslookup al conectar. - [D] Virtualhost personalizado a traves de la DDB. - [D] U-lines a traves de la DDB. + - [D] Mejorar la inicializacion de las DDB con los eventos. PRIORIDAD MEDIA -------------------------------------------------------------------------------------- - [D] DDB: compactado. - [G] Caracter '~' en los nicks. - - [G] Los clientes con +k han de poder "hablar" en canales. - - [G] Mostrar tiempo en formato humano en las G-lines. + - [G] Mostrar tiempo en formato humano en las G-lines y Jupes. - [G] Enviar un Closing Link en los QUIT. - [G] Cuando nos silencian, que salga un numerico. - [G] Estudiar sobre la conveniencia de mandar privmsg globales al nick en vez de a @@ -100,6 +100,9 @@ 15/Mar/2005 - [G] Bajo en ciertas circunstancias desconocidas del ircd.conf no pueden entrar clientes al IRCD. Investigar eso. +26/May/2005 + - [D] Los cambios de modos en canal, a veces hay desyncs. Investigar el origen + - [D] Antes de un netjoin, un /mode #canal mostraba +r, despues ya no. Leyenda: [G] General ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-05-31 11:11:22
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-05-31 11:11:12 UTC Modified files: ircd/test/Makefile.in ircd/test/channel-1.cmd ircd/test/client-1.cmd ircd/test/gline-1.cmd ircd/test/ircd-t1.conf ircd/test/run-tests.sh ircd/test/stats-1.cmd ircd/test/test-driver.pl ircd/test/test_stub.c Added files: ircd/test/commands-1.cmd ircd/test/feature-1.cmd ircd/test/ircd-t1-2.conf ircd/test/ircd-t2.conf ircd/test/ircd_match_t.c ircd/test/jupe-1.cmd ircd/test/kill-block-1.cmd Log message: Nuevos tests ---------------------- diff included ---------------------- Index: ircd-ircdev/ircd/test/Makefile.in diff -u ircd-ircdev/ircd/test/Makefile.in:1.3 ircd-ircdev/ircd/test/Makefile.in:1.4 --- ircd-ircdev/ircd/test/Makefile.in:1.3 Wed Jan 26 09:19:48 2005 +++ ircd-ircdev/ircd/test/Makefile.in Tue May 31 04:10:52 2005 @@ -18,7 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.3 2005/01/26 17:19:48 zolty Exp $ +# $Id: Makefile.in,v 1.4 2005/05/31 11:10:52 zolty Exp $ top_srcdir = @top_srcdir@ srcdir = @srcdir@ @@ -29,12 +29,14 @@ TESTPROGS = \ ircd_chattr_t \ - ircd_string_t \ ircd_in_addr_t + ircd_match_t \ + ircd_string_t DEP_SRC = \ ircd_chattr_t.c \ ircd_in_addr_t.c \ + ircd_match_t.c \ ircd_string_t.c \ test_stub.c @@ -56,15 +58,19 @@ IRCD_CHATTR_T_OBJS = ircd_chattr_t.o test_stub.o ../ircd_string.o ircd_chattr_t: $(IRCD_CHATTR_T_OBJS) - ${CC} -o $@ $(IRCD_CHATTR_T_OBJS) - -IRCD_STRING_T_OBJS = ircd_string_t.o test_stub.o ../ircd_string.o -ircd_string_t: $(IRCD_STRING_T_OBJS) - ${CC} -o $@ $(IRCD_STRING_T_OBJS) + ${CC} -o $@ $(LDFLAGS) $(IRCD_CHATTR_T_OBJS) IRCD_IN_ADDR_T_OBJS = ircd_in_addr_t.o test_stub.o ../ircd_alloc.o ../ircd_string.o ../match.o ../numnicks.o ircd_in_addr_t: $(IRCD_IN_ADDR_T_OBJS) - ${CC} -o $@ $(IRCD_IN_ADDR_T_OBJS) + ${CC} -o $@ $(LDFLAGS) $(IRCD_IN_ADDR_T_OBJS) + +IRCD_MATCH_T_OBJS = ircd_match_t.o test_stub.o ../ircd_string.o ../match.o +ircd_match_t: $(IRCD_MATCH_T_OBJS) + ${CC} -o $@ $(LDFLAGS) $(IRCD_MATCH_T_OBJS) + +IRCD_STRING_T_OBJS = ircd_string_t.o test_stub.o ../ircd_string.o +ircd_string_t: $(IRCD_STRING_T_OBJS) + ${CC} -o $@ $(LDFLAGS) $(IRCD_STRING_T_OBJS) .c.o: ${CC} ${CFLAGS} ${CPPFLAGS} -c $< -o $@ Index: ircd-ircdev/ircd/test/channel-1.cmd diff -u ircd-ircdev/ircd/test/channel-1.cmd:1.1 ircd-ircdev/ircd/test/channel-1.cmd:1.2 --- ircd-ircdev/ircd/test/channel-1.cmd:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/channel-1.cmd Tue May 31 04:11:01 2005 @@ -1,29 +1,50 @@ -define srv localhost:7701 +define srv localhost -connect cl1 Alex alex %srv% :Test client 1 -connect cl2 Bubb bubb %srv% :Test client 2 +connect cl1 Alex alex %srv%:7701 :Test client 1 +connect cl2 Bubb bubb %srv%:7711 :Test client 2 :cl1 join #test :cl1 join #test2 :cl1 mode #test +bb *!*@127.0.0.1 *!*@127.0.0.2 :cl2 wait cl1 -:cl2 join #test -:cl1 wait cl2 +:cl2 raw :away :I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. I'm not here, go away. +:cl2 raw :away :I'm not here, go away. +:cl2 join #test,#test3,#test4,+local +:cl1 wait cl2 +:cl1 join #test3 +:cl1 raw :invite Bubb +:cl1 raw :invite #test +:cl1 invite Bubb #non-existent-channel +:cl1 invite Bubb #test3 +:cl1 invite Bubb #test4 :cl1 invite Bubb #test :cl2 expect *cl1 invite #test +:cl2 mode #test3 +o Alex +:cl2 raw :invite :cl2 join #test :cl2 privmsg #test :Hello, *cl1. +:cl2 notice #test :Hello, *cl1 (via notice). +:cl2 notice @#test :Hello, *cl1 (via wallchops). +:cl2 privmsg #test5 :Hello, *cl1. :cl2 nick Buba :cl2 mode #test +l 15 :cl1 wait cl2 :cl1 privmsg #test :Hello, *cl2. +:cl1 raw :cprivmsg bubb #test :Hello, bubb. +:cl1 raw :cnotice bubb #test :Hello, bubb. :cl1 mode #test -b+kv *!*@127.0.0.1 secret Bubb :cl1 mode #test +b foo!bar@baz :cl1 mode #test +b :cl1 mode #test : :cl1 mode #test -:cl1 raw who #test %lfuh +:cl1 raw :names +:cl1 raw :names #test +:cl1 raw :names +local +:cl1 raw :names +local test-2.* +:cl1 raw :who #test %lfuh :cl2 wait cl1 +:cl2 raw :part :cl2 part #test +:cl2 part #test5 :cl1 wait cl2 :cl2 join #test public :cl2 join #test secret @@ -45,4 +66,9 @@ :cl2 wait cl1 :cl2 mode #test2 -D :cl2 mode #test +v Alex +:cl1 raw :kick #test bubb +:cl2 raw :squit test-1.* +:cl2 sleep 1 +:cl2 raw :connect test-1.* +:cl2 raw :away : :cl1 wait cl2 Index: ircd-ircdev/ircd/test/client-1.cmd diff -u ircd-ircdev/ircd/test/client-1.cmd:1.1 ircd-ircdev/ircd/test/client-1.cmd:1.2 --- ircd-ircdev/ircd/test/client-1.cmd:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/client-1.cmd Tue May 31 04:11:01 2005 @@ -1,9 +1,12 @@ -define srv localhost:7701 +define srv localhost -connect cl1 Alex alex %srv% :Test client 1 +connect cl1 Alex alex %srv%:7701 :Test client 1 :cl1 oper oper1 oper1 -connect cl2 Bubb bubb %srv% :Test client 2 +:cl1 oper oper1 oper1 +connect cl2 Bubb bubb %srv%:7711 :Test client 2 +:cl1 raw :time :cl2 oper oper3 oper4 +:cl1 raw :version :cl2 oper oldoper wrongpass :cl2 oper md5oper wrongpass :cl2 oper cryptoper wrongpass @@ -13,3 +16,10 @@ :cl1 raw :privs Bubb :cl1 nick A :cl1 nick Alexey +:cl1 raw :privmsg : +:cl1 raw :privmsg Alexey : +:cl1 raw :privmsg Bubb :hello Bubb +:cl1 raw :privmsg $*.net :Hello all *.net servers. +:cl1 raw :notice $*.net :Hello all *.net servers. +:cl1 raw :kill Bubb :goodbye Bubb +:cl1 raw :whowas Alex,Bubb 5 Index: ircd-ircdev/ircd/test/commands-1.cmd diff -u /dev/null ircd-ircdev/ircd/test/commands-1.cmd:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/commands-1.cmd Tue May 31 04:11:01 2005 @@ -0,0 +1,43 @@ +define srv localhost:7701 + +connect cl1 Alex alex %srv% :Test client 1 +connect cl2 Bubb bubb %srv% :Test client 2 +:cl1 raw :help +:cl1 raw :admin +:cl1 raw :admin test-2.* +:cl1 raw :info +:cl1 raw :wallops :HELLO OPERZ!!! +:cl1 wait cl2 +:cl1 raw :ison alex,bubb,alex,bubb,alex,bubb +:cl1 raw :who b*b +:cl1 raw :burst the bubble +:cl1 raw :server huh huh i'm a server +:cl1 raw :links +:cl1 raw :map +:cl1 raw :nick +:cl1 raw :nick ~ +:cl1 raw :nick -dude- +:cl1 raw :nick alex +:cl1 raw :nick Bubb +:cl1 raw :ping alex test-1.* + +:cl1 oper oper1 oper1 +:cl1 raw :admin +:cl1 raw :admin test-2.* +:cl1 raw :asll +:cl1 raw :asll test-2.* +:cl1 raw :info +:cl1 raw :info test-2.* +:cl1 raw :who x b*b +:cl1 raw :close +:cl1 raw :map +:cl1 raw :links +:cl1 raw :links test-2.* +:cl1 raw :lusers +:cl1 raw :lusers test-2.* +:cl1 raw :motd +:cl1 raw :motd test-2.* +:cl1 raw :ping alex test-2.* +:cl1 raw :rping test-2.* + +:cl2 raw :quit Index: ircd-ircdev/ircd/test/feature-1.cmd diff -u /dev/null ircd-ircdev/ircd/test/feature-1.cmd:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/feature-1.cmd Tue May 31 04:11:01 2005 @@ -0,0 +1,18 @@ +define srv localhost:7701 + +connect cl1 Alex alex %srv% :Test client 1 +:cl1 oper oper1 oper1 +:cl1 raw :GET LOG +:cl1 raw :RESET LOG +:cl1 raw :GET RANDOM_SEED +:cl1 raw :SET RANDOM_SEED +:cl1 raw :SET RANDOM_SEED abcdefghijklmnop +:cl1 raw :GET DEFAULT_LIST_PARAM +:cl1 raw :SET DEFAULT_LIST_PARAM FALSE +:cl1 raw :SET DEFAULT_LIST_PARAM TRUE +:cl1 nick Alexey +:cl1 nick Amdahl +:cl1 nick Andy +:cl1 nick Aon +:cl1 nick Apple +:cl1 raw :SET NICKNAMEHISTORYLENGTH 4 Index: ircd-ircdev/ircd/test/gline-1.cmd diff -u ircd-ircdev/ircd/test/gline-1.cmd:1.1 ircd-ircdev/ircd/test/gline-1.cmd:1.2 --- ircd-ircdev/ircd/test/gline-1.cmd:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/gline-1.cmd Tue May 31 04:11:01 2005 @@ -7,6 +7,9 @@ :cl1 raw :gline !+127.2.* 3600 :Localclone? :cl1 sleep 5 :cl1 raw :gline !+127.2.* 3600 :Localclone? +:cl1 raw :gline !+127.2.*/15 3600 :Localclone? +:cl1 raw :gline !+127.2.0.0/33 3600 :Localclone? +:cl1 raw :gline !+127.2.0.0/15 3600 :Localclone? connect cl2 Bubb bubb %srv% :Test client 2 :cl1 raw :gline :cl1 raw :gline $Rbubb Index: ircd-ircdev/ircd/test/ircd-t1-2.conf diff -u /dev/null ircd-ircdev/ircd/test/ircd-t1-2.conf:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/ircd-t1-2.conf Tue May 31 04:11:01 2005 @@ -0,0 +1,93 @@ +General { + name = "test-1.example.net"; + vhost = "127.0.0.1"; + vhost = "::1"; + description = "Test Server 1"; + numeric = 1; +}; + +Admin { + location = "Somewhere"; + contact = "Someone"; +}; + +Class { + name = "Server"; + pingfreq = 180 seconds; + connectfreq = 300 seconds; + maxlinks = 1; + sendq = 9000000; +}; + +Class { + name = "others"; + pingfreq = 180 seconds; + sendq = 160000; + maxlinks = 100; + usermode = "+oiwx"; +}; + +Class { + name = "Opers"; + pingfreq = 180 seconds; + sendq = 160000; + maxlinks = 10; + local = no; +}; + +Connect { + name = "bogus.example.net"; + host = "example.net"; + password = "bogus_example"; + port = 7700; + class = "Server"; + maxhops = 2; + hub = "*.example.net"; + autoconnect = yes; # forces a DNS resolution attempt +}; + +CRule { + server = "bogus.example.net"; + all = yes; + rule = "connected(*)"; +}; + +CRule { + server = "bogus.example.net"; + all = no; + rule = "directcon(*)"; +}; + +UWorld { + name = "uworld.example.net"; + name = "uworld2.example.net"; +}; + +Jupe { + nick = "A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q"; + nick = "R,S,T,U,V,W,X,Y,Z,{,|,},~,-,_,`"; +}; + +Operator { name = "oper1"; host = "*@*"; password = "$PLAIN$oper1"; class = "Opers"; }; +Operator { name = "oper2"; host = "*@*"; password = "$PLAIN$oper2"; class = "Opers"; local = yes; }; +Operator { name = "oldoper"; host = "*@*"; password = "Xlfc26b4eYGWs"; class = "Opers"; }; +Operator { name = "md5oper"; host = "*@*"; password = "$SMD5$2O$4O.rSAmhE4Fg05MmG.047/"; class = "Opers"; }; +Operator { name = "cryptoper"; host = "*@*"; password = "$CRYPT$41ndrxPQu3B66"; class = "Opers"; }; + +Kill { username = "sub7"; realname = "s*7*"; reason = "You are infected with a Trojan"; }; +Kill { realname = "Chloe"; reason = "drones"; }; +Kill { username = "sub7"; reason = "You are infected with a Trojan"; }; + +Client { class = "others"; ip = "*"; }; + +Port { server = yes; port = 7700; }; +Port { server = no; port = 7702; }; + +Quarantine { + "#shells" = "Thou shalt not support the h4><0rz"; +}; + +Features { + "HIS_STATS_k" = "FALSE"; + "PPATH" = "ircd-t1.pid"; +}; Index: ircd-ircdev/ircd/test/ircd-t1.conf diff -u ircd-ircdev/ircd/test/ircd-t1.conf:1.1 ircd-ircdev/ircd/test/ircd-t1.conf:1.2 --- ircd-ircdev/ircd/test/ircd-t1.conf:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/ircd-t1.conf Tue May 31 04:11:01 2005 @@ -46,6 +46,15 @@ autoconnect = yes; # forces a DNS resolution attempt }; +Connect { + name = "test-2.example.net"; + host = "::1"; + password = "bogus_example"; + port = 7710; + class = "Server"; + autoconnect = no; +}; + CRule { server = "bogus.example.net"; all = yes; @@ -94,4 +103,5 @@ Features { "HIS_STATS_k" = "FALSE"; + "PPATH" = "ircd-t1.pid"; }; Index: ircd-ircdev/ircd/test/ircd-t2.conf diff -u /dev/null ircd-ircdev/ircd/test/ircd-t2.conf:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/ircd-t2.conf Tue May 31 04:11:01 2005 @@ -0,0 +1,95 @@ +General { + name = "test-2.example.net"; + vhost = "127.0.0.1"; + vhost = "::1"; + description = "Test Server 2"; + numeric = 2; +}; + +Admin { + location = "Somewhere"; + contact = "Someone"; +}; + +Class { + name = "Server"; + pingfreq = 180 seconds; + connectfreq = 300 seconds; + maxlinks = 1; + sendq = 9000000; +}; + +Class { + name = "others"; + pingfreq = 180 seconds; + sendq = 160000; + maxlinks = 100; + usermode = "+oiwx"; +}; + +Class { + name = "Opers"; + pingfreq = 180 seconds; + sendq = 160000; + maxlinks = 10; + local = no; +}; + +Connect { + name = "test-1.example.net"; + host = "::1"; + password = "bogus_example"; + port = 7700; + class = "Server"; + maxhops = 2; + hub = "*.example.net"; + autoconnect = yes; +}; + +CRule { + server = "bogus.example.net"; + all = yes; + rule = "connected(*)"; +}; + +CRule { + server = "bogus.example.net"; + all = no; + rule = "directcon(*)"; +}; + +UWorld { + name = "uworld.example.net"; + name = "uworld2.example.net"; +}; + +Jupe { + nick = "A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q"; + nick = "R,S,T,U,V,W,X,Y,Z,{,|,},~,-,_,`"; +}; + +Operator { name = "oper1"; host = "*@*"; password = "$PLAIN$oper1"; class = "Opers"; }; +Operator { name = "oper2"; host = "*@*"; password = "$PLAIN$oper2"; class = "Opers"; local = yes; }; + +Kill { realname = "Chloe"; reason = "drones"; }; +Kill { username = "sub7"; reason = "You are infected with a Trojan"; }; + +Client { class = "others"; ip = "*"; }; + +Port { server = yes; port = 7710; }; +Port { server = no; port = 7711; mask = "127.0.0.0/8"; }; + +Quarantine { + "#shells" = "Thou shalt not support the h4><0rz"; +}; + +Pseudo "X" { + name = "X"; + nick = "X...@ch..."; +}; + +Features { + "PPATH" = "ircd-t2.pid"; + "LOG" = "SYSTEM" "FILE" "ircd-t2.log"; + "LOG" = "SYSTEM" "LEVEL" "NOTICE"; +}; Index: ircd-ircdev/ircd/test/ircd_match_t.c diff -u /dev/null ircd-ircdev/ircd/test/ircd_match_t.c:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/ircd_match_t.c Tue May 31 04:11:01 2005 @@ -0,0 +1,74 @@ +/* + * ircd_match_t.c - test cases for irc glob matching + */ + +#include "ircd_log.h" +#include "match.h" +#include <stdio.h> +#include <string.h> + +struct match_test { + const char *glob; + const char *should_match; + const char *shouldnt_match; +}; + +const struct match_test match_tests[] = { + { "\\*", + "*\0", + "a\0*PeacefuL*\0" }, + { "*a*", + "a\0pizza\0abe\0brack\0", + "b\0" }, + { "?", + "*\0a\0?\0", + "*PeacefuL*\0pizza\0???\0" }, + { "abc", + "abc\0", + "abcd\0cabc\0" }, + { "*abc", + "abc\0fooabc\0ababc\0", + "abra\0abcd\0" }, + { "\\?", + "?\0", + "a\0" }, + { NULL, NULL, NULL } +}; + +void do_match_test(const struct match_test *test) +{ + const char *candidate; + unsigned int matched, not_matched; + int res; + + for (candidate = test->should_match, matched = 0; + *candidate; + candidate += strlen(candidate) + 1, ++matched) { + res = match(test->glob, candidate); + if (res != 0) { + fprintf(stderr, "\"%s\" failed to match \"%s\".\n", test->glob, candidate); + assert(0); + } + } + + for (candidate = test->shouldnt_match, not_matched = 0; + *candidate; + candidate += strlen(candidate) + 1, ++not_matched) { + res = match(test->glob, candidate); + if (res == 0) { + fprintf(stderr, "\"%s\" incorrectly matched \"%s\".\n", test->glob, candidate); + assert(0); + } + } + + printf("Passed: %s (%u matches, %u non-matches)\n", + test->glob, matched, not_matched); +} + +int main(int argc, char *argv[]) +{ + const struct match_test *match; + for (match = match_tests; match->glob; ++match) + do_match_test(match); + return 0; +} Index: ircd-ircdev/ircd/test/jupe-1.cmd diff -u /dev/null ircd-ircdev/ircd/test/jupe-1.cmd:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/jupe-1.cmd Tue May 31 04:11:01 2005 @@ -0,0 +1,8 @@ +define srv localhost:7701 + +connect cl1 Alex alex %srv% :Test client 1 +:cl1 oper oper1 oper1 +:cl1 raw :jupe +irc-3.example.net 3600 :Server 3 not welcome here. +:cl1 raw :jupe -irc-3.example.net 3600 :Server 3 not welcome here. +:cl1 raw :jupe +irc-3.example.net * 3600 :Server 3 not welcome here. +:cl1 raw :jupe -irc-3.example.net * 3600 :Server 3 not welcome here. Index: ircd-ircdev/ircd/test/kill-block-1.cmd diff -u /dev/null ircd-ircdev/ircd/test/kill-block-1.cmd:1.1 --- /dev/null Tue May 31 04:11:12 2005 +++ ircd-ircdev/ircd/test/kill-block-1.cmd Tue May 31 04:11:01 2005 @@ -0,0 +1,4 @@ +define srv localhost:7701 + +connect cl1 Alex sub7 %srv% :s7server +connect cl2 Chloe chloe %srv% :Chloe Index: ircd-ircdev/ircd/test/run-tests.sh diff -u ircd-ircdev/ircd/test/run-tests.sh:1.1 ircd-ircdev/ircd/test/run-tests.sh:1.2 --- ircd-ircdev/ircd/test/run-tests.sh:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/run-tests.sh Tue May 31 04:11:01 2005 @@ -1,12 +1,27 @@ #! /bin/sh set -e srcdir=$1 -for script in channel-1 client-1 stats-1 gline-1 ; do +cp ${srcdir}/ircd-t1.conf ircd-t1.conf +cp ${srcdir}/ircd-t2.conf ircd-t2.conf +echo "Testing one-shot ircd invocations." +../ircd -v +../ircd -x 6 -k -d . -f ircd-t1.conf -c user@127.0.0.1 +echo "Starting ircd." +../ircd -d . -f ircd-t1.conf +../ircd -d . -f ircd-t2.conf +sleep 10 +# stats-1 is out of alphabetical order to avoid triggering IPcheck. +for script in channel-1 client-1 command-1 feature-1 gline-1 stats-1 jupe-1 kill-block-1 ; do echo "Running test $script." ${srcdir}/test-driver.pl ${srcdir}/${script}.cmd done -echo "Terminating server." -${srcdir}/test-driver.pl ${srcdir}/die.cmd -../ircd -? -../ircd -v -../ircd -x 6 -k -d ${srcdir} -f ircd-t1.conf -c user@127.0.0.1 +echo "Sending signals to server." +cp ${srcdir}/ircd-t1-2.conf ircd-t1.conf +kill -HUP `cat ircd-t1.pid` +sleep 1 +kill -INT `cat ircd-t1.pid` +# A long sleep is necessary to make the server flush its IPcheck entries. +sleep 610 +kill -TERM `cat ircd-t1.pid` `cat ircd-t2.pid` +sleep 1 +../ircd -? || true Index: ircd-ircdev/ircd/test/stats-1.cmd diff -u ircd-ircdev/ircd/test/stats-1.cmd:1.1 ircd-ircdev/ircd/test/stats-1.cmd:1.2 --- ircd-ircdev/ircd/test/stats-1.cmd:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/stats-1.cmd Tue May 31 04:11:01 2005 @@ -33,6 +33,9 @@ :cl1 raw :stats z :cl1 raw :stats * +# Remote stats requests +:cl1 raw :stats f test-2.* + # Named stats commands :cl1 raw :stats nameservers :cl1 raw :stats connect @@ -65,6 +68,9 @@ :cl1 raw :stats memory :cl1 raw :stats help :cl1 raw :hash +:cl1 raw :rehash m +:cl1 raw :rehash l +:cl1 raw :rehash q :cl1 raw :rehash :cl1 nick Alexey Index: ircd-ircdev/ircd/test/test-driver.pl diff -u ircd-ircdev/ircd/test/test-driver.pl:1.1 ircd-ircdev/ircd/test/test-driver.pl:1.2 --- ircd-ircdev/ircd/test/test-driver.pl:1.1 Mon May 16 04:31:20 2005 +++ ircd-ircdev/ircd/test/test-driver.pl Tue May 31 04:11:01 2005 @@ -4,7 +4,7 @@ # collection isn't broken. POE is sometimes too clever for our good # in finding references to sessions, and keeps running even after we # want to stop. -# $Id: test-driver.pl,v 1.1 2005/05/16 11:31:20 zolty Exp $ +# $Id: test-driver.pl,v 1.2 2005/05/31 11:11:01 zolty Exp $ # This interprets a simple scripting language. Lines starting with a # hash mark (#, aka octothorpe, pound sign, etc) are ignored. The @@ -103,8 +103,11 @@ irc_nick => sub {}, irc_part => sub {}, irc_ping => sub {}, + irc_pong => sub {}, + irc_rpong => sub {}, irc_quit => sub {}, irc_topic => sub {}, + irc_plugin_add => sub {}, irc_error => \&irc_error, irc_disconnected => \&irc_disconnected, irc_socketerr => \&irc_socketerr, @@ -316,7 +319,8 @@ } return undef; } - print "ERROR: Unexpected event $state to test driver (from ".$sender->ID.")\n"; + print "ERROR: Unexpected event $state to test driver (from ".$sender->ID.")\n" + unless $state eq '_signal'; return undef; } Index: ircd-ircdev/ircd/test/test_stub.c diff -u ircd-ircdev/ircd/test/test_stub.c:1.2 ircd-ircdev/ircd/test/test_stub.c:1.3 --- ircd-ircdev/ircd/test/test_stub.c:1.2 Mon Mar 21 10:39:12 2005 +++ ircd-ircdev/ircd/test/test_stub.c Tue May 31 04:11:01 2005 @@ -17,6 +17,7 @@ va_start(args, fmt); vfprintf(stderr, fmt, args); + fputc('\n', stderr); va_end(args); } @@ -27,6 +28,7 @@ va_start(args, form); vfprintf(stdout, form, args); + fputc('\n', stdout); va_end(args); } ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-06-22 07:54:50
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-06-22 07:54:40 UTC Modified files: ChangeLog ChangeLog.es include/channel.h include/class.h include/ddb.h include/ircd_string.h include/list.h include/numeric.h include/patchlevel.h include/watch.h ircd/IPcheck.c ircd/channel.c ircd/class.c ircd/client.c ircd/ddb.c ircd/ddb_events.c ircd/ircd.c ircd/ircd_res.c ircd/ircd_string.c ircd/list.c ircd/m_burst.c ircd/m_clearmode.c ircd/m_dbq.c ircd/m_endburst.c ircd/m_invite.c ircd/m_server.c ircd/m_topic.c ircd/match.c ircd/s_bsd.c ircd/s_conf.c ircd/s_debug.c ircd/s_err.c ircd/s_serv.c ircd/s_stats.c ircd/s_user.c ircd/send.c ircd/watch.c ircd/test/.cvsignore ircd/test/Makefile.in ircd/test/kill-block-1.cmd ircd/test/run-tests.sh Log message: Author: zoltan <zo...@ir...> Log message: 2005-06-22 Toni García <zo...@ir...> 1.0.alpha39 * Limpieza * Fixs de bugs estéticos ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.40 ircd-ircdev/ChangeLog:1.41 --- ircd-ircdev/ChangeLog:1.40 Thu May 26 03:34:12 2005 +++ ircd-ircdev/ChangeLog Wed Jun 22 00:54:28 2005 @@ -1,10 +1,14 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.40 2005/05/26 10:34:12 zolty Exp $ +# $Id: ChangeLog,v 1.41 2005/06/22 07:54:28 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-06-22 Toni García <zo...@ir...> 1.0.alpha39 + * Cleanups + * Estetic bugfixes + 2005-05-26 Toni García <zo...@ir...> 1.0.alpha38 * Fix bugs last release. Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.40 ircd-ircdev/ChangeLog.es:1.41 --- ircd-ircdev/ChangeLog.es:1.40 Thu May 26 03:34:13 2005 +++ ircd-ircdev/ChangeLog.es Wed Jun 22 00:54:29 2005 @@ -1,10 +1,14 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.40 2005/05/26 10:34:13 zolty Exp $ +# $Id: ChangeLog.es,v 1.41 2005/06/22 07:54:29 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-06-22 Toni García <zo...@ir...> 1.0.alpha39 + * Limpieza + * Fixs de bugs estéticos + 2005-05-26 Toni García <zo...@ir...> 1.0.alpha38 * Fix de bugs de la release anterior Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.10 ircd-ircdev/include/channel.h:1.11 --- ircd-ircdev/include/channel.h:1.10 Wed May 25 09:56:23 2005 +++ ircd-ircdev/include/channel.h Wed Jun 22 00:54:29 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Channel management and maintenance. - * @version $Id: channel.h,v 1.10 2005/05/25 16:56:23 zolty Exp $ + * @version $Id: channel.h,v 1.11 2005/06/22 07:54:29 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -319,14 +319,14 @@ /** A single ban for a channel. */ struct Ban { - struct Ban* next; /**< next ban in the channel */ + struct Ban* next; /**< next ban in the channel */ struct irc_in_addr address; /**< addres for BAN_IPMASK bans */ - time_t when; /**< timestamp when ban was added */ - unsigned short flags; /**< modifier flags for the ban */ - unsigned char nu_len; /**< length of nick!user part of banstr */ - unsigned char addrbits; /**< netmask length for BAN_IPMASK bans */ - char *who; /**< name of client that set the ban */ - char *banstr; /**< hostmask that the ban matches */ + time_t when; /**< timestamp when ban was added */ + unsigned short flags; /**< modifier flags for the ban */ + unsigned char nu_len; /**< length of nick!user part of banstr */ + unsigned char addrbits; /**< netmask length for BAN_IPMASK bans */ + char who[NICKLEN+1]; /**< name of client that set the ban */ + char banstr[NICKLEN+USERLEN+HOSTLEN+3]; /**< hostmask that the ban matches */ }; /** Information about a channel */ Index: ircd-ircdev/include/class.h diff -u ircd-ircdev/include/class.h:1.6 ircd-ircdev/include/class.h:1.7 --- ircd-ircdev/include/class.h:1.6 Mon Jan 10 04:21:59 2005 +++ ircd-ircdev/include/class.h Wed Jun 22 00:54:29 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Declarations and interfaces for handling connection classes. - * @version $Id: class.h,v 1.6 2005/01/10 12:21:59 zolty Exp $ + * @version $Id: class.h,v 1.7 2005/06/22 07:54:29 zolty Exp $ */ #ifndef INCLUDED_class_h #define INCLUDED_class_h @@ -103,7 +103,6 @@ extern struct ConnectionClass *find_class(const char *name); extern struct ConnectionClass *make_class(void); extern void free_class(struct ConnectionClass * tmp); -extern unsigned int get_con_freq(struct ConnectionClass * clptr); extern char *get_conf_class(const struct ConfItem *aconf); extern int get_conf_ping(const struct ConfItem *aconf); extern char *get_client_class(struct Client *acptr); Index: ircd-ircdev/include/ddb.h diff -u ircd-ircdev/include/ddb.h:1.9 ircd-ircdev/include/ddb.h:1.10 --- ircd-ircdev/include/ddb.h:1.9 Wed May 25 09:56:23 2005 +++ ircd-ircdev/include/ddb.h Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Distributed DataBases structures, macros and functions. - * @version $Id: ddb.h,v 1.9 2005/05/25 16:56:23 zolty Exp $ + * @version $Id: ddb.h,v 1.10 2005/06/22 07:54:29 zolty Exp $ */ #ifndef INCLUDED_ddb_h #define INCLUDED_ddb_h @@ -149,6 +149,7 @@ extern void ddb_reload(void); extern void ddb_die(const char *pattern, ...); extern void ddb_report_stats(struct Client* to, const struct StatDesc* sd, char* param); +extern void ddb_count_memory(size_t* count_out, size_t* bytes_out); /* ddb_db_*.c externs */ extern void ddb_db_init(void); Index: ircd-ircdev/include/ircd_string.h diff -u ircd-ircdev/include/ircd_string.h:1.5 ircd-ircdev/include/ircd_string.h:1.6 --- ircd-ircdev/include/ircd_string.h:1.5 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/ircd_string.h Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file ircd_string.h * @brief Public declarations and APIs for string operations. - * @version $Id: ircd_string.h,v 1.5 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: ircd_string.h,v 1.6 2005/06/22 07:54:29 zolty Exp $ */ #ifndef INCLUDED_ircd_string_h #define INCLUDED_ircd_string_h @@ -30,6 +30,8 @@ #include "ircd_chattr.h" #endif +#include <string.h> /* for DupString()'s strcpy, strlen */ + struct irc_in_addr; /* @@ -38,13 +40,6 @@ /** Check whether \a x is a NULL or empty string. */ #define EmptyString(x) (!(x) || !(*x)) -/* - * initialize recognizers - */ -extern int init_string(void); - -extern int string_is_hostname(const char* str); -extern int string_is_address(const char* str); extern int string_has_wildcards(const char* str); extern char* ircd_strncpy(char* dest, const char* src, size_t len); @@ -139,9 +134,4 @@ #endif #endif /* FORCEINLINE */ -/* - * Proto types of other externally visible functions - */ -extern int strnChattr(const char *s, const size_t n); - #endif /* INCLUDED_ircd_string_h */ Index: ircd-ircdev/include/list.h diff -u ircd-ircdev/include/list.h:1.5 ircd-ircdev/include/list.h:1.6 --- ircd-ircdev/include/list.h:1.5 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/list.h Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file list.h * @brief Singly and doubly linked list manipulation interface. - * @version $Id: list.h,v 1.5 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: list.h,v 1.6 2005/06/22 07:54:29 zolty Exp $ */ #ifndef INCLUDED_list_h #define INCLUDED_list_h @@ -71,7 +71,6 @@ extern void free_link(struct SLink *lp); extern struct SLink *make_link(void); -extern struct SLink *find_user_link(struct SLink *lp, struct Client *ptr); extern void init_list(void); extern struct Client *make_client(struct Client *from, int status); extern void free_connection(struct Connection *con); Index: ircd-ircdev/include/numeric.h diff -u ircd-ircdev/include/numeric.h:1.13 ircd-ircdev/include/numeric.h:1.14 --- ircd-ircdev/include/numeric.h:1.13 Sat May 7 15:23:39 2005 +++ ircd-ircdev/include/numeric.h Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Declarations of numeric replies and supporting functions. - * @version $Id: numeric.h,v 1.13 2005/05/07 22:23:39 zolty Exp $ + * @version $Id: numeric.h,v 1.14 2005/06/22 07:54:29 zolty Exp $ */ #ifndef INCLUDED_numeric_h #define INCLUDED_numeric_h @@ -121,12 +121,12 @@ #define RPL_STATSALINE 226 /* Hybrid, Undernet */ #define RPL_STATSQLINE 228 /* Undernet extension */ -#define RPL_SERVICEINFO 231 /* unused */ -#define RPL_ENDOFSERVICES 232 /* unused */ +/* RPL_SERVICEINFO 231 unused */ +/* RPL_ENDOFSERVICES 232 unused */ /* RPL_RULES 232 unreal */ -#define RPL_SERVICE 233 /* unused */ -#define RPL_SERVLIST 234 /* unused */ -#define RPL_SERVLISTEND 235 /* unused */ +/* RPL_SERVICE 233 unused */ +/* RPL_SERVLIST 234 unused */ +/* RPL_SERVLISTEND 235 unused */ #define RPL_STATSVERBOSE 236 /* Undernet verbose server list */ #define RPL_STATSENGINE 237 /* Undernet engine name */ @@ -161,7 +161,7 @@ #define RPL_ADMINLOC2 258 #define RPL_ADMINEMAIL 259 -#define RPL_TRACELOG 261 /* unused */ +/* RPL_TRACELOG 261 unused */ #define RPL_TRACEEND 262 /* efnet/IRCnet */ /* RPL_LOAD_THROTTLED 263 efnet/hybrid */ /* RPL_TRYAGAIN 263 Numerics List: IRCnet */ @@ -206,11 +206,11 @@ /* RPL_END_CHANINFO 299 aircd */ -#define RPL_NONE 300 /* unused */ +/* RPL_NONE 300 unused */ #define RPL_AWAY 301 #define RPL_USERHOST 302 #define RPL_ISON 303 -#define RPL_TEXT 304 /* unused */ +/* RPL_TEXT 304 unused */ #define RPL_UNAWAY 305 #define RPL_NOWAWAY 306 /* NotAway, aircd */ @@ -276,7 +276,7 @@ See also RPL_ENDOFWHO */ #define RPL_DELNAMREPLY 355 /* QuakeNet extension */ -#define RPL_KILLDONE 361 /* not used */ +/* RPL_KILLDONE 361 not used */ #define RPL_CLOSING 362 #define RPL_CLOSEEND 363 #define RPL_LINKS 364 @@ -303,12 +303,12 @@ #define RPL_YOUREOPER 381 #define RPL_REHASHING 382 /* RPL_YOURSERVICE 383 Numeric List: various */ -#define RPL_MYPORTIS 384 /* not used */ -#define RPL_NOTOPERANYMORE 385 /* Extension to RFC1459, not used */ +/* RPL_MYPORTIS 384 not used */ +/* RPL_NOTOPERANYMORE 385 Extension to RFC1459, not used */ /* RPL_QLIST 386 unreal */ /* RPL_ENDOFQLIST 387 unreal */ /* RPL_ALIST 388 unreal */ -/* RPL_ENDOFALIST 389 unreal */ +/* RPL_ENDOFALIST 389 unreal */ #define RPL_WHOISSUSPEND 390 /* IRC-Dev extension */ #define RPL_TIME 391 @@ -322,7 +322,7 @@ * Errors are in the range from 400-599 currently and are grouped by what * commands they come from. */ -#define ERR_FIRSTERROR 400 /* unused */ +/* ERR_FIRSTERROR 400 unused */ #define ERR_NOSUCHNICK 401 #define ERR_NOSUCHSERVER 402 #define ERR_NOSUCHCHANNEL 403 Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.39 ircd-ircdev/include/patchlevel.h:1.40 --- ircd-ircdev/include/patchlevel.h:1.39 Thu May 26 03:34:13 2005 +++ ircd-ircdev/include/patchlevel.h Wed Jun 22 00:54:29 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.39 2005/05/26 10:34:13 zolty Exp $ + * $Id: patchlevel.h,v 1.40 2005/06/22 07:54:29 zolty Exp $ * */ -#define PATCHLEVEL ".alpha38" +#define PATCHLEVEL ".alpha39" #define RELEASE "1.0" Index: ircd-ircdev/include/watch.h diff -u ircd-ircdev/include/watch.h:1.3 ircd-ircdev/include/watch.h:1.4 --- ircd-ircdev/include/watch.h:1.3 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/watch.h Wed Jun 22 00:54:29 2005 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: watch.h,v 1.3 2005/01/10 12:22:00 zolty Exp $ + * $Id: watch.h,v 1.4 2005/06/22 07:54:29 zolty Exp $ * */ #ifndef INCLUDED_watch_h @@ -65,6 +65,6 @@ extern int add_nick_watch(struct Client *sptr, char *nick); extern int del_nick_watch(struct Client *sptr, char *nick); extern int del_list_watch(struct Client *sptr); -extern int watch_memory_count(size_t *wt_size); +extern void watch_count_memory(size_t* count_out, size_t* bytes_out); #endif /* INCLUDED_watch_h */ Index: ircd-ircdev/ircd/IPcheck.c diff -u ircd-ircdev/ircd/IPcheck.c:1.10 ircd-ircdev/ircd/IPcheck.c:1.11 --- ircd-ircdev/ircd/IPcheck.c:1.10 Mon Mar 21 10:39:05 2005 +++ ircd-ircdev/ircd/IPcheck.c Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Code to count users connected from particular IP addresses. - * @version $Id: IPcheck.c,v 1.10 2005/03/21 18:39:05 zolty Exp $ + * @version $Id: IPcheck.c,v 1.11 2005/06/22 07:54:29 zolty Exp $ */ #include "config.h" @@ -30,11 +30,11 @@ #include "ircd.h" #include "match.h" #include "msg.h" -#include "numnicks.h" /* NumNick, NumServ (GODMODE) */ #include "ircd_alloc.h" #include "ircd_events.h" #include "ircd_features.h" #include "ircd_log.h" +#include "ircd_string.h" /* ircd_ntoa */ #include "s_debug.h" /* Debug */ #include "s_user.h" /* TARGET_DELAY */ #include "send.h" @@ -222,6 +222,7 @@ /* * expired */ + Debug((DEBUG_DNS, "IPcheck expiring registry for %s (no clients connected).", ircd_ntoa(&entry->addr))); ip_registry_remove(entry); ip_registry_delete_entry(entry); } @@ -278,16 +279,18 @@ entry = ip_registry_new_entry(); ip_registry_canonicalize(&entry->addr, addr); ip_registry_add(entry); + Debug((DEBUG_DNS, "IPcheck added new registry for local connection from %s.", ircd_ntoa(&entry->addr))); return 1; } - /* Note that this also connects server connects. + /* Note that this also counts server connects. * It is hard and not interesting, to change that. * - * Don't allow more then 255 connects from one IP number, ever + * Refuse connection if it would overflow the counter. */ if (0 == ++entry->connected) { entry->connected--; + Debug((DEBUG_DNS, "IPcheck refusing local connection from %s: counter overflow.", ircd_ntoa(&entry->addr))); return 0; } @@ -305,17 +308,17 @@ *next_target_out = CurrentTime - (TARGET_DELAY * free_targets - 1); } else if ((CurrentTime - cli_since(&me)) > IPCHECK_CLONE_DELAY) { - /* + /* * Don't refuse connection when we just rebooted the server */ -#ifdef NOTHROTTLE - return 1; -#else +#ifndef NOTHROTTLE assert(entry->connected > 0); --entry->connected; + Debug((DEBUG_DNS, "IPcheck refusing local connection from %s: too fast.", ircd_ntoa(&entry->addr))); return 0; -#endif +#endif } + Debug((DEBUG_DNS, "IPcheck accepting local connection from %s.", ircd_ntoa(&entry->addr))); return 1; } @@ -335,8 +338,10 @@ * Mark that we did add/update an IPregistry entry */ SetIPChecked(cptr); - if (!irc_in_addr_valid(&cli_ip(cptr))) + if (!irc_in_addr_valid(&cli_ip(cptr))) { + Debug((DEBUG_DNS, "IPcheck accepting remote connection from invalid %s.", ircd_ntoa(&cli_ip(cptr)))); return 1; + } entry = ip_registry_find(&cli_ip(cptr)); if (0 == entry) { entry = ip_registry_new_entry(); @@ -344,27 +349,27 @@ if (is_burst) entry->attempts = 0; ip_registry_add(entry); + Debug((DEBUG_DNS, "IPcheck added new registry for remote connection from %s.", ircd_ntoa(&entry->addr))); + return 1; } - else { - if (0 == ++entry->connected) { - /* - * Don't allow more then 255 connects from one IP number, ever + /* Avoid overflowing the connection counter. */ + if (0 == ++entry->connected) { + Debug((DEBUG_DNS, "IPcheck refusing remote connection from %s: counter overflow.", ircd_ntoa(&entry->addr))); + return 0; + } + if (CONNECTED_SINCE(entry->last_connect) > IPCHECK_CLONE_PERIOD) + entry->attempts = 0; + if (!is_burst) { + if (0 == ++entry->attempts) { + /* + * Check for overflow */ - return 0; - } - if (CONNECTED_SINCE(entry->last_connect) > IPCHECK_CLONE_PERIOD) - entry->attempts = 0; - if (!is_burst) { - if (0 == ++entry->attempts) { - /* - * Check for overflow - */ - --entry->attempts; - } - ip_registry_update_free_targets(entry); - entry->last_connect = NOW; + --entry->attempts; } + ip_registry_update_free_targets(entry); + entry->last_connect = NOW; } + Debug((DEBUG_DNS, "IPcheck counting remote connection from %s.", ircd_ntoa(&entry->addr))); return 1; } @@ -376,10 +381,9 @@ void ip_registry_connect_fail(const struct irc_in_addr *addr) { struct IPRegistryEntry* entry = ip_registry_find(addr); - if (entry) - { - if (0 == --entry->attempts) - ++entry->attempts; + if (entry && 0 == --entry->attempts) { + Debug((DEBUG_DNS, "IPcheck noting local connection failure for %s.", ircd_ntoa(&entry->addr))); + ++entry->attempts; } } @@ -395,15 +399,13 @@ unsigned int free_targets = STARTTARGETS; struct IPRegistryEntry* entry = ip_registry_find(&cli_ip(cptr)); - if (!entry) { - Debug((DEBUG_ERROR, "Missing registry entry for: %s", cli_sock_ip(cptr))); - return; - } + assert(entry); if (entry->target) { memcpy(cli_targets(cptr), entry->target->targets, MAXTARGETS); free_targets = entry->target->count; tr = " tr"; } + Debug((DEBUG_DNS, "IPcheck noting local connection success for %s.", ircd_ntoa(&entry->addr))); sendcmdto_one(&me, CMD_NOTICE, cptr, "%C :on %u ca %u(%u) ft %u(%u)%s", cptr, entry->connected, entry->attempts, IPCHECK_CLONE_LIMIT, free_targets, STARTTARGETS, tr); @@ -417,17 +419,16 @@ void ip_registry_disconnect(struct Client *cptr) { struct IPRegistryEntry* entry = ip_registry_find(&cli_ip(cptr)); - if (0 == entry) { - /* - * trying to find an entry for a server causes this to happen, - * servers should never have FLAG_IPCHECK set - */ + if (!irc_in_addr_valid(&cli_ip(cptr))) { + Debug((DEBUG_DNS, "IPcheck noting dicconnect from invalid %s.", ircd_ntoa(&cli_ip(cptr)))); return; } + assert(entry); + assert(entry->connected > 0); + Debug((DEBUG_DNS, "IPcheck noting disconnect from %s.", ircd_ntoa(&entry->addr))); /* * If this was the last one, set `last_connect' to disconnect time (used for expiration) */ - /* assert(entry->connected > 0); */ if (0 == --entry->connected) { if (CONNECTED_SINCE(entry->last_connect) > IPCHECK_CLONE_LIMIT * IPCHECK_CLONE_PERIOD) { /* Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.23 ircd-ircdev/ircd/channel.c:1.24 --- ircd-ircdev/ircd/channel.c:1.23 Thu May 26 03:34:13 2005 +++ ircd-ircdev/ircd/channel.c Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Channel management and maintanance - * @version $Id: channel.c,v 1.23 2005/05/26 10:34:13 zolty Exp $ + * @version $Id: channel.c,v 1.24 2005/06/22 07:54:29 zolty Exp $ */ #include "config.h" @@ -70,6 +70,10 @@ static struct Membership* membershipFreeList; /** Freelist for struct Ban*'s */ static struct Ban* free_bans; +/** Number of ban structures allocated. */ +static size_t bans_alloc; +/** Number of ban structures in use. */ +static size_t bans_inuse; #if !defined(NDEBUG) /** return the length (>=0) of a chain of links. @@ -94,10 +98,9 @@ set_ban_mask(struct Ban *ban, const char *banstr) { char *sep; - MyFree(ban->banstr); - if (!banstr) - return; - DupString(ban->banstr, banstr); + + assert(banstr != NULL); + ircd_strncpy(ban->banstr, banstr, sizeof(ban->banstr) - 1); sep = strrchr(banstr, '@'); if (sep) { ban->nu_len = sep - banstr; @@ -120,6 +123,9 @@ } else if (!(ban = MyMalloc(sizeof(*ban)))) return NULL; + else + bans_alloc++; + bans_inuse++; memset(ban, 0, sizeof(*ban)); set_ban_mask(ban, banstr); return ban; @@ -131,12 +137,24 @@ void free_ban(struct Ban *ban) { - MyFree(ban->who); - MyFree(ban->banstr); ban->next = free_bans; free_bans = ban; + bans_inuse--; } +/** Report ban usage to \a cptr. + * @param[in] cptr Client requesting information. + */ +void bans_send_meminfo(struct Client *cptr) +{ + struct Ban *ban; + size_t num_free; + for (num_free = 0, ban = free_bans; ban; ban = ban->next) + num_free++; + send_reply(cptr, SND_EXPLICIT | RPL_STATSDEBUG, ":Bans: inuse %zu(%zu) free %zu alloc %zu", + bans_inuse, bans_inuse * sizeof(*ban), num_free, bans_alloc); + } + /** return the struct Membership* that represents a client on a channel * This function finds a struct Membership* which holds the state about * a client on a specific channel. The code is smart enough to iterate @@ -741,9 +759,9 @@ struct Membership *member; assert(0 != cptr); /* - * Servers can always speak on channels. + * Servers and channel services can always speak on channels. */ - if (IsServer(cptr)) + if (IsServer(cptr) || IsChannelService(cptr)) return 1; member = find_channel_member(cptr, chptr); @@ -847,7 +865,11 @@ *mbuf++ = 'k'; if (previous_parameter) strcat(pbuf, " "); +#if defined(DDB) || defined(SERVICES) + if (is_chan_owner(cptr, chptr) || is_chan_op(cptr, chptr) || IsServer(cptr)) { +#else if (is_chan_op(cptr, chptr) || IsServer(cptr)) { +#endif strcat(pbuf, chptr->mode.key); } else strcat(pbuf, "*"); @@ -2951,8 +2973,6 @@ if (!bmatch(ban, newban)) { if (do_free) free_ban(newban); - else - MyFree(newban); return 1; } if (!(ban->flags & (BAN_OVERLAPPED|BAN_DEL))) { @@ -2983,14 +3003,10 @@ /* If no matches were found, fail. */ if (do_free) free_ban(newban); - else - MyFree(newban->banstr); return 3; } if (do_free) free_ban(newban); - else - MyFree(newban->banstr); return 4; } @@ -3047,9 +3063,8 @@ newban->next = 0; newban->flags = ((state->dir == MODE_ADD) ? BAN_ADD : BAN_DEL) | (*flag_p == MODE_BAN ? 0 : BAN_EXCEPTION); - newban->banstr = NULL; set_ban_mask(newban, collapse(pretty_mask(t_str))); - newban->who = cli_name(state->sptr); + ircd_strncpy(newban->who, cli_name(state->sptr), HOSTLEN); newban->when = TStime(); apply_ban(&state->chptr->banlist, newban, 0); } @@ -3081,12 +3096,13 @@ count--; len -= banlen; - MyFree(ban->banstr); - continue; } else if (ban->flags & BAN_DEL) { /* Deleted a ban? */ + char *bandup; + + DupString(bandup, ban->banstr); modebuf_mode_string(state->mbuf, MODE_DEL | MODE_BAN, - ban->banstr, 1); + bandup, 1); if (state->flags & MODE_PARSE_SET) { /* Ok, make it take effect */ if (prevban) /* clip it out of the list... */ @@ -3096,9 +3112,6 @@ count--; len -= banlen; - - ban->banstr = NULL; /* modebuf_mode_string() gave ownership of - * the ban string to state->mbuf */ free_ban(ban); changed++; @@ -3116,7 +3129,6 @@ !(state->flags & MODE_PARSE_BOUNCE)) { count--; len -= banlen; - MyFree(ban->banstr); } else { if (state->flags & MODE_PARSE_SET && MyUser(state->sptr) && (len > (feature_int(FEAT_AVBANLEN) * feature_int(FEAT_MAXBANS)) || @@ -3125,15 +3137,17 @@ ban->banstr); count--; len -= banlen; - MyFree(ban->banstr); } else { + char *bandup; + /* add the ban to the buffer */ + DupString(bandup, ban->banstr); modebuf_mode_string(state->mbuf, MODE_ADD | MODE_BAN, - ban->banstr, 1); + bandup, 1); if (state->flags & MODE_PARSE_SET) { /* create a new ban */ newban = make_ban(ban->banstr); - DupString(newban->who, ban->who); + strcpy(newban->who, ban->who); newban->when = ban->when; newban->flags = ban->flags & BAN_IPMASK; @@ -3149,13 +3163,6 @@ prevban = ban; } /* for (prevban = 0, ban = state->chptr->banlist; ban; ban = nextban) { */ - /* Release all masks of removed bans */ - for (count = 0; count < state->numbans; ++count) { - ban = state->banlist + count; - if (ban->flags & BAN_DEL) - MyFree(ban->banstr); - } - if (changed) /* if we changed the ban list, we must invalidate the bans */ mode_ban_invalidate(state->chptr); } @@ -3436,7 +3443,7 @@ for (i = 0; i < MAXPARA; i++) { /* initialize ops/voices arrays */ state.banlist[i].next = 0; - state.banlist[i].who = 0; + state.banlist[i].who[0] = '\0'; state.banlist[i].when = 0; state.banlist[i].flags = 0; state.cli_change[i].flag = 0; @@ -3819,7 +3826,8 @@ /* RevealDelayedJoin: sends a join for a hidden user */ -void RevealDelayedJoin(struct Membership *member) { +void RevealDelayedJoin(struct Membership *member) +{ ClearDelayedJoin(member); sendcmdto_channel_butserv_butone(member->user, CMD_JOIN, member->channel, member->user, 0, ":%H", member->channel); @@ -3828,14 +3836,15 @@ /* CheckDelayedJoins: checks and clear +d if necessary */ -void CheckDelayedJoins(struct Channel *chan) { +void CheckDelayedJoins(struct Channel *chan) +{ struct Membership *memb2; - + if (chan->mode.mode & MODE_WASDELJOINS) { for (memb2=chan->members;memb2;memb2=memb2->next_member) if (IsDelayedJoin(memb2)) break; - + if (!memb2) { /* clear +d */ chan->mode.mode &= ~MODE_WASDELJOINS; Index: ircd-ircdev/ircd/class.c diff -u ircd-ircdev/ircd/class.c:1.7 ircd-ircdev/ircd/class.c:1.8 --- ircd-ircdev/ircd/class.c:1.7 Fri Apr 22 09:22:13 2005 +++ ircd-ircdev/ircd/class.c Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Implementation of connection class handling functions. - * @version $Id: class.c,v 1.7 2005/04/22 16:22:13 zolty Exp $ + * @version $Id: class.c,v 1.8 2005/06/22 07:54:29 zolty Exp $ */ #include "config.h" @@ -199,19 +199,6 @@ return "(null-class)"; } -/** Get connection interval for a connection class. - * @param[in] clptr Connection class to check (or NULL). - * @return If \a clptr != NULL, its connection frequency; else default - * connection frequency. - */ -unsigned int get_con_freq(struct ConnectionClass * clptr) -{ - if (clptr) - return (ConFreq(clptr)); - else - return feature_int(FEAT_CONNECTFREQUENCY); -} - /** Make sure we have a connection class named \a name. * If one does not exist, create it. Then set its ping frequency, * connection frequency, maximum link count, and max SendQ according Index: ircd-ircdev/ircd/client.c diff -u ircd-ircdev/ircd/client.c:1.8 ircd-ircdev/ircd/client.c:1.9 --- ircd-ircdev/ircd/client.c:1.8 Wed Mar 9 10:12:34 2005 +++ ircd-ircdev/ircd/client.c Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Implementation of functions for handling local clients. - * @version $Id: client.c,v 1.8 2005/03/09 18:12:34 zolty Exp $ + * @version $Id: client.c,v 1.9 2005/06/22 07:54:29 zolty Exp $ */ #include "config.h" @@ -232,8 +232,8 @@ P(GLINE), P(LOCAL_GLINE), P(JUPE), P(LOCAL_JUPE), P(OPMODE), P(LOCAL_OPMODE), P(SET), P(WHOX), P(BADCHAN), P(LOCAL_BADCHAN), P(SEE_CHAN), P(PROPAGATE), - P(DISPLAY), P(SEE_OPERS), P(FORCE_OPMODE), P(FORCE_LOCAL_OPMODE), - P(WIDE_GLINE), + P(DISPLAY), P(SEE_OPERS), P(WIDE_GLINE), P(LIST_CHAN), + P(FORCE_OPMODE), P(FORCE_LOCAL_OPMODE), P(APASS_OPMODE), #undef P { 0, 0 } }; Index: ircd-ircdev/ircd/ddb.c diff -u ircd-ircdev/ircd/ddb.c:1.10 ircd-ircdev/ircd/ddb.c:1.11 --- ircd-ircdev/ircd/ddb.c:1.10 Wed May 25 09:56:24 2005 +++ ircd-ircdev/ircd/ddb.c Wed Jun 22 00:54:29 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Implementation of Distributed DataBase. - * @version $Id: ddb.c,v 1.10 2005/05/25 16:56:24 zolty Exp $ + * @version $Id: ddb.c,v 1.11 2005/06/22 07:54:29 zolty Exp $ */ #include "config.h" @@ -56,6 +56,8 @@ * TODO, explicacion del sistema */ +/** Count of allocated Ddb structures. */ +static int ddbCount = 0; /** DDB registers cache. */ static struct Ddb ddb_buf_cache[DDB_BUF_CACHE]; /** Buffer cache. */ @@ -396,6 +398,7 @@ ddb_next(ddb) = ddb_data_table[table][hashi]; ddb_data_table[table][hashi] = ddb; ddb_count_table[table]++; + ddbCount++; return delete; } @@ -426,6 +429,7 @@ delete = 1; DdbFree(ddb); ddb_count_table[table]--; + ddbCount--; break; } ddb3 = &(ddb_next(ddb)); @@ -791,3 +795,15 @@ } } } + +/** Find number of DDB structs allocated and memory used by them. + * @param[out] count_out Receives number of DDB structs allocated. + * @param[out] bytes_out Receives number of bytes used by DDB structs. + */ +void ddb_count_memory(size_t* count_out, size_t* bytes_out) +{ + assert(0 != count_out); + assert(0 != bytes_out); + *count_out = ddbCount; + *bytes_out = ddbCount * sizeof(struct Ddb); +} Index: ircd-ircdev/ircd/ddb_events.c diff -u ircd-ircdev/ircd/ddb_events.c:1.6 ircd-ircdev/ircd/ddb_events.c:1.7 --- ircd-ircdev/ircd/ddb_events.c:1.6 Thu May 26 03:34:13 2005 +++ ircd-ircdev/ircd/ddb_events.c Wed Jun 22 00:54:29 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Events of Distributed DataBases. - * @version $Id: ddb_events.c,v 1.6 2005/05/26 10:34:13 zolty Exp $ + * @version $Id: ddb_events.c,v 1.7 2005/06/22 07:54:29 zolty Exp $ */ #include "config.h" @@ -173,18 +173,15 @@ /* Quitar -q */ for (member = chptr->members; member; member = member->next_member) { - if (IsChanOwner(member)) + if (IsChanOwner(member) && MyUser... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-06-22 09:59:10
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-06-22 09:59:03 UTC Modified files: ChangeLog ChangeLog.es include/channel.h include/ddb.h include/patchlevel.h ircd/ddb.c ircd/ddb_events.c ircd/hash.c ircd/m_list.c ircd/s_user.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-06-22 Toni García <zo...@ir...> 1.0.alpha40 * Tabla v de Vhosts * /LIST con comodines ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.41 ircd-ircdev/ChangeLog:1.42 --- ircd-ircdev/ChangeLog:1.41 Wed Jun 22 00:54:28 2005 +++ ircd-ircdev/ChangeLog Wed Jun 22 02:58:52 2005 @@ -1,10 +1,14 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.41 2005/06/22 07:54:28 zolty Exp $ +# $Id: ChangeLog,v 1.42 2005/06/22 09:58:52 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-06-22 Toni García <zo...@ir...> 1.0.alpha40 + * Vhosts table v + * /LIST with wildcards + 2005-06-22 Toni García <zo...@ir...> 1.0.alpha39 * Cleanups * Estetic bugfixes Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.41 ircd-ircdev/ChangeLog.es:1.42 --- ircd-ircdev/ChangeLog.es:1.41 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/ChangeLog.es Wed Jun 22 02:58:52 2005 @@ -1,10 +1,14 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.41 2005/06/22 07:54:29 zolty Exp $ +# $Id: ChangeLog.es,v 1.42 2005/06/22 09:58:52 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-06-22 Toni García <zo...@ir...> 1.0.alpha40 + * Tabla v de Vhosts + * /LIST con comodines + 2005-06-22 Toni García <zo...@ir...> 1.0.alpha39 * Limpieza * Fixs de bugs estéticos Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.11 ircd-ircdev/include/channel.h:1.12 --- ircd-ircdev/include/channel.h:1.11 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/include/channel.h Wed Jun 22 02:58:52 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Channel management and maintenance. - * @version $Id: channel.h,v 1.11 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: channel.h,v 1.12 2005/06/22 09:58:52 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -192,6 +192,7 @@ #define LISTARG_TOPICLIMITS 0x0001 #define LISTARG_SHOWSECRET 0x0002 +#define LISTARG_NEGATEWILDCARD 0x0004 /** * Maximum acceptable lag time in seconds: A channel younger than @@ -361,6 +362,7 @@ time_t max_topic_time; time_t min_topic_time; unsigned int bucket; + char wildcard[CHANNELLEN]; }; struct ModeBuf { Index: ircd-ircdev/include/ddb.h diff -u ircd-ircdev/include/ddb.h:1.10 ircd-ircdev/include/ddb.h:1.11 --- ircd-ircdev/include/ddb.h:1.10 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/include/ddb.h Wed Jun 22 02:58:52 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Distributed DataBases structures, macros and functions. - * @version $Id: ddb.h,v 1.10 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: ddb.h,v 1.11 2005/06/22 09:58:52 zolty Exp $ */ #ifndef INCLUDED_ddb_h #define INCLUDED_ddb_h @@ -55,6 +55,8 @@ #define DDB_ILINEDB 'i' /** Nicks table of %DDB Distributed Databases. */ #define DDB_NICKDB 'n' +/** Vhost table of %DDB Distributed Databases. */ +#define DDB_VHOSTDB 'v' /** Config table of %DDB Distributed Databases. */ #define DDB_CONFIGDB 'z' /** Last table of %DDB Distributed Databases. */ Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.40 ircd-ircdev/include/patchlevel.h:1.41 --- ircd-ircdev/include/patchlevel.h:1.40 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/include/patchlevel.h Wed Jun 22 02:58:52 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.40 2005/06/22 07:54:29 zolty Exp $ + * $Id: patchlevel.h,v 1.41 2005/06/22 09:58:52 zolty Exp $ * */ -#define PATCHLEVEL ".alpha39" +#define PATCHLEVEL ".alpha40" #define RELEASE "1.0" Index: ircd-ircdev/ircd/ddb.c diff -u ircd-ircdev/ircd/ddb.c:1.11 ircd-ircdev/ircd/ddb.c:1.12 --- ircd-ircdev/ircd/ddb.c:1.11 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/ircd/ddb.c Wed Jun 22 02:58:52 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Implementation of Distributed DataBase. - * @version $Id: ddb.c,v 1.11 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: ddb.c,v 1.12 2005/06/22 09:58:52 zolty Exp $ */ #include "config.h" @@ -151,7 +151,7 @@ unsigned int buffer[129 * sizeof(unsigned int)]; unsigned int *p = buffer; unsigned int x[2], v[2], k[2]; - char *p2; +/* char *p2; */ char buf[1024]; /* ID Mask Key Content */ @@ -208,6 +208,7 @@ ddb_resident_table[DDB_CHANDB2] = 32768; ddb_resident_table[DDB_ILINEDB] = 256; ddb_resident_table[DDB_NICKDB] = 32768; + ddb_resident_table[DDB_VHOSTDB] = 256; ddb_resident_table[DDB_CONFIGDB] = 256; for (table = DDB_INIT; table <= DDB_END; table++) Index: ircd-ircdev/ircd/ddb_events.c diff -u ircd-ircdev/ircd/ddb_events.c:1.7 ircd-ircdev/ircd/ddb_events.c:1.8 --- ircd-ircdev/ircd/ddb_events.c:1.7 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/ircd/ddb_events.c Wed Jun 22 02:58:52 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Events of Distributed DataBases. - * @version $Id: ddb_events.c,v 1.7 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: ddb_events.c,v 1.8 2005/06/22 09:58:52 zolty Exp $ */ #include "config.h" @@ -48,6 +48,7 @@ static void ddb_events_table_c(char *key, char *content, int update); static void ddb_events_table_d(char *key, char *content, int update); static void ddb_events_table_n(char *key, char *content, int update); +static void ddb_events_table_v(char *key, char *content, int update); static void ddb_events_table_z(char *key, char *content, int update); @@ -63,6 +64,7 @@ ddb_events_table[DDB_CHANDB2] = ddb_events_table_d; ddb_events_table[DDB_ILINEDB] = 0; ddb_events_table[DDB_NICKDB] = ddb_events_table_n; + ddb_events_table[DDB_VHOSTDB] = ddb_events_table_v; ddb_events_table[DDB_CONFIGDB] = ddb_events_table_z; events_init = 1; @@ -342,6 +344,42 @@ } } +/** Handle events on Vhosts Table. + * @param[in] key Key of registry. + * @param[in] content Content of registry. + * @param[in] update Update of registry or no. + */ +static void +ddb_events_table_v(char *key, char *content, int update) +{ + struct Client *cptr; + + if (((cptr = FindUser(key))) && IsNickRegistered(cptr)) + { + /* Droping Key */ + if (!content) + { + /* + if (IsHiddenHost(cptr)) + { + ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, "SINIP"); + hide_hostmask(cptr, FLAG_HIDDENHOST); + + } + */ + } + else if (content) + { + if (IsHiddenHost(cptr)) + { + ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, content); + hide_hostmask(cptr, FLAG_NICKREG); + + } + } + } + +} /** Handle events on Config Table. * @param[in] key Key of registry. * @param[in] content Content of registry. Index: ircd-ircdev/ircd/hash.c diff -u ircd-ircdev/ircd/hash.c:1.10 ircd-ircdev/ircd/hash.c:1.11 --- ircd-ircdev/ircd/hash.c:1.10 Wed May 25 09:56:24 2005 +++ ircd-ircdev/ircd/hash.c Wed Jun 22 02:58:52 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Hash table management. - * @version $Id: hash.c,v 1.10 2005/05/25 16:56:24 zolty Exp $ + * @version $Id: hash.c,v 1.11 2005/06/22 09:58:52 zolty Exp $ * * This file used to use some very complicated hash function. Now it * uses CRC-32, but effectively remaps each input byte according to a @@ -512,6 +512,10 @@ && chptr->users < args->max_users && chptr->creationtime > args->min_time && chptr->creationtime < args->max_time + && (!args->wildcard[0] || (args->flags & LISTARG_NEGATEWILDCARD) || + (!match(args->wildcard, chptr->chname))) + && (!(args->flags & LISTARG_NEGATEWILDCARD) || + match(args->wildcard, chptr->chname)) && (!(args->flags & LISTARG_TOPICLIMITS) || (chptr->topic[0] && chptr->topic_time > args->min_topic_time Index: ircd-ircdev/ircd/m_list.c diff -u ircd-ircdev/ircd/m_list.c:1.7 ircd-ircdev/ircd/m_list.c:1.8 --- ircd-ircdev/ircd/m_list.c:1.7 Mon Mar 21 10:39:08 2005 +++ ircd-ircdev/ircd/m_list.c Wed Jun 22 02:58:52 2005 @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * - * $Id: m_list.c,v 1.7 2005/03/21 18:39:08 zolty Exp $ + * $Id: m_list.c,v 1.8 2005/06/22 09:58:52 zolty Exp $ * */ @@ -108,10 +108,11 @@ 0, /* min_time */ 4294967295U, /* max_users */ 0, /* min_users */ - 0, /* topic_limits */ + 0, /* flags */ 2147483647, /* max_topic_time */ 0, /* min_topic_time */ - 0 /* chptr */ + 0, /* bucket */ + {0} /* wildcard */ }; static struct ListingArgs la_default = { @@ -119,10 +120,11 @@ 0, /* min_time */ 4294967295U, /* max_users */ 0, /* min_users */ - 0, /* topic_limits */ + 0, /* flags */ 2147483647, /* max_topic_time */ 0, /* min_topic_time */ - 0 /* chptr */ + 0, /* bucket */ + {0} /* wildcard */ }; static int @@ -151,17 +153,25 @@ " \002C>\002\037min_minutes\037 ; Channels that exist more " "than \037min_minutes\037."); send_reply(sptr, RPL_LISTUSAGE, - " \002T<\002\037max_minutes\037 ; Channels with a topic last " - "set less than \037max_minutes\037 ago."); + " \002T<\002\037max_minutes\037 ; Channels with a topic last " + "set less than \037max_minutes\037 ago."); send_reply(sptr, RPL_LISTUSAGE, - " \002T>\002\037min_minutes\037 ; Channels with a topic last " - "set more than \037min_minutes\037 ago."); + " \002T>\002\037min_minutes\037 ; Channels with a topic last " + "set more than \037min_minutes\037 ago."); + send_reply(sptr, RPL_LISTUSAGE, + " \037pattern\037 ; Channels with names matching " + "\037pattern\037. "); + send_reply(sptr, RPL_LISTUSAGE, + " !\037pattern\037 ; Channels with names not " + "matching \037pattern\037. "); + send_reply(sptr, RPL_LISTUSAGE, "Note: Patterns may contain * and ?. " + "You may only give one pattern match constraint."); if (IsAnOper(sptr)) send_reply(sptr, RPL_LISTUSAGE, " \002S\002 ; Show secret channels."); send_reply(sptr, RPL_LISTUSAGE, - "Example: LIST <3,>1,C<10,T>0 ; 2 users, younger than 10 " - "min., topic set."); + "Example: LIST <3,>1,C<10,T>0,#a* ; 2 users, younger than 10 " + "min., topic set., starts with #a"); return LPARAM_ERROR; /* return error condition */ } @@ -173,6 +183,7 @@ int is_time = 0; char dir; unsigned int val; + char *tmp1, *tmp2; assert(0 != args); @@ -246,7 +257,47 @@ return show_usage(sptr); break; - default: /* channel name? */ + default: + /* It might be a wildcard... */ + if (strchr(param, '*') || + strchr(param, '?')) + { + if (param[0] == '!') + { + param++; + args->flags |= LISTARG_NEGATEWILDCARD; + } + + /* Only one wildcard allowed... */ + if (args->wildcard[0] != 0) + return show_usage(sptr); + + /* If its not going to match anything, don't bother. */ + if (param[0] != '*' && + param[0] != '?' && + param[0] != '#' && + param[0] != '&') + return show_usage(sptr); + + tmp1 = strchr(param, ','); + tmp2 = strchr(param, ' '); + if (tmp2 && (!tmp1 || (tmp2 < tmp1))) + tmp1 = tmp2; + + if (tmp1) + *tmp1++ = 0; + + ircd_strncpy(args->wildcard, param, CHANNELLEN-1); + args->wildcard[CHANNELLEN-1] = 0; + + if (tmp1 == NULL) + return LPARAM_SUCCESS; + + param = tmp1; + continue; + } + + /* channel name? */ if (!permit_chan || !IsChannelName(param)) return show_usage(sptr); Index: ircd-ircdev/ircd/s_user.c diff -u ircd-ircdev/ircd/s_user.c:1.21 ircd-ircdev/ircd/s_user.c:1.22 --- ircd-ircdev/ircd/s_user.c:1.21 Wed Jun 22 00:54:30 2005 +++ ircd-ircdev/ircd/s_user.c Wed Jun 22 02:58:52 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Miscellaneous user-related helper functions. - * @version $Id: s_user.c,v 1.21 2005/06/22 07:54:30 zolty Exp $ + * @version $Id: s_user.c,v 1.22 2005/06/22 09:58:52 zolty Exp $ */ #include "config.h" @@ -1141,6 +1141,10 @@ if (!IsNickEquivalent(flags)) { #if defined(DDB) + struct Ddb *ddbv; + + ddbv = ddb_find_key(DDB_VHOSTDB, cli_name(sptr)); + if (MyConnect(sptr)) { struct Flags oldflags; @@ -1154,9 +1158,17 @@ else SetNickRegistered(sptr); + if (ddbv && !IsHiddenHost(sptr)) + SetHiddenHost(sptr); + send_umode_out(cptr, sptr, &oldflags, IsRegistered(sptr)); } } + if (ddbv) + { + ircd_snprintf(0, cli_user(sptr)->host, HOSTLEN, ddb_content(ddbv)); + hide_hostmask(sptr, FLAG_HIDDENHOST); + } #endif /* defined(DDB) */ /* Notify change nick local/remote user */ @@ -1415,6 +1427,13 @@ chan = chan->next_channel) ClearBanValid(chan); break; +#elsif defined(DDB) || defined(SERVICES) + case FLAG_NICKREG: + /* Invalidate all bans against the user so we check them again */ + for (chan = (cli_user(cptr))->channel; chan; + chan = chan->next_channel) + ClearBanValid(chan); + break; #endif default: return 0; @@ -1423,17 +1442,23 @@ SetFlag(cptr, flag); #if defined(UNDERNET) if (!HasFlag(cptr, FLAG_HIDDENHOST) || !HasFlag(cptr, FLAG_ACCOUNT)) +#elsif defined(DDB) || defined(SERVICES) + if (!HasFlag(cptr, FLAG_HIDDENHOST) || !HasFlag(cptr, FLAG_NICKREG)) #else if (!HasFlag(cptr, FLAG_HIDDENHOST)) #endif return 0; +#if defined(UNDERNET) || defined(SERVICES) sendcmdto_common_channels_butone(cptr, CMD_QUIT, cptr, ":Registered"); ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, "%s.%s", -#if defined(UNDERNET) +# if defined(UNDERNET) cli_user(cptr)->account, feature_str(FEAT_HIDDEN_HOST)); -#else +# else cli_yxx(cptr), feature_str(FEAT_HIDDEN_HOST)); +# endif +#else + sendcmdto_common_channels_butone(cptr, CMD_QUIT, cptr, ":Changing virtualhost"); #endif /* ok, the client is now fully hidden, so let them know -- hikari */ @@ -1452,13 +1477,23 @@ if (!IsDelayedJoin(chan)) sendcmdto_channel_butserv_butone(cptr, CMD_JOIN, chan->channel, cptr, 0, "%H", chan->channel); - if (IsChanOp(chan) && HasVoice(chan)) + +#if defined(DDB) || defined(SERVICES) + if (IsChanOwner(chan) || IsChanOp(chan) || HasVoice(chan)) sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan->channel, cptr, 0, - "%H +ov %C %C", chan->channel, cptr, + "%H +%s%s%s %C %C", chan->channel, cptr, + IsChanOwner(chan) ? "q" : "", + IsChanOp(chan) ? "o" : "", + HasVoice(chan) ? "v" : "", cptr); - else if (IsChanOp(chan) || HasVoice(chan)) +#else + if (IsChanOp(chan) || HasVoice(chan)) sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan->channel, cptr, 0, - "%H +%c %C", chan->channel, IsChanOp(chan) ? 'o' : 'v', cptr); + "%H +%s%s %C %C", chan->channel, cptr, + IsChanOp(chan) ? "o" : "", + HasVoice(chan) ? "v" : "", + cptr); +#endif } return 0; } ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-06-22 10:01:41
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-06-22 10:01:35 UTC Modified files: TODO.es include/patchlevel.h Log message: actualizacion todo ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.27 ircd-ircdev/TODO.es:1.28 --- ircd-ircdev/TODO.es:1.27 Thu May 26 08:49:56 2005 +++ ircd-ircdev/TODO.es Wed Jun 22 03:01:25 2005 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.27 2005/05/26 15:49:56 zolty Exp $ +# $Id: TODO.es,v 1.28 2005/06/22 10:01:25 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -20,7 +20,6 @@ - [G] ¿Modo +M de canales?. - [G] Poner uuna Feature para elegir entre salir o no el nombre del servidor en los notices de auth y dnslookup al conectar. - - [D] Virtualhost personalizado a traves de la DDB. - [D] U-lines a traves de la DDB. - [D] Mejorar la inicializacion de las DDB con los eventos. Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.41 ircd-ircdev/include/patchlevel.h:1.42 --- ircd-ircdev/include/patchlevel.h:1.41 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/include/patchlevel.h Wed Jun 22 03:01:25 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.41 2005/06/22 09:58:52 zolty Exp $ + * $Id: patchlevel.h,v 1.42 2005/06/22 10:01:25 zolty Exp $ * */ -#define PATCHLEVEL ".alpha40" +#define PATCHLEVEL ".alpha41" #define RELEASE "1.0" ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-07-03 18:45:09
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-07-03 18:45:02 UTC Modified files: ChangeLog ChangeLog.es include/ddb.h include/s_user.h ircd/ddb.c ircd/ddb_events.c ircd/s_conf.c ircd/s_user.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-07-03 Toni García <zo...@ir...> 1.0.alpha41 * IPs cifradas (sólo IPv4) ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.42 ircd-ircdev/ChangeLog:1.43 --- ircd-ircdev/ChangeLog:1.42 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/ChangeLog Sun Jul 3 11:44:51 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.42 2005/06/22 09:58:52 zolty Exp $ +# $Id: ChangeLog,v 1.43 2005/07/03 18:44:51 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-07-03 Toni García <zo...@ir...> 1.0.alpha41 + * Crypted ips (only IPv4) + 2005-06-22 Toni García <zo...@ir...> 1.0.alpha40 * Vhosts table v * /LIST with wildcards Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.42 ircd-ircdev/ChangeLog.es:1.43 --- ircd-ircdev/ChangeLog.es:1.42 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/ChangeLog.es Sun Jul 3 11:44:51 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.42 2005/06/22 09:58:52 zolty Exp $ +# $Id: ChangeLog.es,v 1.43 2005/07/03 18:44:51 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-07-03 Toni García <zo...@ir...> 1.0.alpha41 + * IPs cifradas (sólo IPv4) + 2005-06-22 Toni García <zo...@ir...> 1.0.alpha40 * Tabla v de Vhosts * /LIST con comodines Index: ircd-ircdev/include/ddb.h diff -u ircd-ircdev/include/ddb.h:1.11 ircd-ircdev/include/ddb.h:1.12 --- ircd-ircdev/include/ddb.h:1.11 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/include/ddb.h Sun Jul 3 11:44:51 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Distributed DataBases structures, macros and functions. - * @version $Id: ddb.h,v 1.11 2005/06/22 09:58:52 zolty Exp $ + * @version $Id: ddb.h,v 1.12 2005/07/03 18:44:51 zolty Exp $ */ #ifndef INCLUDED_ddb_h #define INCLUDED_ddb_h @@ -70,7 +70,8 @@ #define DDB_CONFIGDB_MAX_CLONES_PER_IP "maxclones" /** Message to clients with too many clones from your ip */ #define DDB_CONFIGDB_MSG_TOO_MANY_FROM_IP "msgmanyperip" - +/** Key to crypt ips */ +#define DDB_CONFIGDB_IP_CRYPT_KEY "ipcryptkey" /* * PseudoBots @@ -163,6 +164,12 @@ extern void ddb_db_hash_write(unsigned char table); extern void ddb_db_end(void); +/* PROVISIONAL */ +extern int max_clones; +extern char *msg_many_clones; +extern char *ip_crypt_key; +extern unsigned int binary_ip_crypt_key[2]; + #endif /* defined(DDB) */ #endif /* INCLUDED_ddb_h */ Index: ircd-ircdev/include/s_user.h diff -u ircd-ircdev/include/s_user.h:1.7 ircd-ircdev/include/s_user.h:1.8 --- ircd-ircdev/include/s_user.h:1.7 Thu Mar 31 04:58:03 2005 +++ ircd-ircdev/include/s_user.h Sun Jul 3 11:44:51 2005 @@ -21,7 +21,7 @@ */ /** @file s_user.h * @brief Miscellaneous user-related helper functions. - * @version $Id: s_user.h,v 1.7 2005/03/31 12:58:03 zolty Exp $ + * @version $Id: s_user.h,v 1.8 2005/07/03 18:44:51 zolty Exp $ */ #ifndef INCLUDED_s_user_h #define INCLUDED_s_user_h @@ -123,7 +123,7 @@ extern void send_user_info(struct Client* to, char* names, int rpl, InfoFormatter fmt); -extern int hide_hostmask(struct Client *cptr, unsigned int flags); +extern int hide_hostmask(struct Client *cptr, const char *vhost, unsigned int flags); extern int set_user_mode(struct Client *cptr, struct Client *sptr, int parc, char *parv[]); extern int is_silenced(struct Client *sptr, struct Client *acptr); Index: ircd-ircdev/ircd/ddb.c diff -u ircd-ircdev/ircd/ddb.c:1.12 ircd-ircdev/ircd/ddb.c:1.13 --- ircd-ircdev/ircd/ddb.c:1.12 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/ircd/ddb.c Sun Jul 3 11:44:52 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Implementation of Distributed DataBase. - * @version $Id: ddb.c,v 1.12 2005/06/22 09:58:52 zolty Exp $ + * @version $Id: ddb.c,v 1.13 2005/07/03 18:44:52 zolty Exp $ */ #include "config.h" @@ -344,9 +344,7 @@ else ddb_del_key(table, keytemp); - /* TODO */ - /* Ejecutamos los eventos */ - /* if (!cptr && ddb_events_table[table]) */ +/* if (cptr && ddb_events_table[table]) */ if (ddb_events_table[table]) ddb_events_table[table](key, content, update); } Index: ircd-ircdev/ircd/ddb_events.c diff -u ircd-ircdev/ircd/ddb_events.c:1.8 ircd-ircdev/ircd/ddb_events.c:1.9 --- ircd-ircdev/ircd/ddb_events.c:1.8 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/ircd/ddb_events.c Sun Jul 3 11:44:52 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Events of Distributed DataBases. - * @version $Id: ddb_events.c,v 1.8 2005/06/22 09:58:52 zolty Exp $ + * @version $Id: ddb_events.c,v 1.9 2005/07/03 18:44:52 zolty Exp $ */ #include "config.h" @@ -38,6 +38,7 @@ #include "send.h" #include <stdio.h> +#include <stdlib.h> #include <string.h> /** It indicates events is initialized */ @@ -51,6 +52,11 @@ static void ddb_events_table_v(char *key, char *content, int update); static void ddb_events_table_z(char *key, char *content, int update); +/* PROVISIONAL */ +int max_clones; +char *msg_many_clones; +char *ip_crypt_key; +unsigned int binary_ip_crypt_key[2]; /** Initialize events module of %DDB Distributed DataBases. */ @@ -359,24 +365,18 @@ /* Droping Key */ if (!content) { - /* if (IsHiddenHost(cptr)) { - ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, "SINIP"); - hide_hostmask(cptr, FLAG_HIDDENHOST); - + hide_hostmask(cptr, 0, FLAG_NICKREG); } - */ } - else if (content) + else if (content && update) { - if (IsHiddenHost(cptr)) - { - ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, content); - hide_hostmask(cptr, FLAG_NICKREG); - - } - } + if (strcmp(content, cli_user(cptr)->host)) + hide_hostmask(cptr, content, FLAG_NICKREG); + } + else + hide_hostmask(cptr, content, FLAG_NICKREG); } } @@ -388,4 +388,38 @@ static void ddb_events_table_z(char *key, char *content, int update) { + if (content) + { + if (!strcmp(key, DDB_CONFIGDB_MAX_CLONES_PER_IP)) + max_clones = atoi(content); + else if (!strcmp(key, DDB_CONFIGDB_MSG_TOO_MANY_FROM_IP)) + msg_many_clones = content; + else if (!strcmp(key, DDB_CONFIGDB_IP_CRYPT_KEY)) + { + char keytmp[12 + 1]; + char c; + + ip_crypt_key = content; + strncpy(keytmp, content, 12); + keytmp[12] = '\0'; + c = keytmp[6]; + keytmp[6] = '\0'; + binary_ip_crypt_key[0] = base64toint(keytmp); + keytmp[6] = c; + binary_ip_crypt_key[1] = base64toint(keytmp + 6); + } + } + else + { + if (!strcmp(key, DDB_CONFIGDB_MAX_CLONES_PER_IP)) + max_clones = 0; + else if (!strcmp(key, DDB_CONFIGDB_MSG_TOO_MANY_FROM_IP)) + msg_many_clones = NULL; + else if (!strcmp(key, DDB_CONFIGDB_IP_CRYPT_KEY)) + { + ip_crypt_key = NULL; + binary_ip_crypt_key[0] = 0; + binary_ip_crypt_key[1] = 0; + } + } } Index: ircd-ircdev/ircd/s_conf.c diff -u ircd-ircdev/ircd/s_conf.c:1.18 ircd-ircdev/ircd/s_conf.c:1.19 --- ircd-ircdev/ircd/s_conf.c:1.18 Wed Jun 22 00:54:30 2005 +++ ircd-ircdev/ircd/s_conf.c Sun Jul 3 11:44:52 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief ircd configuration file driver - * @version $Id: s_conf.c,v 1.18 2005/06/22 07:54:30 zolty Exp $ + * @version $Id: s_conf.c,v 1.19 2005/07/03 18:44:52 zolty Exp $ */ #include "config.h" @@ -375,20 +375,17 @@ ddb = ddb_find_key(DDB_ILINEDB, (char *)ircd_ntoa(&cli_ip(cptr))); if (ddb && (clones = atoi(ddb_content(ddb)))) maxclones = clones; - else if ((ddb = ddb_find_key(DDB_CONFIGDB, DDB_CONFIGDB_MAX_CLONES_PER_IP)) - && (clones = atoi(ddb_content(ddb)))) - maxclones = clones; + else if (max_clones) /* DDB */ + maxclones = max_clones; else maxclones = aconf->maximum; if (IPcheck_nr(cptr) > maxclones) { - ddb = ddb_find_key(DDB_CONFIGDB, DDB_CONFIGDB_MSG_TOO_MANY_FROM_IP); - sendcmdto_one(&me, CMD_NOTICE, cptr, "%C :In the %s IRC Network only allows %d clones for your IP (%s)%s%s", cptr, feature_str(FEAT_NETWORK), maxclones, ircd_ntoa(&cli_ip(cptr)), - ddb ? ". " : "", ddb ? ddb_content(ddb) : ""); + msg_many_clones ? ". " : "", msg_many_clones ? msg_many_clones : ""); return ACR_TOO_MANY_FROM_IP; } #else Index: ircd-ircdev/ircd/s_user.c diff -u ircd-ircdev/ircd/s_user.c:1.22 ircd-ircdev/ircd/s_user.c:1.23 --- ircd-ircdev/ircd/s_user.c:1.22 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/ircd/s_user.c Sun Jul 3 11:44:52 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Miscellaneous user-related helper functions. - * @version $Id: s_user.c,v 1.22 2005/06/22 09:58:52 zolty Exp $ + * @version $Id: s_user.c,v 1.23 2005/07/03 18:44:52 zolty Exp $ */ #include "config.h" @@ -1165,10 +1165,8 @@ } } if (ddbv) - { - ircd_snprintf(0, cli_user(sptr)->host, HOSTLEN, ddb_content(ddbv)); - hide_hostmask(sptr, FLAG_HIDDENHOST); - } + hide_hostmask(sptr, ddb_content(ddbv), FLAG_HIDDENHOST); + #endif /* defined(DDB) */ /* Notify change nick local/remote user */ @@ -1406,11 +1404,12 @@ /** Set \a flag on \a cptr and possibly hide the client's hostmask. * @param[in,out] cptr User who is getting a new flag. + * @param[in] vhost Vhost of the user. * @param[in] flag Some flag that affects host-hiding (FLAG_HIDDENHOST, FLAG_ACCOUNT). * @return Zero. */ int -hide_hostmask(struct Client *cptr, unsigned int flag) +hide_hostmask(struct Client *cptr, const char *vhost, unsigned int flag) { struct Membership *chan; @@ -1443,7 +1442,8 @@ #if defined(UNDERNET) if (!HasFlag(cptr, FLAG_HIDDENHOST) || !HasFlag(cptr, FLAG_ACCOUNT)) #elsif defined(DDB) || defined(SERVICES) - if (!HasFlag(cptr, FLAG_HIDDENHOST) || !HasFlag(cptr, FLAG_NICKREG)) + /* if (!HasFlag(cptr, FLAG_HIDDENHOST) || !HasFlag(cptr, FLAG_NICKREG)) */ + if (1 == 0) #else if (!HasFlag(cptr, FLAG_HIDDENHOST)) #endif @@ -1459,6 +1459,53 @@ # endif #else sendcmdto_common_channels_butone(cptr, CMD_QUIT, cptr, ":Changing virtualhost"); + if (!vhost) + { + char ipcrypted[HOSTLEN + 1]; + + if (!ip_crypt_key) + { + strncpy(ipcrypted, "No.there.is.a.crypt.key", HOSTLEN); + } + /* IPv4 */ + else if (irc_in_addr_is_ipv4(&cli_ip(cptr))) + { + unsigned int v[2], x[2]; + unsigned int ts = 0; + + do { + x[0] = x[1] = 0; + v[0] = (binary_ip_crypt_key[0] & 0xffff0000) + ts; + v[1] = (ntohl(cli_ip(cptr).in6_16[6]) << 16) | ntohl(cli_ip(cptr).in6_16[7]); + + ircd_tea(v, binary_ip_crypt_key, x); + + /* Virtualhost format: qWeRty.AsDfGh.v4 */ + inttobase64(ipcrypted, x[0], 6); + ipcrypted[6] = '.'; + inttobase64(ipcrypted + 7, x[1], 6); + strncpy(ipcrypted + 13, ".v4", HOSTLEN); + log_write(LS_SYSTEM, L_CRIT, 0, "%u - %u", x[0], x[1]); + + /* No debería ocurrir nunca... */ + if (++ts == 65535) + { + strncpy(ipcrypted, cli_user(cptr)->realhost, HOSTLEN); + strncat(ipcrypted, ".v4", HOSTLEN); + break; + } + } while (strchr(ipcrypted, ']') || strchr(ipcrypted, '[')); + } + /* IPv6 */ + else + { + strncpy(ipcrypted, cli_user(cptr)->realhost, HOSTLEN); + strncat(ipcrypted, ".v6", HOSTLEN); + } + ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, ipcrypted); + } + else + ircd_snprintf(0, cli_user(cptr)->host, HOSTLEN, vhost); #endif /* ok, the client is now fully hidden, so let them know -- hikari */ @@ -1480,19 +1527,25 @@ #if defined(DDB) || defined(SERVICES) if (IsChanOwner(chan) || IsChanOp(chan) || HasVoice(chan)) + /* TODO-zoltan: Optimizar esto */ sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan->channel, cptr, 0, - "%H +%s%s%s %C %C", chan->channel, cptr, + "%H +%s%s%s %s%s%s%s%s", chan->channel, IsChanOwner(chan) ? "q" : "", IsChanOp(chan) ? "o" : "", HasVoice(chan) ? "v" : "", - cptr); + IsChanOwner(chan) ? cli_name(cptr) : "", + IsChanOwner(chan) ? " " : "", + IsChanOp(chan) ? cli_name(cptr) : "", + IsChanOp(chan) ? " " : "", + HasVoice(chan) ? cli_name(cptr) : ""); #else - if (IsChanOp(chan) || HasVoice(chan)) + if (IsChanOp(chan) && HasVoice(chan)) sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan->channel, cptr, 0, - "%H +%s%s %C %C", chan->channel, cptr, - IsChanOp(chan) ? "o" : "", - HasVoice(chan) ? "v" : "", + "%H +ov %C %C", chan->channel, cptr, cptr); + else if (IsChanOp(chan) || HasVoice(chan)) + sendcmdto_channel_butserv_butone(&me, CMD_MODE, chan->channel, cptr, 0, + "%H +%c %C", chan->channel, IsChanOp(chan) ? 'o' : 'v', cptr); #endif } return 0; @@ -1768,7 +1821,7 @@ if (!FlagHas(&setflags, FLAG_INVISIBLE) && IsInvisible(sptr)) ++UserStats.inv_clients; if (!FlagHas(&setflags, FLAG_HIDDENHOST) && do_host_hiding) - hide_hostmask(sptr, FLAG_HIDDENHOST); + hide_hostmask(sptr, 0, FLAG_HIDDENHOST); /* TODO-ZOLTAN */ send_umode_out(cptr, sptr, &setflags, prop); return 0; ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-07-03 20:22:01
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-07-03 20:21:52 UTC Modified files: ChangeLog ChangeLog.es include/client.h include/patchlevel.h include/res.h include/s_bsd.h include/s_misc.h ircd/hash.c ircd/ircd_auth.c ircd/ircd_crypt.c ircd/ircd_res.c ircd/list.c ircd/m_invite.c ircd/s_auth.c ircd/s_bsd.c ircd/s_conf.c ircd/s_misc.c ircd/s_serv.c ircd/s_user.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-07-03 Toni García <zo...@ir...> 1.0.alpha42 * Sincronización Undernet ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.43 ircd-ircdev/ChangeLog:1.44 --- ircd-ircdev/ChangeLog:1.43 Sun Jul 3 11:44:51 2005 +++ ircd-ircdev/ChangeLog Sun Jul 3 13:21:41 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.43 2005/07/03 18:44:51 zolty Exp $ +# $Id: ChangeLog,v 1.44 2005/07/03 20:21:41 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-07-03 Toni García <zo...@ir...> 1.0.alpha42 + * Undernet synchronization + 2005-07-03 Toni García <zo...@ir...> 1.0.alpha41 * Crypted ips (only IPv4) Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.43 ircd-ircdev/ChangeLog.es:1.44 --- ircd-ircdev/ChangeLog.es:1.43 Sun Jul 3 11:44:51 2005 +++ ircd-ircdev/ChangeLog.es Sun Jul 3 13:21:41 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.43 2005/07/03 18:44:51 zolty Exp $ +# $Id: ChangeLog.es,v 1.44 2005/07/03 20:21:41 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-07-03 Toni García <zo...@ir...> 1.0.alpha42 + * Sincronización Undernet + 2005-07-03 Toni García <zo...@ir...> 1.0.alpha41 * IPs cifradas (sólo IPv4) Index: ircd-ircdev/include/client.h diff -u ircd-ircdev/include/client.h:1.15 ircd-ircdev/include/client.h:1.16 --- ircd-ircdev/include/client.h:1.15 Mon Apr 11 01:44:59 2005 +++ ircd-ircdev/include/client.h Sun Jul 3 13:21:41 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Structures and functions for handling local clients. - * @version $Id: client.h,v 1.15 2005/04/11 08:44:59 zolty Exp $ + * @version $Id: client.h,v 1.16 2005/07/03 20:21:41 zolty Exp $ */ #ifndef INCLUDED_client_h #define INCLUDED_client_h @@ -225,8 +225,6 @@ struct SLink* con_confs; /**< Associated configuration records. */ HandlerType con_handler; /**< Message index into command table for parsing. */ - struct DNSReply* con_dns_reply; /**< DNS reply received during client - registration. */ struct ListingArgs* con_listing; /**< Current LIST status. */ unsigned long con_unreg; /**< Indicate what still needs to be done */ unsigned int con_max_sendq; /**< cached max send queue for client */ @@ -382,8 +380,6 @@ #define cli_confs(cli) con_confs(cli_connect(cli)) /** Get handler type for client. */ #define cli_handler(cli) con_handler(cli_connect(cli)) -/** Get DNS reply for client. */ -#define cli_dns_reply(cli) con_dns_reply(cli_connect(cli)) /** Get LIST status for client. */ #define cli_listing(cli) con_listing(cli_connect(cli)) /** Get cached max SendQ for client. */ @@ -463,8 +459,6 @@ #define con_confs(con) ((con)->con_confs) /** Get command handler for the connection. */ #define con_handler(con) ((con)->con_handler) -/** Get DNS reply for the connection. */ -#define con_dns_reply(con) ((con)->con_dns_reply) /** Get the LIST status for the connection. */ #define con_listing(con) ((con)->con_listing) /** Get remining steps before registration completes. */ Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.42 ircd-ircdev/include/patchlevel.h:1.43 --- ircd-ircdev/include/patchlevel.h:1.42 Wed Jun 22 03:01:25 2005 +++ ircd-ircdev/include/patchlevel.h Sun Jul 3 13:21:41 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.42 2005/06/22 10:01:25 zolty Exp $ + * $Id: patchlevel.h,v 1.43 2005/07/03 20:21:41 zolty Exp $ * */ -#define PATCHLEVEL ".alpha41" +#define PATCHLEVEL ".alpha42" #define RELEASE "1.0" Index: ircd-ircdev/include/res.h diff -u ircd-ircdev/include/res.h:1.7 ircd-ircdev/include/res.h:1.8 --- ircd-ircdev/include/res.h:1.7 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/res.h Sun Jul 3 13:21:41 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief IRC resolver API. - * @version $Id: res.h,v 1.7 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: res.h,v 1.8 2005/07/03 20:21:41 zolty Exp $ */ #ifndef INCLUDED_res_h @@ -88,19 +88,8 @@ unsigned short port; /**< Port number, host-endian. */ }; -/** DNS reply structure. */ -struct DNSReply -{ - char *h_name; /**< Hostname. */ - struct irc_in_addr addr; /**< IP address. */ -}; - -/** DNS callback structure. */ -struct DNSQuery -{ - void *vptr; /**< pointer used by callback to identify request */ - void (*callback)(void* vptr, struct DNSReply *reply); /**< callback to call */ -}; +/** DNS callback function signature. */ +typedef void (*dns_callback_f)(void *vptr, const struct irc_in_addr *addr, const char *h_name); /** DNS query and response header. */ typedef struct @@ -145,8 +134,8 @@ extern size_t cres_mem(struct Client* cptr); extern void delete_resolver_queries(const void *vptr); extern void report_dns_servers(struct Client *source_p, const struct StatDesc *sd, char *param); -extern void gethost_byname(const char *name, const struct DNSQuery *query); -extern void gethost_byaddr(const struct irc_in_addr *addr, const struct DNSQuery *query); +extern void gethost_byname(const char *name, dns_callback_f callback, void *ctx); +extern void gethost_byaddr(const struct irc_in_addr *addr, dns_callback_f callback, void *ctx); /** Evaluate to non-zero if \a ADDR is a valid address (not all 0s and not all 1s). */ #define irc_in_addr_valid(ADDR) (((ADDR)->in6_16[0] && ~(ADDR)->in6_16[0]) \ Index: ircd-ircdev/include/s_bsd.h diff -u ircd-ircdev/include/s_bsd.h:1.6 ircd-ircdev/include/s_bsd.h:1.7 --- ircd-ircdev/include/s_bsd.h:1.6 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/s_bsd.h Sun Jul 3 13:21:41 2005 @@ -21,7 +21,7 @@ */ /** @file s_bsd.h * @brief Wrapper functions to avoid direct use of BSD APIs. - * @version $Id: s_bsd.h,v 1.6 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: s_bsd.h,v 1.7 2005/07/03 20:21:41 zolty Exp $ */ #ifndef INCLUDED_s_bsd_h #define INCLUDED_s_bsd_h @@ -81,7 +81,6 @@ */ extern unsigned int deliver_it(struct Client *cptr, struct MsgQ *buf); extern int connect_server(struct ConfItem* aconf, struct Client* by); -extern void release_dns_reply(struct Client* cptr); extern int net_close_unregistered_connections(struct Client* source); extern void close_connection(struct Client *cptr); extern void add_connection(struct Listener* listener, int fd); Index: ircd-ircdev/include/s_misc.h diff -u ircd-ircdev/include/s_misc.h:1.4 ircd-ircdev/include/s_misc.h:1.5 --- ircd-ircdev/include/s_misc.h:1.4 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/s_misc.h Sun Jul 3 13:21:41 2005 @@ -21,7 +21,7 @@ */ /** @file s_misc.h * @brief Miscellaneous support functions and declarations. - * @version $Id: s_misc.h,v 1.4 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: s_misc.h,v 1.5 2005/07/03 20:21:41 zolty Exp $ */ #ifndef INCLUDED_s_misc_h #define INCLUDED_s_misc_h @@ -105,7 +105,6 @@ struct Client *sptr, const char *pattern, ...); extern void initstats(void); extern char *date(time_t clock); -extern void get_sockhost(struct Client *cptr, char *host); extern int vexit_client_msg(struct Client *cptr, struct Client *bcptr, struct Client *sptr, const char *pattern, va_list vl); extern void tstats(struct Client *cptr, const struct StatDesc *sd, Index: ircd-ircdev/ircd/hash.c diff -u ircd-ircdev/ircd/hash.c:1.11 ircd-ircdev/ircd/hash.c:1.12 --- ircd-ircdev/ircd/hash.c:1.11 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/ircd/hash.c Sun Jul 3 13:21:42 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Hash table management. - * @version $Id: hash.c,v 1.11 2005/06/22 09:58:52 zolty Exp $ + * @version $Id: hash.c,v 1.12 2005/07/03 20:21:42 zolty Exp $ * * This file used to use some very complicated hash function. Now it * uses CRC-32, but effectively remaps each input byte according to a @@ -40,6 +40,7 @@ #include "ircd_reply.h" #include "ircd_string.h" #include "ircd.h" +#include "match.h" #include "msg.h" #include "numeric.h" #include "random.h" Index: ircd-ircdev/ircd/ircd_auth.c diff -u ircd-ircdev/ircd/ircd_auth.c:1.6 ircd-ircdev/ircd/ircd_auth.c:1.7 --- ircd-ircdev/ircd/ircd_auth.c:1.6 Sat May 7 15:23:40 2005 +++ ircd-ircdev/ircd/ircd_auth.c Sun Jul 3 13:21:42 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief IAuth client implementation for an IRC server. - * @version $Id: ircd_auth.c,v 1.6 2005/05/07 22:23:40 zolty Exp $ + * @version $Id: ircd_auth.c,v 1.7 2005/07/03 20:21:42 zolty Exp $ */ #include "config.h" #include "client.h" @@ -84,7 +84,6 @@ struct Timer i_reconn_timer; /**< when to reconnect the connection */ struct Timer i_request_timer; /**< when the current request times out */ struct IAuthFlags i_flags; /**< connection state/status/flags */ - struct DNSQuery i_query; /**< DNS lookup for iauth server */ unsigned int i_recvM; /**< messages received */ unsigned int i_sendM; /**< messages sent */ unsigned int i_recvK; /**< kilobytes received */ @@ -408,13 +407,13 @@ * @param[in] vptr Pointer to the IAuth struct. * @param[in] he DNS reply parameters. */ -static void iauth_dns_callback(void *vptr, struct DNSReply *he) +static void iauth_dns_callback(void *vptr, const struct irc_in_addr *addr, const char *h_name) { struct IAuth *iauth = vptr; - if (!he) { + if (!addr) { log_write(LS_IAUTH, L_NOTICE, 0, "IAuth connection to %s failed: host lookup failed", i_host(iauth)); } else { - memcpy(&i_addr(iauth).addr, &he->addr, sizeof(i_addr(iauth).addr)); + memcpy(&i_addr(iauth).addr, &addr, sizeof(i_addr(iauth).addr)); if (!irc_in_addr_valid(&i_addr(iauth).addr)) { log_write(LS_IAUTH, L_NOTICE, 0, "IAuth connection to %s failed: host came back as unresolved", i_host(iauth)); return; @@ -463,9 +462,7 @@ log_write(LS_IAUTH, L_DEBUG, 0, "IAuth attempt connection to %s port %p.", i_host(iauth), i_port(iauth)); if (!irc_in_addr_valid(&i_addr(iauth).addr) && !ircd_aton(&i_addr(iauth).addr, i_host(iauth))) { - i_query(iauth).vptr = iauth; - i_query(iauth).callback = iauth_dns_callback; - gethost_byname(i_host(iauth), &i_query(iauth)); + gethost_byname(i_host(iauth), iauth_dns_callback, iauth); return; } local = irc_in_addr_is_ipv4(&i_addr(iauth).addr) ? &VirtualHost_v4 : &VirtualHost_v6; Index: ircd-ircdev/ircd/ircd_crypt.c diff -u ircd-ircdev/ircd/ircd_crypt.c:1.4 ircd-ircdev/ircd/ircd_crypt.c:1.5 --- ircd-ircdev/ircd/ircd_crypt.c:1.4 Mon Mar 21 10:39:07 2005 +++ ircd-ircdev/ircd/ircd_crypt.c Sun Jul 3 13:21:42 2005 @@ -22,7 +22,7 @@ /** * @file * @brief Core password encryption routines. - * @version $Id: ircd_crypt.c,v 1.4 2005/03/21 18:39:07 zolty Exp $ + * @version $Id: ircd_crypt.c,v 1.5 2005/07/03 20:21:42 zolty Exp $ * * This is a new look crypto API for ircu, it can handle different * password formats by the grace of magic tokens at the beginning of the @@ -202,9 +202,13 @@ /* try to use native crypt for an old-style (untagged) password */ if (strlen(salt) > 2) { + char *s; temp_hashed_pass = (char*)ircd_crypt_native(key, salt); if (!ircd_strcmp(temp_hashed_pass, salt)) - return strdup(temp_hashed_pass); + { + DupString(s, temp_hashed_pass); + return s; + } } return NULL; Index: ircd-ircdev/ircd/ircd_res.c diff -u ircd-ircdev/ircd/ircd_res.c:1.9 ircd-ircdev/ircd/ircd_res.c:1.10 --- ircd-ircdev/ircd/ircd_res.c:1.9 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/ircd/ircd_res.c Sun Jul 3 13:21:42 2005 @@ -41,7 +41,7 @@ */ /** @file * @brief IRC resolver functions. - * @version $Id: ircd_res.c,v 1.9 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: ircd_res.c,v 1.10 2005/07/03 20:21:42 zolty Exp $ */ #include "client.h" #include "ircd_alloc.h" @@ -137,17 +137,19 @@ time_t timeout; /**< When this request times out. */ struct irc_in_addr addr; /**< Address for this request. */ char *name; /**< Hostname for this request. */ - struct DNSQuery query; /**< Query callback for this request. */ + dns_callback_f callback; /**< Callback function on completion. */ + void *callback_ctx; /**< Context pointer for callback. */ }; /** Base of request list. */ static struct dlink request_list; static void rem_request(struct reslist *request); -static struct reslist *make_request(const struct DNSQuery *query); -static void do_query_name(const struct DNSQuery *query, + +static struct reslist *make_request(dns_callback_f callback, void *ctx); +static void do_query_name(dns_callback_f callback, void *ctx, const char* name, struct reslist *request, int); -static void do_query_number(const struct DNSQuery *query, +static void do_query_number(dns_callback_f callback, void *ctx, const struct irc_in_addr *, struct reslist *request); static void query_name(const char *name, int query_class, int query_type, @@ -156,7 +158,6 @@ static void resend_query(struct reslist *request); static int proc_answer(struct reslist *request, HEADER *header, char *, char *); static struct reslist *find_id(int id); -static struct DNSReply *make_dnsreply(struct reslist *request); static void res_readreply(struct Event *ev); static void timeout_resolver(struct Event *notused); @@ -270,7 +271,7 @@ * @return Newly allocated and linked-in reslist. */ static struct reslist * -make_request(const struct DNSQuery* query) +make_request(dns_callback_f callback, void *ctx) { struct reslist *request; @@ -286,7 +287,8 @@ request->resend = 1; request->timeout = feature_int(FEAT_IRCD_RES_TIMEOUT); memset(&request->addr, 0, sizeof(request->addr)); - memcpy(&request->query, query, sizeof(request->query)); + request->callback = callback; + request->callback_ctx = ctx; add_dlink(&request->node, &request_list); return(request); @@ -335,7 +337,7 @@ if (--request->retries <= 0) { Debug((DEBUG_DNS, "Request %p out of retries; destroying", request)); - (*request->query.callback)(request->query.vptr, 0); + (*request->callback)(request->callback_ctx, NULL, NULL); rem_request(request); continue; } @@ -374,7 +376,7 @@ { next_ptr = ptr->next; request = (struct reslist*)ptr; - if (vptr == request->query.vptr) { + if (vptr == request->callback_ctx) { Debug((DEBUG_DNS, "Removing request %p with vptr %p", request, vptr)); rem_request(request); } @@ -439,9 +441,9 @@ * @param[in] query Callback information. */ void -gethost_byname(const char *name, const struct DNSQuery *query) +gethost_byname(const char *name, dns_callback_f callback, void *ctx) { - do_query_name(query, name, NULL, T_AAAA); + do_query_name(callback, ctx, name, NULL, T_AAAA); } /** Try to look up hostname for an address. @@ -449,9 +451,9 @@ * @param[in] query Callback information. */ void -gethost_byaddr(const struct irc_in_addr *addr, const struct DNSQuery *query) +gethost_byaddr(const struct irc_in_addr *addr, dns_callback_f callback, void *ctx) { - do_query_number(query, addr, NULL); + do_query_number(callback, ctx, addr, NULL); } /** Send a query to look up the address for a name. @@ -461,7 +463,7 @@ * @param[in] type Preferred request type. */ static void -do_query_name(const struct DNSQuery *query, const char *name, +do_query_name(dns_callback_f callback, void *ctx, const char *name, struct reslist *request, int type) { char host_name[HOSTLEN + 1]; @@ -471,7 +473,7 @@ if (request == NULL) { - request = make_request(query); + request = make_request(callback, ctx); DupString(request->name, host_name); #ifdef IPV6 if (type != T_A) @@ -492,7 +494,7 @@ * @param[in] request DNS lookup structure (may be NULL). */ static void -do_query_number(const struct DNSQuery *query, const struct irc_in_addr *addr, +do_query_number(dns_callback_f callback, void *ctx, const struct irc_in_addr *addr, struct reslist *request) { char ipbuf[128]; @@ -537,7 +539,7 @@ } if (request == NULL) { - request = make_request(query); + request = make_request(callback, ctx); request->state= REQ_PTR; request->type = T_PTR; memcpy(&request->addr, addr, sizeof(request->addr)); @@ -597,15 +599,15 @@ switch(request->type) { case T_PTR: - do_query_number(NULL, &request->addr, request); + do_query_number(NULL, NULL, &request->addr, request); break; case T_A: - do_query_name(NULL, request->name, request, request->type); + do_query_name(NULL, NULL, request->name, request, request->type); break; case T_AAAA: /* didn't work, try A */ if (request->state == REQ_AAAA) - do_query_name(NULL, request->name, request, T_A); + do_query_name(NULL, NULL, request->name, request, T_A); default: break; } @@ -774,7 +776,6 @@ char buf[sizeof(HEADER) + MAXPACKET]; HEADER *header; struct reslist *request = NULL; - struct DNSReply *reply = NULL; unsigned int rc; int answer_count; @@ -837,7 +838,7 @@ * send any more (no retries granted). */ Debug((DEBUG_DNS, "Request %p has bad response (state %d type %d rcode %d)", request, request->state, request->type, header->rcode)); - (*request->query.callback)(request->query.vptr, 0); + (*request->callback)(request->callback_ctx, NULL, NULL); rem_request(request); } } @@ -861,7 +862,7 @@ * don't bother trying again, the client address doesn't resolve */ Debug((DEBUG_DNS, "Request %p PTR had empty name", request)); - (*request->query.callback)(request->query.vptr, reply); + (*request->callback)(request->callback_ctx, NULL, NULL); rem_request(request); return; } @@ -872,10 +873,10 @@ */ #ifdef IPV6 if (!irc_in_addr_is_ipv4(&request->addr)) - do_query_name(&request->query, request->name, NULL, T_AAAA); + do_query_name(request->callback, request->callback_ctx, request->name, NULL, T_AAAA); else #endif - do_query_name(&request->query, request->name, NULL, T_A); + do_query_name(request->callback, request->callback_ctx, request->name, NULL, T_A); Debug((DEBUG_DNS, "Request %p switching to forward resolution", request)); rem_request(request); } @@ -884,8 +885,7 @@ /* * got a name and address response, client resolved */ - reply = make_dnsreply(request); - (*request->query.callback)(request->query.vptr, (reply) ? reply : 0); + (*request->callback)(request->callback_ctx, &request->addr, request->name); Debug((DEBUG_DNS, "Request %p got forward resolution", request)); rem_request(request); } @@ -903,23 +903,6 @@ } } -/** Build a DNSReply for a completed request. - * @param[in] request Completed DNS request. - * @return Newly allocated DNSReply containing host name and address. - */ -static struct DNSReply * -make_dnsreply(struct reslist *request) -{ - struct DNSReply *cp; - assert(request != 0); - - cp = (struct DNSReply *)MyMalloc(sizeof(struct DNSReply)); - - DupString(cp->h_name, request->name); - memcpy(&cp->addr, &request->addr, sizeof(cp->addr)); - return(cp); -} - /** Statistics callback to list DNS servers. * @param[in] source_p Client requesting statistics. * @param[in] sd Stats descriptor for request (ignored). Index: ircd-ircdev/ircd/list.c diff -u ircd-ircdev/ircd/list.c:1.8 ircd-ircdev/ircd/list.c:1.9 --- ircd-ircdev/ircd/list.c:1.8 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/ircd/list.c Sun Jul 3 13:21:42 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Singly and doubly linked list manipulation implementation. - * @version $Id: list.c,v 1.8 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: list.c,v 1.9 2005/07/03 20:21:42 zolty Exp $ */ #include "config.h" @@ -168,10 +168,6 @@ Debug((DEBUG_LIST, "Deallocating connection %p", con)); - if (con_dns_reply(con)) { - MyFree(con_dns_reply(con)); - con_dns_reply(con) = 0; - } if (-1 < con_fd(con)) close(con_fd(con)); MsgQClear(&(con_sendQ(con))); Index: ircd-ircdev/ircd/m_invite.c diff -u ircd-ircdev/ircd/m_invite.c:1.12 ircd-ircdev/ircd/m_invite.c:1.13 --- ircd-ircdev/ircd/m_invite.c:1.12 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/ircd/m_invite.c Sun Jul 3 13:21:42 2005 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: m_invite.c,v 1.12 2005/06/22 07:54:29 zolty Exp $ + * $Id: m_invite.c,v 1.13 2005/07/03 20:21:42 zolty Exp $ * */ @@ -179,7 +179,7 @@ if (MyConnect(acptr)) { add_invite(acptr, chptr); sendcmdto_one(sptr, CMD_INVITE, acptr, "%s %H", cli_name(acptr), chptr); - } else { + } else if (!IsLocalChannel(chptr->chname)) { sendcmdto_one(sptr, CMD_INVITE, acptr, "%s %H %Tu", cli_name(acptr), chptr, chptr->creationtime); } Index: ircd-ircdev/ircd/s_auth.c diff -u ircd-ircdev/ircd/s_auth.c:1.11 ircd-ircdev/ircd/s_auth.c:1.12 --- ircd-ircdev/ircd/s_auth.c:1.11 Mon Mar 21 10:39:11 2005 +++ ircd-ircdev/ircd/s_auth.c Sun Jul 3 13:21:42 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Implementation of DNS and ident lookups. - * @version $Id: s_auth.c,v 1.11 2005/03/21 18:39:11 zolty Exp $ + * @version $Id: s_auth.c,v 1.12 2005/07/03 20:21:42 zolty Exp $ */ #include "config.h" @@ -106,7 +106,7 @@ * @return Non-zero if the hostname is valid. */ static int -auth_verify_hostname(char *host, int maxlen) +auth_verify_hostname(const char *host, int maxlen) { int i; @@ -299,7 +299,7 @@ * @param vptr The pending struct AuthRequest. * @param hp Pointer to the DNS reply (or NULL, if lookup failed). */ -static void auth_dns_callback(void* vptr, struct DNSReply* hp) +static void auth_dns_callback(void* vptr, const struct irc_in_addr *addr, const char *h_name) { struct AuthRequest* auth = (struct AuthRequest*) vptr; assert(auth); @@ -310,31 +310,30 @@ */ ClearDNSPending(auth); - if (hp) { + if (addr) { /* * Verify that the host to ip mapping is correct both ways and that * the ip#(s) for the socket is listed for the host. */ - if (irc_in_addr_cmp(&hp->addr, &cli_ip(auth->client))) { + if (irc_in_addr_cmp(addr, &cli_ip(auth->client))) { if (IsUserPort(auth->client)) sendheader(auth->client, REPORT_IP_MISMATCH); sendto_opmask_butone(0, SNO_IPMISMATCH, "IP# Mismatch: %s != %s[%s]", - cli_sock_ip(auth->client), hp->h_name, - ircd_ntoa(&hp->addr)); + cli_sock_ip(auth->client), h_name, + ircd_ntoa(addr)); if (feature_bool(FEAT_KILL_IPMISMATCH)) { auth_kill_client(auth); return; } } - else if (!auth_verify_hostname(hp->h_name, HOSTLEN)) + else if (!auth_verify_hostname(h_name, HOSTLEN)) { if (IsUserPort(auth->client)) sendheader(auth->client, REPORT_INVAL_DNS); } else { - cli_dns_reply(auth->client) = hp; - ircd_strncpy(cli_sockhost(auth->client), hp->h_name, HOSTLEN); + ircd_strncpy(cli_sockhost(auth->client), h_name, HOSTLEN); if (IsUserPort(auth->client)) sendheader(auth->client, REPORT_FIN_DNS); } @@ -549,15 +548,9 @@ if (irc_in_addr_is_loopback(&cli_ip(client))) strcpy(cli_sockhost(client), cli_name(&me)); else { - struct DNSQuery query; - - query.vptr = auth; - query.callback = auth_dns_callback; - if (IsUserPort(auth->client)) sendheader(client, REPORT_DO_DNS); - - gethost_byaddr(&cli_ip(client), &query); + gethost_byaddr(&cli_ip(client), auth_dns_callback, auth); SetDNSPending(auth); } } Index: ircd-ircdev/ircd/s_bsd.c diff -u ircd-ircdev/ircd/s_bsd.c:1.15 ircd-ircdev/ircd/s_bsd.c:1.16 --- ircd-ircdev/ircd/s_bsd.c:1.15 Wed Jun 22 00:54:30 2005 +++ ircd-ircdev/ircd/s_bsd.c Sun Jul 3 13:21:42 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Functions that now (or in the past) relied on BSD APIs. - * @version $Id: s_bsd.c,v 1.15 2005/06/22 07:54:30 zolty Exp $ + * @version $Id: s_bsd.c,v 1.16 2005/07/03 20:21:42 zolty Exp $ */ #include "config.h" @@ -175,14 +175,13 @@ * @param vptr The struct ConfItem representing the Connect block. * @param hp A pointer to the DNS lookup results (NULL on failure). */ -static void connect_dns_callback(void* vptr, struct DNSReply* hp) +static void connect_dns_callback(void* vptr, const struct irc_in_addr *addr, const char *h_name) { struct ConfItem* aconf = (struct ConfItem*) vptr; assert(aconf); aconf->dns_pending = 0; - if (hp) { - memcpy(&aconf->address, &hp->addr, sizeof(aconf->address)); - MyFree(hp); + if (addr) { + memcpy(&aconf->address, addr, sizeof(aconf->address)); connect_server(aconf, 0); } else @@ -326,21 +325,6 @@ return bytes_written; } -/** Free the client's DNS reply, if any. - * @param cptr Client to operate on. - */ -void release_dns_reply(struct Client* cptr) -{ - assert(0 != cptr); - assert(MyConnect(cptr)); - - if (cli_dns_reply(cptr)) { - MyFree(cli_dns_reply(cptr)->h_name); - MyFree(cli_dns_reply(cptr)); - cli_dns_reply(cptr) = 0; - } -} - /** Complete non-blocking connect()-sequence. Check access and * terminate connection, if trouble detected. * @param cptr Client to which we have connected, with all ConfItem structs attached. @@ -541,27 +525,32 @@ */ os_disable_options(fd); - /* - * Add this local client to the IPcheck registry. - * - * If they're throttled, murder them, but tell them why first. - */ - if (!IPcheck_local_connect(&addr.addr, &next_target) && !listener->server) + if (listener->server) { - ++ServerStats->is_ref; - write(fd, throttle_message, strlen(throttle_message)); - close(fd); - return; + new_client = make_client(0, STAT_UNKNOWN_SERVER); + } + else + { + /* + * Add this local client to the IPcheck registry. + * + * If they're throttled, murder them, but tell them why first. + */ + if (!IPcheck_local_connect(&addr.addr, &next_target)) + { + ++ServerStats->is_ref; + write(fd, throttle_message, strlen(throttle_message)); + close(fd); + return; + } + new_client = make_client(0, STAT_UNKNOWN_USER); + SetIPChecked(new_client); } - - new_client = make_client(0, ((listener->server) ? - STAT_UNKNOWN_SERVER : STAT_UNKNOWN_USER)); /* * Copy ascii address to 'sockhost' just in case. Then we have something * valid to put into error messages... */ - SetIPChecked(new_client); ircd_ntoa_r(cli_sock_ip(new_client), &addr.addr); strcpy(cli_sockhost(new_client), cli_sock_ip(new_client)); memcpy(&cli_ip(new_client), &addr.addr, sizeof(cli_ip(new_client))); @@ -766,14 +755,8 @@ if (!irc_in_addr_valid(&aconf->address.addr) && !ircd_aton(&aconf->address.addr, aconf->host)) { char buf[HOSTLEN + 1]; - struct DNSQuery query; - - query.vptr = aconf; - query.callback = connect_dns_callback; host_from_uh(buf, aconf->host, HOSTLEN); - buf[HOSTLEN] = '\0'; - - gethost_byname(buf, &query); + gethost_byname(buf, connect_dns_callback, aconf); aconf->dns_pending = 1; return 0; } Index: ircd-ircdev/ircd/s_conf.c diff -u ircd-ircdev/ircd/s_conf.c:1.19 ircd-ircdev/ircd/s_conf.c:1.20 --- ircd-ircdev/ircd/s_conf.c:1.19 Sun Jul 3 11:44:52 2005 +++ ircd-ircdev/ircd/s_conf.c Sun Jul 3 13:21:42 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief ircd configuration file driver - * @version $Id: s_conf.c,v 1.19 2005/07/03 18:44:52 zolty Exp $ + * @version $Id: s_conf.c,v 1.20 2005/07/03 20:21:42 zolty Exp $ */ #include "config.h" @@ -232,16 +232,13 @@ * @param vptr Pointer to struct ConfItem for the block. * @param hp DNS reply, or NULL if the lookup failed. */ -static void conf_dns_callback(void* vptr, struct DNSReply* hp) +static void conf_dns_callback(void* vptr, const struct irc_in_addr *addr, const char *h_name) { struct ConfItem* aconf = (struct ConfItem*) vptr; assert(aconf); aconf->dns_pending = 0; - if (hp) - { - memcpy(&aconf->address.addr, &hp->addr, sizeof(aconf->address.addr)); - MyFree(hp); - } + if (addr) + memcpy(&aconf->address.addr, addr, sizeof(aconf->address.addr)); } /** Start a nameserver lookup of the conf host. If the conf entry is @@ -252,13 +249,8 @@ { if (!aconf->dns_pending) { char buf[HOSTLEN + 1]; - struct DNSQuery query; - query.vptr = aconf; - query.callback = conf_dns_callback; host_from_uh(buf, aconf->host, HOSTLEN); - buf[HOSTLEN] = '\0'; - - gethost_byname(buf, &query); + gethost_byname(buf, conf_dns_callback, aconf); aconf->dns_pending = 1; } } @@ -402,11 +394,9 @@ enum AuthorizationCheckResult attach_iline(struct Client* cptr) { struct ConfItem* aconf; - struct DNSReply* hp; assert(0 != cptr); - hp = cli_dns_reply(cptr); for (aconf = GlobalConfList; aconf; aconf = aconf->next) { if (aconf->status != CONF_CLIENT) continue; @@ -420,7 +410,7 @@ if (match(aconf->username, cli_username(cptr))) continue; } - if (aconf->host && (!hp || match(aconf->host, ... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-09-01 11:25:59
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-09-01 11:25:52 UTC Modified files: ChangeLog ChangeLog.es RELEASE.NOTES RELEASE.NOTES.es configure configure.in doc/ircd.sample-en.conf doc/ircd.sample-es.conf doc/en/features.txt doc/en/log.txt doc/en/api/features.txt doc/en/api/modebuf.txt doc/en/api/motd.txt include/channel.h include/ircd_features.h include/numeric.h include/patchlevel.h include/s_conf.h include/supported.h include/sys.h ircd/IPcheck.c ircd/channel.c ircd/class.c ircd/engine_epoll.c ircd/engine_select.c ircd/gline.c ircd/ircd.c ircd/ircd_auth.c ircd/ircd_features.c ircd/ircd_log.c ircd/ircd_parser.y ircd/listener.c ircd/m_burst.c ircd/m_join.c ircd/m_kick.c ircd/m_trace.c ircd/parse.c ircd/s_bsd.c ircd/s_conf.c ircd/s_err.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-09-01 Toni García <zo...@ir...> 1.0.alpha43 * Sincronización Undernet ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.44 ircd-ircdev/ChangeLog:1.45 --- ircd-ircdev/ChangeLog:1.44 Sun Jul 3 13:21:41 2005 +++ ircd-ircdev/ChangeLog Thu Sep 1 04:25:42 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.44 2005/07/03 20:21:41 zolty Exp $ +# $Id: ChangeLog,v 1.45 2005/09/01 11:25:42 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-09-01 Toni García <zo...@ir...> 1.0.alpha43 + * Undernet synchronization + 2005-07-03 Toni García <zo...@ir...> 1.0.alpha42 * Undernet synchronization Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.44 ircd-ircdev/ChangeLog.es:1.45 --- ircd-ircdev/ChangeLog.es:1.44 Sun Jul 3 13:21:41 2005 +++ ircd-ircdev/ChangeLog.es Thu Sep 1 04:25:42 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.44 2005/07/03 20:21:41 zolty Exp $ +# $Id: ChangeLog.es,v 1.45 2005/09/01 11:25:42 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-09-01 Toni García <zo...@ir...> 1.0.alpha43 + * Sincronización Undernet + 2005-07-03 Toni García <zo...@ir...> 1.0.alpha42 * Sincronización Undernet Index: ircd-ircdev/RELEASE.NOTES diff -u ircd-ircdev/RELEASE.NOTES:1.2 ircd-ircdev/RELEASE.NOTES:1.3 --- ircd-ircdev/RELEASE.NOTES:1.2 Sat Apr 23 08:57:00 2005 +++ ircd-ircdev/RELEASE.NOTES Thu Sep 1 04:25:42 2005 @@ -8,7 +8,7 @@ ircu2.10.07 (based on IRC-Hispano ircdh and Terraircu). IRC-Dev ircd is only compatible with servers that implement the P10 protocol. It has been tested to link against old ircds, but some features (notably -IPv6 support) are not supported by old ircds. +IPv6 support and oplevels) are not supported by old ircds. Enhancements: @@ -34,6 +34,19 @@ and allows that external program to assign an account stamp to the incoming user. +A new channel mode, +D, has been added for auditorium-style channels. +These are channels where most users listen but do not speak or receive +ops or voice. The effect of +D is that the server waits to send the +JOIN message for new users until the user gets ops or voice or sends a +message to the channel. A list of join-delayed users in a channel may +be retrieved by using /NAMES -d #channel. The response to /NAMES -d +uses the same format as numeric 353, but uses numeric 355 instead. If +an op removes +D while there are still join-delayed users, the server +automatically sets mode +d, and removes +d when the last user's join +is shown. It is not possible to set channel mode +d manually; its +purpose is to warn channel users that there are "hidden" users in the +channel. + More than one hashing mechanism is now supported for oper passwords, and a new tool (ircd/umkpasswd) is provided to generate them. Index: ircd-ircdev/RELEASE.NOTES.es diff -u ircd-ircdev/RELEASE.NOTES.es:1.2 ircd-ircdev/RELEASE.NOTES.es:1.3 --- ircd-ircdev/RELEASE.NOTES.es:1.2 Sat Apr 23 08:57:02 2005 +++ ircd-ircdev/RELEASE.NOTES.es Thu Sep 1 04:25:42 2005 @@ -9,7 +9,7 @@ Terraircu). El ircd de IRC-Dev es compatible solamente con servidores que tengan implementado el protocolo P10. Ha sido probado el link con ircds antiguos, pero muchas caracteristicas (notablemente el soporte -IPv6) no están soportadas por ircds viejos. +IPv6 y oplevels) no están soportadas por ircds viejos. Implementaciones: @@ -36,6 +36,20 @@ el servidor y permite que ese programa externo asigne una cuenta de acceso al usuario entrante. +Un nuevo modo de canal, +d, se ha agregado para los canales estilo +auditorio. Estos son canales donde la mayoría de los usuarios escuchan +pero no hablan ni reciben ops o voz. El efecto de +D es que el servidor +espera para enviar el mensaje del JOIN para los nuevos usuarios hasta +que el usuario consigue ops o voz o envía un mensaje al canal. La lista +de usuarios con entrada retrasada en un canal se puede sacar usando +/NAMES -d #canal. La respuesta al /NAMES -d utiliza el mismo formato que +el numérico 353, pero usa el numérico 355. Si un op quita el +D mientras +que todavía hay usuarios con entrada retrasada, el servidor ajusta el modo ++d automáticamente, y quita +d cuando se muestra la entrada del ultimo +usuario. No es posible fijar el modo +d del canal manualmente; su +próposito es advertir a los usuarios del canal de que hay usuarios +"ocultos" en el canal. + Más de un mecanismo del hashing está soportado ahora para las contraseñas de operador (IRCOP), y se proporciona una herramienta nueva (ircd/umkpasswd) para generarlas. Index: ircd-ircdev/configure diff -u ircd-ircdev/configure:1.18 ircd-ircdev/configure:1.19 --- ircd-ircdev/configure:1.18 Mon May 16 04:22:48 2005 +++ ircd-ircdev/configure Thu Sep 1 04:25:42 2005 @@ -7765,6 +7765,71 @@ echo "$as_me: error: Cannot find a type with size of 64 bits" >&2;} { (exit 1); exit 1; }; } fi +echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5 +echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6 +if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <sys/types.h> +#include <netinet/in.h> + +int +main () +{ +if ((struct sockaddr_in6 *) 0) + return 0; +if (sizeof (struct sockaddr_in6)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_type_struct_sockaddr_in6=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_type_struct_sockaddr_in6=no +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5 +echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6 +if test $ac_cv_type_struct_sockaddr_in6 = yes; then + unet_have_sockaddr_in6="yes" +else + unet_have_sockaddr_in6="no" +fi + + echo "$as_me:$LINENO: checking for socklen_t" >&5 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6 if test "${ac_cv_type_socklen_t+set}" = set; then @@ -7776,7 +7841,9 @@ cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -$ac_includes_default +#include <sys/types.h> +#include<sys/socket.h> + int main () { @@ -7825,33 +7892,29 @@ : else -cat >>confdefs.h <<_ACEOF -#define socklen_t unsigned int -_ACEOF - -fi - -echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5 -echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6 -if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then + echo "$as_me:$LINENO: checking for socklen_t equivalent" >&5 +echo $ECHO_N "checking for socklen_t equivalent... $ECHO_C" >&6 + if test "${curl_cv_socklen_t_equiv+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF + + curl_cv_socklen_t_equiv= + for arg2 in "struct sockaddr" void ; do + for t in int size_t unsigned long "unsigned long" ; do + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <sys/types.h> -#include <netinet/in.h> - +#include <sys/socket.h> +int getpeername (int $arg2 *, $t *); int main () { -if ((struct sockaddr_in6 *) 0) - return 0; -if (sizeof (struct sockaddr_in6)) - return 0; +$t len; + getpeername(0, 0, &len); ; return 0; } @@ -7878,21 +7941,26 @@ ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_type_struct_sockaddr_in6=yes + curl_cv_socklen_t_equiv="$t" + break else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -ac_cv_type_struct_sockaddr_in6=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext + done + done + fi -echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5 -echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6 -if test $ac_cv_type_struct_sockaddr_in6 = yes; then - unet_have_sockaddr_in6="yes" -else - unet_have_sockaddr_in6="no" + + echo "$as_me:$LINENO: result: $curl_cv_socklen_t_equiv" >&5 +echo "${ECHO_T}$curl_cv_socklen_t_equiv" >&6 + +cat >>confdefs.h <<_ACEOF +#define socklen_t $curl_cv_socklen_t_equiv +_ACEOF + fi Index: ircd-ircdev/configure.in diff -u ircd-ircdev/configure.in:1.17 ircd-ircdev/configure.in:1.18 --- ircd-ircdev/configure.in:1.17 Mon May 16 04:22:49 2005 +++ ircd-ircdev/configure.in Thu Sep 1 04:25:42 2005 @@ -22,7 +22,7 @@ dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA dnl -dnl $Id: configure.in,v 1.17 2005/05/16 11:22:49 zolty Exp $ +dnl $Id: configure.in,v 1.18 2005/09/01 11:25:42 zolty Exp $ dnl dnl Make sure we are in the correct directory (someone could have run @@ -79,10 +79,35 @@ AC_STRUCT_TM AC_TYPE_UID_T unet_CHECK_TYPE_SIZES -AC_CHECK_TYPE(socklen_t, unsigned int) AC_CHECK_TYPE(struct sockaddr_in6, [unet_have_sockaddr_in6="yes"], [unet_have_sockaddr_in6="no"], [#include <sys/types.h> #include <netinet/in.h>]) +dnl Check for socklen_t. In traditional BSD this is an int, but some +dnl OSes use a different type. Test until we find something that will +dnl work properly. Test borrowed from a patch submitted for Python. +AC_CHECK_TYPE([socklen_t], ,[ + AC_MSG_CHECKING([for socklen_t equivalent]) + AC_CACHE_VAL([curl_cv_socklen_t_equiv], + [ +dnl Systems have either "struct sockaddr*" or "void*" as second +dnl arg to getpeername. + curl_cv_socklen_t_equiv= + for arg2 in "struct sockaddr" void ; do + for t in int size_t unsigned long "unsigned long" ; do + AC_TRY_COMPILE([#include <sys/types.h> +#include <sys/socket.h> +int getpeername (int $arg2 *, $t *);],[$t len; + getpeername(0, 0, &len);], [curl_cv_socklen_t_equiv="$t" + break]) + done + done + ]) + AC_MSG_RESULT($curl_cv_socklen_t_equiv) + AC_DEFINE_UNQUOTED(socklen_t, $curl_cv_socklen_t_equiv, + [type to use in place of socklen_t if not defined])], + [#include <sys/types.h> +#include<sys/socket.h>]) + dnl Checks for library functions. AC_CHECK_FUNCS([kqueue setrlimit getrusage times]) Index: ircd-ircdev/doc/en/api/features.txt diff -u ircd-ircdev/doc/en/api/features.txt:1.2 ircd-ircdev/doc/en/api/features.txt:1.3 --- ircd-ircdev/doc/en/api/features.txt:1.2 Wed Jan 5 08:38:12 2005 +++ ircd-ircdev/doc/en/api/features.txt Thu Sep 1 04:25:42 2005 @@ -1,4 +1,4 @@ -$Id: features.txt,v 1.2 2005/01/05 16:38:12 zolty Exp $ +$Id: features.txt,v 1.3 2005/09/01 11:25:42 zolty Exp $ As of u2.10.11, most of the compile-time configuration options present in previous versions of ircu have been provided via the configuration @@ -63,13 +63,13 @@ Marking Features When the configuration file is read, there must be some way to -determine if a particular F-line has been removed since the last time -the configuration file was read. The way this is done in the features -subsystem is to have a "mark" for each feature. Prior to reading the -configuration file, all marks are cleared for all features (and all -"unmark" call-backs are called). As each F-line is encountered and -processed, that feature's mark is set. Finally, when the -configuration file has been fully read, all remaining unmarked +determine if a particular Feature entry has been removed since the +last time the configuration file was read. The way this is done in +the features subsystem is to have a "mark" for each feature. Prior to +reading the configuration file, all marks are cleared for all features +(and all "unmark" call-backs are called). As each Feature entry is +encountered and processed, that feature's mark is set. Finally, when +the configuration file has been fully read, all remaining unmarked features are reset to their default values (and all "mark" call-backs are called). @@ -150,8 +150,8 @@ <function> void feature_report(struct Client* to); -Reports all F-lines to a user using RPL_STATSFLINE, except those which -the user is not permitted to see due to flag settings. +Reports all Feature entries to a user using RPL_STATSFLINE, except +those which the user is not permitted to see due to flag settings. </function> <function> Index: ircd-ircdev/doc/en/api/modebuf.txt diff -u ircd-ircdev/doc/en/api/modebuf.txt:1.2 ircd-ircdev/doc/en/api/modebuf.txt:1.3 --- ircd-ircdev/doc/en/api/modebuf.txt:1.2 Wed Jan 5 08:38:12 2005 +++ ircd-ircdev/doc/en/api/modebuf.txt Thu Sep 1 04:25:42 2005 @@ -1,4 +1,4 @@ -$Id: modebuf.txt,v 1.2 2005/01/05 16:38:12 zolty Exp $ +$Id: modebuf.txt,v 1.3 2005/09/01 11:25:42 zolty Exp $ Generating and parsing channel mode strings is often a very complicated process. The ModeBuf interface, along with the associated @@ -103,10 +103,10 @@ <macro> #define MODEBUF_DEST_HACK4 0x8000 /* Send a HACK(4) notice, TS == 0 */ -Some servers are special. When a server that has a U-line issues a -mode change, we send a "HACK(4)" message to differentiate it from an -ordinary server changing a channel mode. This is the flag that must -be passed to modebuf_init() to cause that behavior. +Some servers are special. When a server that has a Uworld entry +issues a mode change, we send a "HACK(4)" message to differentiate it +from an ordinary server changing a channel mode. This is the flag +that must be passed to modebuf_init() to cause that behavior. </macro> <function> Index: ircd-ircdev/doc/en/api/motd.txt diff -u ircd-ircdev/doc/en/api/motd.txt:1.2 ircd-ircdev/doc/en/api/motd.txt:1.3 --- ircd-ircdev/doc/en/api/motd.txt:1.2 Wed Jan 5 08:38:12 2005 +++ ircd-ircdev/doc/en/api/motd.txt Thu Sep 1 04:25:42 2005 @@ -1,4 +1,4 @@ -$Id: motd.txt,v 1.2 2005/01/05 16:38:12 zolty Exp $ +$Id: motd.txt,v 1.3 2005/09/01 11:25:42 zolty Exp $ The server has a Message of the Day (MOTD) which is often used for describing the Acceptable Usage Policy, where to get help if you have @@ -21,12 +21,11 @@ This function sends an appropriate MOTD to the client specified by _cptr_. If _cptr_ is not a local client, the remote MOTD will be -sent; otherwise, an attempt will be made to find a T-line in the -configuration file that matches the client. If no T-line can be +sent; otherwise, an attempt will be made to find a Motd entry in the +configuration file that matches the client. If no Motd entry can be found, the default MOTD will be sent to the client. This function returns 0 for the convenience of other functions that must have an -integer return value. -</function> +integer return value. </function> <function> void motd_signon(struct Client* cptr); @@ -62,7 +61,7 @@ <function> void motd_report(struct Client *to); -The motd_report() function sends a list of the T-lines stored in +The motd_report() function sends a list of the Motd entries stored in memory to the client specified by _to_. Access control should be handled by the caller. </function> Index: ircd-ircdev/doc/en/features.txt diff -u ircd-ircdev/doc/en/features.txt:1.2 ircd-ircdev/doc/en/features.txt:1.3 --- ircd-ircdev/doc/en/features.txt:1.2 Wed Jan 26 09:19:41 2005 +++ ircd-ircdev/doc/en/features.txt Thu Sep 1 04:25:42 2005 @@ -1,9 +1,9 @@ -$Id: features.txt,v 1.2 2005/01/26 17:19:41 zolty Exp $ +$Id: features.txt,v 1.3 2005/09/01 11:25:42 zolty Exp $ Many of the old compile-time options are now configured through the server configuration file, ircd.conf. This file is intended to document each of these features. Logging, although also configured -through the use of "Features" Block, is documented in doc/*/log.txt. +through the use of Feature entries, is documented in doc/*/log.txt. NOTE THAT THESE NAMES ARE CASE SENSITIVE! Values are not case sensitive unless stated otherwise in the documentation for that feature. @@ -343,6 +343,15 @@ in nickname length for a network. +CHANNELLEN + * Type: integer + * Default: 200 + +This is the allowed length of locally created channels. It may not be +larger than the CHANNELLEN #define. Like the NICKLEN feature, this is +intended to ease changes in channel name length across a network. + + AVBANLEN * Type: integer * Default: 40 @@ -439,8 +448,8 @@ This is the default frequency that the server attempts to reconnect with its uplink server if it is set to auto connect to it. Note that -this value is overridden by a "Class" block in ircd.conf if the "Connect" -block in ircd.conf assign a specific class to the connection (recommended). +this value is overridden by a "Class" block in ircd.conf if the Connect +entries in ircd.conf assign a specific class to the connection (recommended). DEFAULTMAXSENDQLENGTH @@ -449,9 +458,7 @@ This is the default value of the maximum sendQ length of connection classes (see doc/ircd.sample-*.conf for details on "Class" blocks). You will -probably always override this value in your "ircd.conf" with the -"Class" block. The given value used to be an often used value for client -sendQs. +generally override this value in your "ircd.conf" with a Class block. GLINEMAXUSERCOUNT @@ -604,13 +611,12 @@ * Type: boolean * Default: FALSE -For u2.10.11, several new oper-only features have been added that -involve changes to the server<->server protocol. Until the entire -network is running the new version, these features cannot be enabled. -This configuration option provides a single switch to prevent the use -of these features until the entire network has been upgraded. It is -not required that all servers set this to "TRUE" in order for the -features to be used. +Since u2.10.11, several new oper-only features have been added that +involve changes to the server<->server protocol. This configuration +option provides a single switch to prevent the use of these features +until the entire network has been upgraded. It is not required that +all servers set this to "TRUE" in order for the features to be used, +as long as all servers are running u2.10.11 or above. HIS_SNOTICES Index: ircd-ircdev/doc/en/log.txt diff -u ircd-ircdev/doc/en/log.txt:1.2 ircd-ircdev/doc/en/log.txt:1.3 --- ircd-ircdev/doc/en/log.txt:1.2 Sat May 7 15:23:39 2005 +++ ircd-ircdev/doc/en/log.txt Thu Sep 1 04:25:42 2005 @@ -1,10 +1,10 @@ -$Id: log.txt,v 1.2 2005/05/07 22:23:39 zolty Exp $ +$Id: log.txt,v 1.3 2005/09/01 11:25:42 zolty Exp $ Older versions of ircd had no consistent way of logging various actions. Some things, such as G-lines, were written out to log files with names compiled into the server. Others could only be logged through syslog. Some required that their log files exist beforehand. -For u2.10.11, this situation has changed dramatically. +Starting with u2.10.11, this situation has changed dramatically. All logging in the server is now unified through a single logging subsystem. Unfortunately, the server still does not generate all the @@ -139,30 +139,31 @@ The IRC server has a default facility that it uses when sending log messages to syslog. The default facility may be overridden for each individual subsystem, but the default itself can be changed with an -appropriate F-line in the configuration file. The facility normally -defaults to "USER," but may be configured to be any of AUTH, CRON, -DAEMON, LOCAL0, LOCAL1, LOCAL2, LOCAL3, LOCAL4, LOCAL5, LOCAL6, +appropriate Feature entry in the configuration file. The facility +normally defaults to "USER," but may be configured to be any of AUTH, +CRON, DAEMON, LOCAL0, LOCAL1, LOCAL2, LOCAL3, LOCAL4, LOCAL5, LOCAL6, LOCAL7, LPR, MAIL, NEWS, USER, or UUCP. Some systems also have the -AUTHPRIV facility. To configure this default, add an F-line to the -configuration file that looks like "F:LOG:<facility>"; <facility> -should be replaced with the string for the desired default syslog -facility. +AUTHPRIV facility. To configure this default, add a Feature line to +the configuration file that looks like "LOG" = "<facility>"; +<facility> should be replaced with the string for the desired default +syslog facility. Log Files Each subsystem may be configured to send its log messages to any -single log file with an F-line like "F:LOG:<subsys>:FILE:<file>"; -<subsys> should be replaced with one of the subsystem names described -above, and <file> should be a file name for the log file. The file -name may be relative to the server's data directory ("DPATH"), or it -may be an absolute path name. Note that if you're using chroot, these -absolute path names will be relative to the server's root directory. +single log file with a Feature entry like "LOG" = "<subsys>" "FILE" +"<file>"; <subsys> should be replaced with one of the subsystem names +described above, and <file> should be a file name for the log file. +The file name may be relative to the server's data directory +("DPATH"), or it may be an absolute path name. Note that if you're +using chroot, these absolute path names will be relative to the +server's root directory. Logging to Syslog By default, except for the CONFIG subsystem, no logs are sent to -syslog. This can be overridden using an F-line like -"F:LOG:<subsys>:FACILITY:<facility>"; <subsys>, as above, should be +syslog. This can be overridden using an Feature entry like "LOG" = +"<subsys>" "FACILITY" "<facility>"; <subsys>, as above, should be replaced with one of the subsystem names described above, and <facility> must be one of the facility strings mentioned under "Default Syslog Facility." The facility string may also be "NONE," to @@ -182,14 +183,14 @@ are OLDSNO, SERVKILL, OPERKILL, HACK2, HACK3, UNAUTH, TCPCOMMON, TOOMANY, HACK4, GLINE, NETWORK, IPMISMATCH, THROTTLE, OLDREALOP, CONNEXIT, and DEBUG. The special mask name "NONE" inhibits sending of -server notices for a particular subsystem. The F-line for this -configuration looks like "F:LOG:<subsys>:SNOMASK:<mask>"; again, +server notices for a particular subsystem. The Feature entry for this +configuration looks like "LOG" = "<subsys>" "SNOMASK" "<mask>"; again, <subsys> is one of the subsystems described above, and <mask> is one of the mask names. Setting Minimum Logging Level The minimum log level for a particular subsystem may be set with an -F-line like "F:LOG:<subsys>:LEVEL:<level>"; here, <subsys> is yet -again one of the subsystems described above, and <level> is one of the -level names, also described above. +Feature entry like "LOG" = "<subsys>" "LEVEL" "<level>"; here, +<subsys> is yet again one of the subsystems described above, and +<level> is one of the level names, also described above. Index: ircd-ircdev/doc/ircd.sample-en.conf diff -u ircd-ircdev/doc/ircd.sample-en.conf:1.21 ircd-ircdev/doc/ircd.sample-en.conf:1.22 --- ircd-ircdev/doc/ircd.sample-en.conf:1.21 Sat May 7 15:32:20 2005 +++ ircd-ircdev/doc/ircd.sample-en.conf Thu Sep 1 04:25:42 2005 @@ -1,6 +1,6 @@ # ircd.conf - configuration file for IRC-Dev's IRCD. # -# Last Updated: 8, May 2005. +# Last Updated: 1, Sep 2005. # # Written by Niels <ni...@un...>, based on the original example.conf, # server code and some real-life (ahem) experience. @@ -64,7 +64,7 @@ # be the address of a physical interface on the host. This address is # used for outgoing connections if the "Connect" block does not override # it. See "Port" block for listener virtual hosting. If in doubt, -# leave it out. +# leave it out -- or use "*", which has the same meaning as no vhost. # # You may specify both an IPv4 virtual host and an IPv6 virtual host, # to indicate which address should be used for outbound connections @@ -160,6 +160,12 @@ maxlinks = 100; usermode = "+iw"; }; +Class { + name = "Other"; + pingfreq = 1 minutes 30 seconds; + sendq = 160000; + maxlinks = 400; +}; Client { class = "Other"; @@ -172,12 +178,6 @@ maxlinks = 5; }; Class { - name = "Other"; - pingfreq = 1 minutes 30 seconds; - sendq = 160000; - maxlinks = 400; -}; -Class { name = "Opers"; pingfreq = 1 minutes 30 seconds; sendq = 160000; @@ -460,9 +460,9 @@ # # # The default reason is: "You are banned from this server" -# Note that K-lines are local to the server; if you ban a person or a +# Note that Kill blocks are local to the server; if you ban a person or a # whole domain from your server, they can get on IRC via any other server -# that doesn't have them K-lined (yet). +# that doesn't have them Killed (yet). # # With a simple comment, using quotes: Kill { host = "*.au"; reason = "Please use a nearer server"; }; @@ -785,6 +785,7 @@ # "KILLCHASETIMELIMIT" = "30"; # "MAXCHANNELSPERUSER" = "10"; # "NICKLEN" = "12"; +# "CHANNELLEN" = "200"; # "AVBANLEN" = "40"; # "MAXBANS" = "45"; # "MAXSILES" = "15"; Index: ircd-ircdev/doc/ircd.sample-es.conf diff -u ircd-ircdev/doc/ircd.sample-es.conf:1.16 ircd-ircdev/doc/ircd.sample-es.conf:1.17 --- ircd-ircdev/doc/ircd.sample-es.conf:1.16 Sat May 7 15:32:20 2005 +++ ircd-ircdev/doc/ircd.sample-es.conf Thu Sep 1 04:25:42 2005 @@ -1,6 +1,6 @@ # ircd.conf - archivo de configuración para el IRCD de IRC-Dev. # -# Ultima actualización: 8, May 2005. +# Ultima actualización: 1, Sep 2005. # # Escrito por Niels <ni...@un...>, basado en el archivo example.conf # original, en el código del servidor y la experiencia de la vida real. @@ -70,7 +70,8 @@ # La dirección DEBE ser la dirección de una interfaz física en el host. # Esta dirección se utiliza para las conexiones salientes si el bloque # "Connect" no la elimina. Veáse el bloque "Port" para la escucha con -# virtual hosting. En caso de duda no pongas nada. +# virtual hosting. En caso de duda no pongas nada o usa "*" que tiene el +# mismo significado que no tener vhost. # # Puedes especificar un virtualhost de IPv4 y un virtualhost de IPv6, # para indicar cuál de las direcciones se debe utilizar para las @@ -169,6 +170,12 @@ maxlinks = 100; usermode = "+iw"; }; +Class { + name = "Otros"; + pingfreq = 1 minutes 30 seconds; + sendq = 160000; + maxlinks = 400; +}; Client { class = "Otros"; @@ -181,12 +188,6 @@ maxlinks = 5; }; Class { - name = "Otros"; - pingfreq = 1 minutes 30 seconds; - sendq = 160000; - maxlinks = 400; -}; -Class { name = "Opers"; pingfreq = 1 minutes 30 seconds; sendq = 160000; @@ -482,9 +483,9 @@ # # # La razón por defecto es: "You are banned from this server" -# Notese que las "K-lines" son locales al servidor; si se prohibe a una -# persona o un dominio entero de tu servidor, aun pueden entrar al IRC -# por otro servidor que no tengan "K-lined" (aun). +# Notese que los bloques "Kill" son locales al servidor; si se prohibe +# a una persona o un dominio entero de tu servidor, aun pueden entrar +# al IRC por otro servidor que no tengan "Killed" (aun). # # Con un simple comentario, usando comillas: Kill { host = "*.au"; reason = "Por favor, use un servidor más cercano"; }; @@ -495,7 +496,7 @@ # El archivo puede contener, por ejemplo, una razón, un enlace a las normas # del servidor y una dirección de contacto. Observe la combinación del username -y el host en el campo "host". +#y el host en el campo "host". Kill { host = "*lu...@un..."; @@ -822,6 +823,7 @@ # "KILLCHASETIMELIMIT" = "30"; # "MAXCHANNELSPERUSER" = "10"; # "NICKLEN" = "12"; +# "CHANNELLEN" = "200"; # "AVBANLEN" = "40"; # "MAXBANS" = "45"; # "MAXSILES" = "15"; Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.12 ircd-ircdev/include/channel.h:1.13 --- ircd-ircdev/include/channel.h:1.12 Wed Jun 22 02:58:52 2005 +++ ircd-ircdev/include/channel.h Thu Sep 1 04:25:42 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Channel management and maintenance. - * @version $Id: channel.h,v 1.12 2005/06/22 09:58:52 zolty Exp $ + * @version $Id: channel.h,v 1.13 2005/09/01 11:25:42 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -49,9 +49,6 @@ #define MODEBUFLEN 200 /**< Maximum length of a mode */ #define KEYLEN 23 /**< Maximum length of a key */ -#if defined(UNDERNET) -#define PASSLEN 23 /**< Maximum length of a password */ -#endif #define CHANNELLEN 200 /**< Maximum length of a channel */ #define MAXJOINARGS 15 /**< number of slots for join buffer */ @@ -305,8 +302,8 @@ unsigned int limit; char key[KEYLEN + 1]; #if defined(UNDERNET) - char upass[PASSLEN + 1]; - char apass[PASSLEN + 1]; + char upass[KEYLEN + 1]; + char apass[KEYLEN + 1]; #endif }; ... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-09-01 11:34:14
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-09-01 11:34:08 UTC Modified files: TODO.es Log message: Mas TODO ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.28 ircd-ircdev/TODO.es:1.29 --- ircd-ircdev/TODO.es:1.28 Wed Jun 22 03:01:25 2005 +++ ircd-ircdev/TODO.es Thu Sep 1 04:33:58 2005 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.28 2005/06/22 10:01:25 zolty Exp $ +# $Id: TODO.es,v 1.29 2005/09/01 11:33:58 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -15,7 +15,7 @@ ALTA PRIORIDAD -------------------------------------------------------------------------------------- - [G] Soporte de E-lines (excepciones a K-lines). - - [G] Modo +X de ver ips. + - [G] Modo +X de ver ips. Hacerlo por privilegios daria problemas. - [G] Modo +R de usuarios. - [G] ¿Modo +M de canales?. - [G] Poner uuna Feature para elegir entre salir o no el nombre del servidor en los @@ -98,7 +98,8 @@ -------------------------------------------------------------------------------------- 15/Mar/2005 - [G] Bajo en ciertas circunstancias desconocidas del ircd.conf no pueden - entrar clientes al IRCD. Investigar eso. + entrar clientes al IRCD. Investigar eso. Parece ser que si se pilla el + sample en castellano y no funciona pero... si comentas lo iauth entonces ya funciona. 26/May/2005 - [D] Los cambios de modos en canal, a veces hay desyncs. Investigar el origen - [D] Antes de un netjoin, un /mode #canal mostraba +r, despues ya no. ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-09-01 11:38:14
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-09-01 11:38:07 UTC Modified files: doc/history/Undernet/ChangeLog-u2.10.12 Log message: ChangeLog ---------------------- diff included ---------------------- Index: ircd-ircdev/doc/history/Undernet/ChangeLog-u2.10.12 diff -u ircd-ircdev/doc/history/Undernet/ChangeLog-u2.10.12:1.3 ircd-ircdev/doc/history/Undernet/ChangeLog-u2.10.12:1.4 --- ircd-ircdev/doc/history/Undernet/ChangeLog-u2.10.12:1.3 Wed Mar 9 10:12:32 2005 +++ ircd-ircdev/doc/history/Undernet/ChangeLog-u2.10.12 Thu Sep 1 04:37:57 2005 @@ -1,3 +1,1320 @@ +2005-08-30 Michael Poole <md...@tr...> + + * include/channel.h (PASSLEN): Remove; use KEYLEN instead. + + * ircd/channel.c (mode_parse_upass): Likewise. + (mode_parse_apass): Likewise. + The inconsistency (in clean_key()) was reported by Reed. + +2005-08-30 Michael Poole <md...@tr...> + + * RELEASE.NOTES: Document +D and +d channel modes. + +2005-08-29 Michael Poole <md...@tr...> + + * include/numeric.h (ERR_NOMANAGER_LONG): Undefine. + (ERR_NOMANAGER_SHORT): Rename to ERR_NOMANAGER. + + * ircd/s_err.c (replyTable): Change to reflect that. + + * ircd/channel.c (clean_key): New function. + (mode_parse_key): Use it, and check that keys do not start with :. + (mode_parse_upass): Likewise, and adjust for ERR_NOMANAGER. + (mode_parse_apass): Likewise. + The key and password changes fix bugs reported by coekie. + +2005-08-27 Michael Poole <md...@tr...> + + * ircd/channel.c (add_user_to_channel): Use SetOpLevel() instead + of assigning directly to member->oplevel. + (mode_parse_apass): Likewise. + (mode_process_clients): Users opped by outsiders should get + oplevel 1, since they are not channel managers. + + * ircd/m_burst.c (ms_burst): Use SetOpLevel() instead of assigning + directly to member->oplevel. + +2005-08-25 Michael Poole <md...@tr...> + + * ircd/channel.c (member_can_send_to_channel): At coekie's + suggestion, disallow channel manager talking after Apass is set, + so they set and use Upass sooner. + + * ircd/class.c (init_class): Default class should have 1 link. + (report_classes): Return links count minus one to match old output. + + * ircd/m_trace.c (do_trace): Fix links count here, too (spotted by + Reed). + +2005-08-25 Michael Poole <md...@tr...> + + * ircd/channel.c (mode_parse): Accept +A/+U from servers + regardless of FEAT_OPLEVELS. + +2005-08-24 Michael Poole <md...@tr...> + + * ircd/ircd.c (parse_command_line): Mention epoll engine when run + with -v. + +2005-08-24 Michael Poole <md...@tr...> + + * include/patchlevel.h (PATCHLEVEL): Increment. + + * ircd/channel.c (joinbuf_join): Double check that oplevel is 0 or + 1 when propagating JOIN <level>:#channel, to avoid PV on receiver. + + * ircd/engine_epoll.c: Add system call numbers for more CPU types. + + * ircd/ircd_log.c (log_open): Remove NFS-oriented alarm() calls; + anyone who writes logs over NFS is mental. (Thanks to D. Bruce.) + +2005-08-21 Michael Poole <md...@tr...> + + * include/s_conf.h (free_mapping): Declare new function. + + * ircd/ircd_parser.y (pseudoblock): Use it. + + * ircd/s_conf.c (free_mapping): Define it. + (close_mappings): New function. + (rehash): Call close_mappings() before reading file. + + * ircd/m_kill.c (do_kill): Revert 2005-08-18 change. + +2005-08-19 Michael Poole <md...@tr...> + + * ircd/parse.c (tok_tree): Re-add token tree structure. + (initmsgtree): Populate it. + (parse_server): Prefer it to full message tree. + +2005-08-18 Michael Poole <md...@tr...> + + * ircd/m_kill.c (do_kill): When FEAT_HIS_KILLWHO, change apparent + source of KILLs to &his instead of &me. + +2005-08-16 Michael Poole <md...@tr...> + + * ircd/channel.c (mode_parse_ban): Avoid overwriting part of + newban->banstr[] when the source is a server. (Spotted by jcq.) + +2005-08-16 Michael Poole <md...@tr...> + + * ircd/channel.c (joinbuf_join): Switch to &his instead of &me for + announcements to local users in a channel. + + * ircd/m_burst.c (ms_burst): Likewise. + + * ircd/m_invite.c (m_invite): Likewise. + (ms_invite): Likewise. + + * ircd/m_kick.c (ms_kick): Likewise. + + * ircd/m_topic.c (do_settopic): Another &me -> &his change for + HIS, and use that apparent source for the channel localcast. + +2005-08-16 Jukka Ollila <jao...@ni...> + + * ircd/s_user.c (hide_hostmask): Use HIS_SERVERNAME instead of the + real thing for the post-mode-x rejoin. + +2005-08-15 Michael Poole <md...@tr...> + + * include/supported.h (FEATURESVALUES2): Add +d channel mode. + + * ircd/IPcheck.c (ip_registry_new_entry): Clarify that this is not + a varadic function. (Suggested by Ian Kumlien.) + + * ircd/convert-conf.c (finish_operators): Likewise. + + * ircd/listener.c (close_listeners): Likewise. + + * ircd/channel.c (CheckDelayedJoins): Use HIS server name to + remove channel mode +d. + +2005-08-12 Michael Poole <md...@tr...> + + * ircd/channel.c (pretty_mask): Recognize ':' as unique to the + host part of a ban mask. + +2005-08-03 Jan Krueger <ja...@he...> + + * ircd/m_kick.c (m_kick): Send JOIN prior to confirming KICK on + invisible member. + +2005-08-08 Michael Poole <md...@tr...> + + * ircd/channel.c (find_ban): For non-IPmask bans, match the ban + string against the string form of the client's IP address. + +2005-07-16 Michael Poole <md...@tr...> + + * configure.in: Apply a test for socklen_t that Reed found. + + * configure: Regenerate. + +2005-07-16 Michael Poole <md...@tr...> + + * RELEASE.NOTES: Mention that 2.10.11 does not support oplevels. + + * README.FreeBSD: Remove (merged into README). + + * README.Solaris: Remove (merged into README). + + * README: Merge in the above; also update for 2.10.12. + + * doc/example.conf: Change mention of K-lines to say Kill blocks + instead. + + * doc/iauth.txt: Remove (out of date). + + * doc/readme.features: Update to reflect that 2.10.11 is not the + current release. Change mention of various config lines to use + the equivalent config entries or blocks instead. + + * doc/readme.log: Likewise. + + * doc/api/features.txt: Change F-line mentions to say Feature + entry instead. + + * doc/api/modebuf.txt: Change U-line mention to say Uworld entry. + + * doc/api/motd.txt: Change T-line mentions to say Motd entry. + +2005-07-15 Michael Poole <md...@tr...> + + * ircd/ircd_features.c (feature_init): Always call + feature_notify_server*() so that 'his' is initialized. + + * ircd/m_whois.c (do_whois): Unswap sense of comparison to choose + between user->server and &his. + +2005-07-14 Michael Poole <md...@tr...> + + * ircd/channel.c (mode_parse_apass): Update oplevels when setting + or removing the +A password. Partial credit goes to Reed Loden. + +2005-07-14 Michael Poole <md...@tr...> + + * include/ircd_features.h: Declare new "his" pseudo-server to hold + FEAT_HIS_SERVERNAME and FEAT_HIS_SERVERINFO in a convenient place. + + * ircd/ircd_features.c: Initialize and update it. + + * ircd/channel.c (modebuf_flush_int): Use it as the apparent + source for opmodes and server mode changes (also when the source + is me). + + * ircd/m_burst.c (ms_burst): Use it as the apparent source for net + rider kicks. + + * ircd/m_whois.c (do_whois): Use it to simplify code here. + + * ircd/s_misc.c (exit_client): Use it as the apparent killer. + +2005-07-14 Michael Poole <md...@tr...> + + * doc/example.conf (General): Update comment about vhost to match + the code change below. + + * ircd/ircd_parser.y (generalvhost): Accept vhost="*"; as a + synonym for the default behavior (for backwards compatibility). + Spotted by Kev. + + * ircd/channel.c (sub1_from_channel): Remove stale code and + comment, replacing with an up-to-date comment. Spotted by skx. + +2005-07-11 Michael Poole <md...@tr...> + + * ircd/engine_select.c: Remove outdated comment about USE_POLL. + + * ircd/parse.c (msgtab): #if out CAP handler until we have caps. + + * RELEASE.NOTES: Remove mention of capabilities for now. + +2005-07-11 Stephan Peijnik <spe...@gm...> + + * ircd/gline.c (gline_add): It's only a protocol violation when a + server issues a "whacky" gline. If it's an oper, only tell opers + with SNO_GLINE. + + * ircd/ircd_auth.c (iauth_protocol_violation): Likewise, the whole + network is not likely to care about IAuth PVs, so only tell opers + with SNO_CONNEXIT. + +2005-07-11 Michael Poole <md...@tr...> + + * doc/readme.features: Document FEAT_CHANNELLEN. + + * doc/example.conf: Give an example of it. + + * ircd/m_join.c (ms_join): Do not clean channel names from remote + servers, to avoid desynchs. + + * ircd/m_names.c (ms_names): Likewise. + +2005-07-11 Stephan Peijnik <spe...@gm...> + + * include/ircd_features.h: Declare new FEAT_CHANNELLEN. + + * include/supported.h: Add it to the ISUPPORT display. + + * ircd/channel.c (clean_channelname): Impose the lower limit + between FEAT_CHANNELLEN and CHANNELLEN. + + * ircd/ircd_features.c: Define FEAT_CHANNELLEN. + +2005-07-11 Reed Loden <re...@re...> + + * include/sys.h: Move FD_SETSIZE redefinition to engine_select.c. + + * ircd/s_bsd.c: Move FD_SETSIZE sanity check to engine_select.c + Remove unused #include <sys/poll.h>. + + * ircd/engine_select.c: Put FD_SETSIZE redefinition and sanity + checks here, since they are not used elsewhere in the daemon. + [Order slightly changed by Michael Poole to compile.] + +2005-07-03 Michael Poole <md...@tr...> + + * ircd/convert-conf.c: New file. + + * ircd/Makefile: Compile it. + +2005-06-27 Michael Poole <md...@tr...> + + * ircd/s_bsd.c (add_connection): Split logic for server versus + client listeners; only do IPcheck for client connections. + + * ircd/s_serv.c (server_estab): There is no longer a need to + remove IPcheck reference, so don't. + +2005-06-27 Michael Poole <md...@tr...> + + * include/client.h (struct Connection): Remove con_dns_reply (and + associated macros). + + * include/res.h (gethost_byname): Change calling signature to + clarify memory ownership. + (gethost_byaddr): Likewise. + + * include/s_bsd.h (release_dns_reply): Remove function. + + * ircd/hash.c: #include "match.h" to quash warning. + + * ircd/ircd_auth.c (struct IAuth): Remove i_query field. + (iauth_dns_callback): Adjust for new gethost_byname signature. + (iauth_reconnect): Likewise. + + * ircd/ircd_res.c (struct reslist): Make elements of query field + inline rather than in a contained structure. + (make_request): Reflect removal of DNSQuery. + (do_query_name): Likewise. + (do_query_number): Likewise. + (make_dnsreply): Remove now-unused function. + (timeout_resolver): Adjust to new callback signature. + (delete_resolver_queries): Reflect removal of DNSQuery. + (gethost_byname): Update to new signature. + (gethost_byaddr): Likewise. + (res_readreply): Reflect removal of DNSReply. + + * ircd/list.c (dealloc_connection): con_dns_reply no longer + exists, so do not free it. + + * ircd/s_auth.c (auth_verify_hostname): constify. + (auth_dns_callback): Adjust to new callback signature. + (start_auth): Adjust to new gethost_byaddr() signature. + + * ircd/s_bsd.c (connect_dns_callback): Adjust to new callback + signature. + (release_dns_reply): Remove unused function. + (connect_server): Adjust to new gethost_byname() signature. + + * ircd/s_conf.c (conf_dns_callback): Adjust to new callback + signature. + (conf_dns_lookup): Adjust to new gethost_byname() signature. + (attach_iline): Use cli_sockhost() instead of DNS reply. + (conf_check_server): Simplify use of DNS results. + + * ircd/s_serv.c (server_estab): Remove call to removed function. + + * ircd/s_user.c (register_user): Remove call to removed function. + +2005-06-27 Michael Poole <md...@tr...> + + * include/s_misc.h (get_sockhost): Remove the unused (and + deceptively named) get_sockhost(). + + * ircd/s_misc.c (get_sockhost): Likewise. + +2005-06-25 Andrew Miller <a1...@am...> + + * ircd/ircd_crypt.c (ircd_crypt): strdup is not allowed, change to + DupStr so memdebug works. + + * doc/debug_memleak_gc.patch : Update to gc6.5 + +2005-06-24 Andrew Miller <a1...@am...> + * ircd/m_invite.c (m_invite): Don't propagate invites to local channels. + +2005-06-21 Andrew Miller <a1...@am...> + + * ircd/m_list.c (param_parse): Add support for channel wildcards. + * ircd/m_list.c (show_usage): Document the new format. + * ircd/hash.c (list_next_channels): Check channel wildcard in list. + * include/channel.h (ListingArgs): Add the wildcard member. + +2005-06-19 Andrew Miller <a1...@am...> + + * ircd/ircd_res.c (proc_answer): Deal with unexpected record types more + gracefully. + + * ircd/ircd_res.c (res_readreply): Check res_ourserver before walking + the pending request list, to make DoS attacks harder. + + * ircd/m_invite.c (m_invite): Give no such channel rather than not on + channel when the channel being invited to does not exist. + +2005-06-18 Michael Poole <md...@tr...> + + * ircd/s_debug.c (count_memory): Consolidate several lines; make + initial letter capitalization consistent. + +2005-06-19 Andrew Miller <a1...@am...> + + * ircd/s_stats.c: Remove the "debug only" label on memusage stats, + since it no longer applies. + +2005-05-16 Michael Poole <md...@tr...> + + * include/channel.h (struct Ban): Make 'who' and 'banstr' direct + arrays, rather than pointers. + + * ircd/channel.c (bans_alloc): New variable to count number of ban + structures allocated. + (bans_inuse): New variable to count number of ban structures + currently in use. + (set_banmask): Adapt to changes in struct Ban. + (make_ban): Likewise, and update ban counts. + (free_ban): Likewise. + (bans_send_meminfo): New function. + (apply_ban): Adapt to changes in struct Ban. + (mode_parse_ban): Likewise. + (mode_process_bans): Likewise. + (mode_parse): Likewise. + (RevealDelayedJoin): Fix brace placement. + (CheckDelayedJoins): Fix brace placement and whitespace. + + * ircd/list.c (struct liststats): Add new fields to eliminate the + separate count variables. + (init_list): Adapt to those changes. + (alloc_client): Likewise. + (dealloc_client): Likewise. + (alloc_connection): Likewise. + (dealloc_connection): Likewise. + (make_server): Likewise. + (remove_client_from_list): Likewise. + (verify_client_list): Likewise. + (make_link): Likewise. + (free_link): Likewise. + (send_liststats): New function. + (send_listinfo): Rewrite to use new struct liststats layout. + + * ircd/m_burst.c (ms_burst): Adapt to changes in struct Ban. + + * ircd/m_clearmode.c (do_clearmode): Adapt to changes in struct + Ban. + + * ircd/s_stats.c (stats_meminfo): Define unconditionally and call + bans_send_meminfo(). + (statsinfo): Always give access to stats_meminfo. + +2005-06-16 Michael Poole <md...@tr...> + + * include/ircd_string.h: Include necessary <string.h> header. + + * ircd/test/.cvsignore: Ignore log output files. + + * ircd/test/Makefile.in: Remove log output files. + + * ircd/test/kill-block-1.cmd: Add sleeps to try to trigger Kills. + + * ircd/test/run-tests.sh: Switch sense of argument. Send an IRC + debug dump to log files. + +2005-06-13 Michael Poole <md...@tr...> + + * ircd/s_user.c (make_user): Unconditionally increment userCount. + (free_user): Unconditionally decrement it here. + + * ircd/s_conf.c (make_conf): Unconditionally increment + GlobalConfCount. + (free_conf): Unconditionally decrement it here. + + * ircd/s_debug.c (count_memory): Fix termination condition for + ban-walking loop. Add missing "e" to "members". + + +2005-06-10 Michael Poole <md...@tr...> + + * ircd/match.c (check_if_ipmask): Strings that contain '?' cannot + be true IP masks. + +2005-05-30 Michael Poole <md...@tr...> + + * ircd/test/Makefile.in: Add LDFLAGS variable for profiling purposes. + + * ircd/test/ircd_match_t.c: Test recovery from backtracking. + + * ircd/test/channel-1.cmd: Modify to improve code coverage. + + * ircd/test/client-1.cmd: Likewise. + + * ircd/test/gline-1.cmd: Likewise. + + * ircd/test/ircd-t1.conf: Likewise. + + * ircd/test/stats-1.cmd: Likewise. + + * ircd/test/run-tests.sh: Explicitly start ircds. Add new test scripts. + + * ircd/test/test-driver.pl: Silently handle more signals from IRC. + + * ircd/test/commands-1.cmd: New test script. + + * ircd/test/feature-1.cmd: New test script. + + * ircd/test/jupe-1.cmd: New test script. + + * ircd/test/kill-block-1.cmd: New test script. + + * ircd/test/ircd-t1-2.conf: New configuration file for test scripts. + + * ircd/test/ircd-t2.conf: Likewise. + +2005-05-30 Michael Poole <md...@tr...> + + * ircd/s_debug.c (count_memory): Use count_listener_memory() to + report memory used by listener structures. + +2005-05-30 Michael Poole <md...@tr...> + + * include/class.h (get_con_freq): Remove unused function. + + * include/list.h (find_user_link): Remove unused function. + + * include/class.c (get_con_freq): Remove. + + * ircd/list.c (find_user_link): Remove. + + * include/string.h (string_is_hostname, string_is_address, + strnChattr): Remove unused functions. + (init_string): Remove function that becomes a noop. + + * ircd/string.h (init_string): Remove. + (string_is_hostname, string_is_address, strnChattr): Likewise. + + * ircd/ircd.c (main): Remove call to init_string(). + +2005-05-30 Michael Poole <md...@tr...> + + * include/numeric.h (RPL_TRACELOG, RPL_MYPORTIS, + RPL_NOTOPERANYMORE): Undefine unused numeric replies. + + * ircd/s_err.c (replyTable): Fix format fields for certain numeric + arguments. Remove some unused entries. + + * ircd/s_stats.c (stats_configured_links): Move invariant + parameters to message format string. + +2005-05-30 Michael Poole <md...@tr...> + + * ircd/client.c (privtab): Add missing LIST_CHAN privilege, move + WIDE_GLINE to reflect its enumerated value. + + * ircd/s_debug.c (count_memory): Use user_count_memory() function + to count User structs in-use. + + * ircd/m_server.c (mr_server): Change "C:line" to "Connect block". + + * ircd/s_bsd.c (connect_server): Likewise. + + * ircd/s_conf.c (conf_check_server): Likewise. + + * ircd/s_err.c (replyTable): Change "O-lines" to "Operator block". + +2005-05-30 Michael Poole <md...@tr...> + + * ircd/match.c (match): Rewrite to handle globs that end in an + escaped wildcard (and hopefully clarify the code). + + * ircd/test/Makefile.in: Add new ircd_match_t test program. + + * ircd/test/ircd_match_t.c: New file. + + * ircd/test/test_stub.c: Emite newlines after log and debug + messages. + +2005-05-25 Reed Loden <re...@re...> + + * ircd/s_err.c (replyTable): Allow for the specification of 'O' or + 'o' in RPL_STATSOLINE. + + * ircd/s_stats.c (stats_configured_links): In /stats o/O, display + 'O' if either the oper block or the connection class has + PRIV_PROPAGATE (global oper) and 'o' if neither has PRIV_PROPAGATE + (local oper). + +2005-05-30 Michael Poole <md...@tr...> + + * ircd/IPcheck.c: Add Debug()s to try to track why the connected + count underflows. + + * ircd/m_endburst.c (ms_endofburst): Avoid dereferencing 'chan' + after it may be freed (in sub1_from_channel). + + * ircd/s_user.c (register_user): Rearrange code to reduce number + of "if (MyConnect(sptr))" checks. + +2005-05-12 Michael Poole <md...@tr...> + + * configure.in: Do not try to outsmart the default CFLAGS. + Simply add parameters explicitly requested by the user. + + * configure: Regenerate. + + * ircd/ircd_crypt_native.c: Use _XOPEN_SOURCE 600 (which is + used in os_generic.c) to get crypt() on NetBSD. + +2005-05-11 Kevin L. Mitchell <kl...@mi...> + + * ircd/ircd.c: if debugging is enabled (both DEBUGMODE defined and + -x given), reserve fd 2 for the use of the debugging log; + otherwise, some engines may attempt to use fd 2, which would end + up getting closed by debug_init() (actually, by + log_debug_reopen(), called by log_debug_init(), called by + debug_init()) + +2005-08-10 Michael Poole <md...@tr...> + + * ircd/channel.c (joinbuf_join): Do not send a MODE +o when a + local user creates a channel. + + * ircd/umkpasswd.c (crypt_pass): Allocate the proper amount of + memory for the tagged output string. + + * ircd/test/test-driver.pl: Add -vhost=... option. + + * ircd/test/ircd-t1.conf: Add new Operator blocks. + + * ircd/test/*.cmd: Rearrange and add more coverage tests. + +2005-08-09 Michael Poole <md...@tr...> + + * ircd/ircd_parser.y: Move error tokens to top level of parse, and + make ';' a synchronizing token for them. This avoids crashes in + situations like missing ';' between two Kill blocks. Move several + ';'s earlier for earlier detection of syntax errors. + + * ircd/motd.c (motd_memory_count): Use size_t for memory counts to + match the format strings used for those variables. + + * ircd/msgq.c (msgq_histogram): tmp.sizes[] is an array of + unsigned int, not unsigned long; use correct format string. + + * ircd/s_stats.c (stats_crule_list): Restore display of 'D' vs 'd' + based on crule type, rather than query type. + (statsinfo): Remove STAT_FLAG_VARPARAM from the "modules" and + "help" stats, which don't use the varparam. + + * ircd/test/test-driver.pl: Interpreter for test scripts.b + + * ircd/test/ircd-t1.conf: Configuration file for test scripts. + + * ircd/test/*.cmd: New test scripts for test-driver.pl. + +2005-05-08 Jukka Ollila <jao...@ni...> + (Adapted slightly by Michael Poole.) + + * ircd/os_generic.c (sockaddr_to_irc): Change to use v4compat + addresses event when !defined(IPV6). + +2005-05-07 Michael Poole <md...@tr...> + + * ircd/channel.c (joinbuf_join): Be smarter about what source to + use when opping a user that joins a channel. + +2005-05-04 Reed Loden <re...@re...> + + * ircd/m_trace.c (do_trace): Show the real nickname instead of the + numnick. + +2005-05-02 Jan Krueger <ja...@he...> + + * ircd/channel.c (member_can_send_to_channel): if the channel can only + be joined by users with accounts (+r), do not allow users without + accounts to speak. + +2005-05-07 Michael Poole <md...@tr...> + + * ircd/numnicks.c (base64toip): Fix bugs in parsing IPv6 + addresses. + * ircd/test/ircd_in_addr_t.c (test_addrs): Add new entry. + (test_address): Test base64toip() as well. + +2005-05-05 Michael Poole <md...@tr...> + + * ircd/s_user.c (umode_str): Only clear the operator flag when not + propagating; never set it. + +2005-05-04 Michael Poole <md...@tr...> + + * ircd/channel.c (joinbuf_join): Include channel manager flag in + determination of oplevel. If opping the user for a non-local + non-create, include oplevel in message to other servers. Send + "MODE +o <client>" to local users whenever opping the client. + + * ircd/m_join.c (m_join): Remove logic that moved into + joinbuf_join(). + (ms_join): Look for level 0 and 1 joins from remote servers + and adjust value of 'flags' appropriately. + +2005-05-04 Michael Poole <md...@tr...> + + * include/numeric.h: Remap oplevel numerics to new range. + + * ircd/s_err.c: Likewise. + +2005-05-03 Michael Poole <md...@tr...> + + * ircd/s_stats.c (stats_access): Update to use new CONF_CLIENT + fields, fixing crash found by nighty. + +2005-05-02 Michael Poole <md...@tr...> + + * include/numeric.h (ERR_UPASS_SAME_APASS): New error message when + trying to set +U pass to the same as the +A pass. + + * ircd/channel.c (mode_parse_upass): Use it. + + * ircd/ircd_auth.c (iauth_exit_client): Only send ExitUser if + there is an active IAuth connection, fixing PR#1193808. + (iauth_dispose_request): Only delete the timer if it is active. + + * ircd/m_invite.c (m_invite): Always forward the invite in the + correct direction, and then skip it as 'one' if announcing. + (ms_invite): Likewise. + + * ircd/numnicks.c (base64toip): Do not interpret AAAAAA as + ::ffff:0.0.0.0; keep it as ::. + + * ircd/s_err.c (replyTable): Add ERR_UPASS_SAME_APASS. + +2005-05-01 Michael Poole <md...@tr...> + + * doc/readme.log: Document IAUTH log target, remove docs for + OLDLOG log target. + + * include/ircd_log.h: Add LS_IAUTH target, remove LS_OLDLOG. + + * ircd/ircd_log.c (logDesc): Likewise. + + * ircd/engine_epoll.c (engine_loop): Handle EPOLLHUP for all + sockets (e.g. when connecting) and do not generate read/write + events in the same pass as error or EOF events. + + * ircd/ircd_auth.c: Convert old sendto and debug messages to use + the LS_IAUTH log target. Consistently use IAUTH_CONNECTED flag + instead of comparing fd to -1. + (iauth_reconnect): If already connected, disconnect and schedule a + reconnect later, since an immediate reconnect can cause assertion + failure in the event engine. Also schedule a reconnect when the + connection attempt fails. + (iauth_read): Reconnect on IO_FAILURE. + (iauth_sock_callback): Disconnect and schedule a reconnect on both + error (after reporting the error) and EOF. + (iauth_start_client): Record the IAuth request in the client. + (iauth_exit_client): Report the client exit. + + * ircd/s_misc.c (exit_one_client): Fix formatting. + +2005-04-30 Michael Poole <md...@tr...> + + * ircd/ircd_auth.c (iauth_connect): Initialize (but do not add) + timer here and set fd to -1. + (iauth_schedule_reconnect): Rewrite to handle previously + initialized timer. + (iauth_reconnect): If server is connected, disconnect first. + Update socket generator fd before calling socket_add(). + (iauth_read): When reading 0 bytes (EOF), reconnect. + +2005-04-27 Michael Poole <md...@tr...> + + * ircd/ircd_parser.y: Report non-existent class names as errors + earlier, and do not fall back to "default" for Client blocks. + +2005-04-25 Reed Loden <re...@re...> + + * ircd/ircd_lexer.l: Add missing header to squash a warning. + +2005-04-25 Michael Poole <md...@tr...> + + * ircd/s_user.c (register_user): Replace call with set_user_mode() + with a direct parsing of user modes. To match this, revert the + initial display of usermode to how it was done before. + +2005-04-24 Michael Poole <md...@tr...> + + * doc/example.conf: Document new autoconnect field of Connect. + + * include/s_conf.h: Add CONF_AUTOCONNECT and field for it. + + * ircd/ircd.c (try_connections): Skip non-autoconnect servers. + + * ircd/ircd_lexer.l: Recognize autoconnect token. + + * ircd/ircd_parser.y: Add autoconnect= option to Connect block. + + * ircd/m_invite.c (m_invite): Avoid sending channel timestamp to + user being invited. + (ms_invite): Likewise. + + * ircd/s_user.c (register_user): Show class name rather than + pointer-as-integer. + +2005-04-24 Michael Poole <md...@tr...> + + * ircd/ircd_parser.y: Rewrite so each error condition gets its own + error message, and so that invalid parameters are printed out. + +2005-04-23 Michael Poole <md...@tr...> + + * ircd/channel.c (apply_ban): Consistently free newban->banstr + when the function fails. + (mode_process_bans): Free banstr for all BAN_DEL bans. + + * ircd/ircd_parser.y: Fix a few memory leaks from previous commit. + +2005-04-23 Michael Poole <md...@tr...> + + * include/patchlevel.h: Bump to being a beta. + + * ircd/ircd_lexer.l (QSTRING): Return a copy of the string so that + parser actions don't have to be immediately after a QSTRING. + + * ircd/ircd_parser.y (FNAME): Remove unused token. + (QSTRING): Adjust for QSTRING being an already-copied version. + +2005-04-23 Michael Poole <md...@tr...> + + * doc/example.conf (UWorld): Illustrate new config extension. + + * ircd/ircd_parser.y (uworldblock): Do the expected thing when + multiple name= entries are present. + +2005-04-22 Michael Poole <md...@tr...> + + * RELEASE.NOTES: Silence exceptions use ~, not -. Oops! + + * doc/example.conf: Fix typo in example Kill block. + + * ircd/channel.c (mode_parse_ban): Use correct test for flag_p. + + * ircd/m_silence.c (apply_silence): Make mask pretty so that later + processing does not convert * to @ (and match no one). + +2005-04-21 Kevin L. Mitchell <kl...@mi...> + + * ircd/m_userip.c (userip_formatter): /userip should *never* + report the user's real IP unless its answering the user + him/herself + + * ircd/m_userhost.c (userhost_formatter): /userhost should *never* + report the user's real host unless its answering the user + him/herself + +2005-04-20 Michael Poole <md...@tr...> + + * ircd/ircd.c (parse_command_line): Update usage text. + + * ircd/numnicks.c (base64toip): Use v4mapped address range instead + of v4compat address range, fixing IPv4-based /who. + +2005-04-19 Michael Poole <md...@tr...> + + * configure.in: When --enable-profile, add -pg to LDFLAGS. + + * configure: Regenerate. + +2005-04-19 Michael Poole <md...@tr...> + + * ircd/match.c (check_if_ipmask): Fix brown-paper-bag typo. + + * ircd/s_conf.c (conf_debug_iline): Look for matching Kill blocks + once a matching Client block is found. + + * ircd/m_whowas.c (m_whowas): Change strcmp() to ircd_strcmp(). + +2005-04-18 Michael Poole <md...@tr...> + + * ircd/match.c (check_if_ipmask): Do not interpret masks that + start with . or / as IP-based host masks. + +2005-04-17 Michael Poole <md...@tr...> + + * ircd/channel.c (mode_process_clients): Only prohibit deops of + users with the same or higher oplevel where apass is set. + Likewise, when opping users, give them MAXOPLEVEL for non-apass + channels. + (joinbuf_join): Give new ops MAXOPLEVEL for non-apass channels. + + * ircd/m_kick.c (m_kick): Only prohibit kicks of users with the + same or higher oplevel where apass is set. + + * ircd/s_user.c (register_user): Fix order of server version vs + various mode strings. + + * tools/linesync/linesync.sh: Add revision id field. + +2005-04-17 Michael Poole <md...@tr...> + + * tools/linesync/linesync.sh: Fix typo comment. Check for + multiple blocks per line in the linesync input. + +2005-04-17 Dan <da...@un...> + + * tools/linesync/linesync.sh: Update to support new syntax and to + avoid rehashing the ircd when the config is the same. + + * tools/linesync/linesync.conf: Update allowed conf items. + +2005-04-16 Michael Poole <mdpoole@troil... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-10-13 10:02:18
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-13 10:02:08 UTC Modified files: TODO.es Log message: actualizacion todo ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.29 ircd-ircdev/TODO.es:1.30 --- ircd-ircdev/TODO.es:1.29 Thu Sep 1 04:33:58 2005 +++ ircd-ircdev/TODO.es Thu Oct 13 03:01:58 2005 @@ -1,10 +1,14 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.29 2005/09/01 11:33:58 zolty Exp $ +# $Id: TODO.es,v 1.30 2005/10/13 10:01:58 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # +URGENTISIMO + - Pasar el codigo de alpha a BETA. Hay que revisar codigo por .c por +.c. Esto es debido a que la base del ircd ya se utiliza en producción. + URGENTE -------------------------------------------------------------------------------------- ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-10-17 14:02:50
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-17 14:02:42 UTC Modified files: ChangeLog ChangeLog.es doc/ircd.sample-en.conf doc/ircd.sample-es.conf include/channel.h include/ircd_string.h include/match.h include/patchlevel.h ircd/Makefile.in ircd/channel.c ircd/ddb_db_native.c ircd/gline.c ircd/ircd.c ircd/ircd_string.c ircd/m_burst.c ircd/m_invite.c ircd/m_join.c ircd/m_mode.c ircd/m_names.c ircd/m_opmode.c ircd/m_ping.c ircd/match.c ircd/s_conf.c ircd/test/ircd_in_addr_t.c Added files: ircd/convert-conf.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-10-17 Toni García <zo...@ir...> 1.0.alpha44 * Sincronización Undernet ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.45 ircd-ircdev/ChangeLog:1.46 --- ircd-ircdev/ChangeLog:1.45 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/ChangeLog Mon Oct 17 07:02:32 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.45 2005/09/01 11:25:42 zolty Exp $ +# $Id: ChangeLog,v 1.46 2005/10/17 14:02:32 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-10-17 Toni García <zo...@ir...> 1.0.alpha44 + * Undernet synchronization + 2005-09-01 Toni García <zo...@ir...> 1.0.alpha43 * Undernet synchronization Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.45 ircd-ircdev/ChangeLog.es:1.46 --- ircd-ircdev/ChangeLog.es:1.45 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/ChangeLog.es Mon Oct 17 07:02:32 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.45 2005/09/01 11:25:42 zolty Exp $ +# $Id: ChangeLog.es,v 1.46 2005/10/17 14:02:32 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-10-17 Toni García <zo...@ir...> 1.0.alpha44 + * Sincronización Undernet + 2005-09-01 Toni García <zo...@ir...> 1.0.alpha43 * Sincronización Undernet Index: ircd-ircdev/doc/ircd.sample-en.conf diff -u ircd-ircdev/doc/ircd.sample-en.conf:1.22 ircd-ircdev/doc/ircd.sample-en.conf:1.23 --- ircd-ircdev/doc/ircd.sample-en.conf:1.22 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/doc/ircd.sample-en.conf Mon Oct 17 07:02:32 2005 @@ -800,7 +800,7 @@ # "GLINEMAXUSERCOUNT" = "20"; # "SOCKSENDBUF" = "61440"; # "SOCKRECVBUF" = "61440"; -# "IPCHECK_CLONE_LIMIT = 24"; +# "IPCHECK_CLONE_LIMIT = "24"; # "IPCHECK_CLONE_PERIOD = "40"; # "IPCHECK_CLONE_DELAY = "600"; # "MPATH" = "ircd.motd"; @@ -859,7 +859,7 @@ # "HIS_BANWHO" = "TRUE"; # "HIS_KILLWHO" = "TRUE"; # "HIS_REWRITE" = "TRUE"; -# "HIS_REMOTE" = 1; +# "HIS_REMOTE" = "1"; # "HIS_NETSPLIT" = TRUE"; # "HIS_SERVERNAME" = "*.irc-dev.net"; # "HIS_SERVERINFO" = "IRC-Dev.Net, Desarrollo de IRC / IRC Development"; Index: ircd-ircdev/doc/ircd.sample-es.conf diff -u ircd-ircdev/doc/ircd.sample-es.conf:1.17 ircd-ircdev/doc/ircd.sample-es.conf:1.18 --- ircd-ircdev/doc/ircd.sample-es.conf:1.17 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/doc/ircd.sample-es.conf Mon Oct 17 07:02:32 2005 @@ -838,7 +838,7 @@ # "GLINEMAXUSERCOUNT" = "20"; # "SOCKSENDBUF" = "61440"; # "SOCKRECVBUF" = "61440"; -# "IPCHECK_CLONE_LIMIT = 24"; +# "IPCHECK_CLONE_LIMIT = "24"; # "IPCHECK_CLONE_PERIOD = "40"; # "IPCHECK_CLONE_DELAY = "600"; # "MPATH" = "ircd.motd"; @@ -897,7 +897,7 @@ # "HIS_BANWHO" = "TRUE"; # "HIS_KILLWHO" = "TRUE"; # "HIS_REWRITE" = "TRUE"; -# "HIS_REMOTE" = 1; +# "HIS_REMOTE" = "1"; # "HIS_NETSPLIT" = TRUE"; # "HIS_SERVERNAME" = "*.irc-dev.net"; # "HIS_SERVERINFO" = "IRC-Dev.Net, Desarrollo de IRC / IRC Development"; Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.13 ircd-ircdev/include/channel.h:1.14 --- ircd-ircdev/include/channel.h:1.13 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/include/channel.h Mon Oct 17 07:02:32 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Channel management and maintenance. - * @version $Id: channel.h,v 1.13 2005/09/01 11:25:42 zolty Exp $ + * @version $Id: channel.h,v 1.14 2005/10/17 14:02:32 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -213,10 +213,6 @@ */ #define MAGIC_REMOTE_JOIN_TS 1270080000 -/** - * used in can_join to determine if an oper forced a join on a channel - */ -#define MAGIC_OPER_OVERRIDE 1000 extern const char* const PartFmt1; @@ -430,7 +426,6 @@ /* * Proto types */ -extern void clean_channelname(char* name); extern void channel_modes(struct Client *cptr, char *mbuf, char *pbuf, int buflen, struct Channel *chptr, struct Membership *member); @@ -445,7 +440,6 @@ const struct Client* cptr); extern int sub1_from_channel(struct Channel* chptr); extern int destruct_channel(struct Channel* chptr); -extern int can_join(struct Client *sptr, struct Channel *chptr, char *key); extern void add_user_to_channel(struct Channel* chptr, struct Client* who, unsigned int flags, int oplevel); extern void make_zombie(struct Membership* member, struct Client* who, Index: ircd-ircdev/include/ircd_string.h diff -u ircd-ircdev/include/ircd_string.h:1.6 ircd-ircdev/include/ircd_string.h:1.7 --- ircd-ircdev/include/ircd_string.h:1.6 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/include/ircd_string.h Mon Oct 17 07:02:32 2005 @@ -21,7 +21,7 @@ */ /** @file ircd_string.h * @brief Public declarations and APIs for string operations. - * @version $Id: ircd_string.h,v 1.6 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: ircd_string.h,v 1.7 2005/10/17 14:02:32 zolty Exp $ */ #ifndef INCLUDED_ircd_string_h #define INCLUDED_ircd_string_h @@ -51,7 +51,8 @@ char** vector, int size); extern const char* ircd_ntoa(const struct irc_in_addr* addr); extern const char* ircd_ntoa_r(char* buf, const struct irc_in_addr* addr); -extern int ircd_aton(struct irc_in_addr *addr, const char *str); +#define ircd_aton(ADDR, STR) ipmask_parse((STR), (ADDR), NULL) +extern int ipmask_parse(const char *in, struct irc_in_addr *mask, unsigned char *bits_ptr); extern char* host_from_uh(char* buf, const char* userhost, size_t len); extern char* ircd_strtok(char** save, char* str, char* fs); Index: ircd-ircdev/include/match.h diff -u ircd-ircdev/include/match.h:1.4 ircd-ircdev/include/match.h:1.5 --- ircd-ircdev/include/match.h:1.4 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/match.h Mon Oct 17 07:02:32 2005 @@ -21,7 +21,7 @@ */ /** @file match.h * @brief Interface for matching strings to IRC masks. - * @version $Id: match.h,v 1.4 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: match.h,v 1.5 2005/10/17 14:02:32 zolty Exp $ */ #ifndef INCLUDED_match_h #define INCLUDED_match_h @@ -51,8 +51,6 @@ extern int matchdecomp(char *mask, const char *cmask); extern int mmexec(const char *wcm, int wminlen, const char *rcm, int rminlen); -extern int check_if_ipmask(const char *mask); -extern int ipmask_parse(const char *in, struct irc_in_addr *mask, unsigned char *bits_ptr); extern int ipmask_check(const struct irc_in_addr *addr, const struct irc_in_addr *mask, unsigned char bits); #endif /* INCLUDED_match_h */ Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.44 ircd-ircdev/include/patchlevel.h:1.45 --- ircd-ircdev/include/patchlevel.h:1.44 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/include/patchlevel.h Mon Oct 17 07:02:32 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.44 2005/09/01 11:25:42 zolty Exp $ + * $Id: patchlevel.h,v 1.45 2005/10/17 14:02:32 zolty Exp $ * */ -#define PATCHLEVEL ".alpha43" +#define PATCHLEVEL ".alpha44" #define RELEASE "1.0" Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.27 ircd-ircdev/ircd/Makefile.in:1.28 --- ircd-ircdev/ircd/Makefile.in:1.27 Wed May 25 09:56:23 2005 +++ ircd-ircdev/ircd/Makefile.in Mon Oct 17 07:02:32 2005 @@ -18,7 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.27 2005/05/25 16:56:23 zolty Exp $ +# $Id: Makefile.in,v 1.28 2005/10/17 14:02:32 zolty Exp $ #### Start of system configuration section. #### @@ -69,6 +69,9 @@ PURIFY = RINGLOG_O = +CONVERT_CONF_SRC = \ + convert-conf.c + ENGINE_SRC = \ engine_devpoll.c \ engine_epoll.c \ @@ -261,6 +264,8 @@ UMKPASSWD_OBJS = ${UMKPASSWD_SRC:%.c=%.o} +CONVERT_CONF_OBJS = ${CONVERT_CONF_SRC:%.c=%.o} + DEP_SRC = ${IRCD_SRC} ${UNDERNET_SRC} ${DDB_SRC} ${SERVICES_SRC} ${ENGINE_SRC} ${CRYPTO_SRC} all: @@ -271,13 +276,16 @@ .c.o: ${CC} ${CFLAGS} ${CPPFLAGS} -c $< -o $@ -build: ircd +build: ircd convert-conf ircd: ${OBJS} ../include/patchlevel.h version.o ${PURIFY} ${CC} ${OBJS} version.o ${RINGLOG_O} ${LDFLAGS} ${LIBS} \ -o ircd ${CHMOD} ${IRCDMODE} ircd +convert-conf: ${CONVERT_CONF_OBJS} + ${PURIFY} ${CC} ${CONVERT_CONF_OBJS} ${LDFLAGS} -o convert-conf + # # Make sure the anti hack checksums get included when things change # bleah @@ -356,7 +364,7 @@ @echo "Please remove the contents of ${DPATH} manually" clean: - ${RM} -f *.o *.bak ircd version.c umkpasswd ircd_osdep.c chattr.tab.c table_gen y.tab.* lex.yy.* + ${RM} -f *.o *.bak ircd version.c umkpasswd convert-conf chattr.tab.c table_gen y.tab.* lex.yy.* distclean: clean ${RM} -f Makefile stamp-m Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.25 ircd-ircdev/ircd/channel.c:1.26 --- ircd-ircdev/ircd/channel.c:1.25 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/ircd/channel.c Mon Oct 17 07:02:32 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Channel management and maintanance - * @version $Id: channel.c,v 1.25 2005/09/01 11:25:42 zolty Exp $ + * @version $Id: channel.c,v 1.26 2005/10/17 14:02:32 zolty Exp $ */ #include "config.h" @@ -368,12 +368,15 @@ #if defined(UNDERNET) char tmphost[HOSTLEN + 1]; #endif + char iphost[SOCKIPLEN + 1]; + char *hostmask; char *sr; struct Ban *found; /* Build nick!user and alternate host names. */ ircd_snprintf(0, nu, sizeof(nu), "%s!%s", cli_name(cptr), cli_user(cptr)->username); + ircd_ntoa_r(iphost, &cli_ip(cptr)); #if defined(UNDERNET) if (!IsAccount(cptr)) @@ -403,11 +406,13 @@ if (res) continue; /* Compare host portion of ban. */ + hostmask = banlist->banstr + banlist->nu_len + 1; if (!((banlist->flags & BAN_IPMASK) && ipmask_check(&cli_ip(cptr), &banlist->address, banlist->addrbits)) - && match(banlist->banstr + banlist->nu_len + 1, cli_user(cptr)->host) - && !(sr && match(banlist->banstr + banlist->nu_len + 1, sr) == 0)) + && match(hostmask, cli_user(cptr)->host) + && !(sr && match(hostmask, sr))) continue; + /* If an exception matches, no ban can match. */ if (banlist->flags & BAN_EXCEPTION) return NULL; @@ -1320,106 +1325,6 @@ send_reply(cptr, RPL_ENDOFBANLIST, chptr->chname); } -/** Check a key against a keyring. - * We are now treating the key part of /join channellist key as a key - * ring; that is, we try one key against the actual channel key, and if that - * doesn't work, we try the next one, and so on. -Kev -Texaco - * Returns: 0 on match, 1 otherwise - * This version contributed by SeKs \<in...@in...\> - * - * @param key Key to check - * @param keyring Comma separated list of keys - * - * @returns True if the key was found and matches, false otherwise. - */ -static int compall(char *key, char *keyring) -{ - char *p1; - -top: - p1 = key; /* point to the key... */ - while (*p1 && *p1 == *keyring) - { /* step through the key and ring until they - don't match... */ - p1++; - keyring++; - } - - if (!*p1 && (!*keyring || *keyring == ',')) - /* ok, if we're at the end of the and also at the end of one of the keys - in the keyring, we have a match */ - return 0; - - if (!*keyring) /* if we're at the end of the key ring, there - weren't any matches, so we return 1 */ - return 1; - - /* Not at the end of the key ring, so step - through to the next key in the ring: */ - while (*keyring && *(keyring++) != ','); - - goto top; /* and check it against the key */ -} - -/** Returns if a user can join a channel with a specific key. - * - * @param sptr The client trying to join - * @param chptr The channel to join - * @param key The key to use - * - * @returns any error that occurred bitwised OR'd with MAGIC_OPER_OVERRIDE - * if the oper used the magic key, 0 if no error occured. - */ -int can_join(struct Client *sptr, struct Channel *chptr, char *key) -{ - int overrideJoin = 0; - - /* - * Now a banned user CAN join if invited -- Nemesi - * Now a user CAN escape channel limit if invited -- bfriendly - * Now a user CAN escape anything if invited -- Isomer - */ - - if (IsInvited(sptr, chptr)) - return 0; - - /* An oper can force a join on a local channel using "OVERRIDE" as the key. - a HACK(4) notice will be sent if he would not have been supposed - to join normally. */ - if (IsLocalChannel(chptr->chname) && HasPriv(sptr, PRIV_WALK_LCHAN) && - !BadPtr(key) && compall("OVERRIDE",chptr->mode.key) != 0 && - compall("OVERRIDE",key) == 0) - overrideJoin = MAGIC_OPER_OVERRIDE; - - if (chptr->mode.mode & MODE_INVITEONLY) - return overrideJoin + ERR_INVITEONLYCHAN; - - if (chptr->mode.limit && chptr->users >= chptr->mode.limit) - return overrideJoin + ERR_CHANNELISFULL; - - if ((chptr->mode.mode & MODE_REGONLY) && -#if defined(UNDERNET) - !IsAccount(sptr)) -#elif defined(DDB) || defined(SERVICES) - !IsNickRegistered(sptr)) -#endif - return overrideJoin + ERR_NEEDREGGEDNICK; - - if (find_ban(sptr, chptr->banlist)) - return overrideJoin + ERR_BANNEDFROMCHAN; - - /* - * now using compall (above) to test against a whole key ring -Kev - */ - if (*chptr->mode.key && (EmptyString(key) || compall(chptr->mode.key, key))) - return overrideJoin + ERR_BADCHANNELKEY; - - if (overrideJoin) - return ERR_DONTCHEAT; - - return 0; -} - /** Remove bells and commas from channel name * * @param cn Channel name to clean, modified in place. @@ -3639,9 +3544,7 @@ assert(0 != jbuf); if (!chan) { - if (jbuf->jb_type == JOINBUF_TYPE_JOIN) - sendcmdto_serv_butone(jbuf->jb_source, CMD_JOIN, jbuf->jb_connect, "0"); - + sendcmdto_serv_butone(jbuf->jb_source, CMD_JOIN, jbuf->jb_connect, "0"); return; } Index: ircd-ircdev/ircd/convert-conf.c diff -u /dev/null ircd-ircdev/ircd/convert-conf.c:1.1 --- /dev/null Mon Oct 17 07:02:43 2005 +++ ircd-ircdev/ircd/convert-conf.c Mon Oct 17 07:02:32 2005 @@ -0,0 +1,650 @@ +/* + * IRC-Dev IRCD - An advanced and innovative IRC Daemon, ircd/convert-conf.c + * + * Copyright (C) 2002-2005 IRC-Dev Development Team <de...@ir...> + * Copyright (C) 2005 Michael Poole + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * $Id: convert-conf.c,v 1.1 2005/10/17 14:02:32 zolty Exp $ + * convert-conf.c - Convert ircu2.10.11 ircd.conf to ircu2.10.12 format. + * + */ + +#include <ctype.h> /* tolower(), toupper(), isdigit() */ +#include <stdio.h> /* *printf(), fgets() */ +#include <stdlib.h> /* free(), strtol() */ +#include <string.h> /* strlen(), memcpy(), strchr(), strspn() */ + +#define MAX_FIELDS 5 + +const char *admin_names[] = { "location", "contact", "contact", 0 }, + *connect_names[] = { "host", "password", "name", "#port", "class", 0 }, + *crule_names[] = { "server", "", "rule", 0 }, + *general_names[] = { "name", "vhost", "description", "", "#numeric", 0 }, + *motd_names[] = { "host", "file", 0 }, + *class_names[] = { "name", "#pingfreq", "#connectfreq", "#maxlinks", "#sendq", 0 }, + *removed_features[] = { "VIRTUAL_HOST", "OPERS_SEE_IN_SECRET_CHANNELS", "LOCOP_SEE_IN_SECRET_CHANNELS", 0 }; +char orig_line[512], line[512], dbuf[512]; +char *fields[MAX_FIELDS + 1]; +unsigned int nfields; +unsigned int lineno; + +/*** GENERIC SUPPORT CODE ***/ + +static int split_line(char *input, char **output) +{ + size_t quoted = 0, jj; + char *dest = dbuf, ch; + + nfields = 1; + output[0] = dest; + while (*input != '\0' && *input != '#') switch (ch = *input++) { + case ':': + if (quoted) + *dest++ = ch; + else { + *dest++ = '\0'; + if (nfields >= MAX_FIELDS) + return nfields; + output[nfields++] = dest; + } + break; + case '\\': + switch (ch = *input++) { + case 'b': *dest++ = '\b'; break; + case 'f': *dest++ = '\f'; break; + case 'n': *dest++ = '\n'; break; + case 'r': *dest++ = '\r'; break; + case 't': *dest++ = '\t'; break; + case 'v': *dest++ = '\v'; break; + default: *dest++ = ch; break; + } + break; + case '"': quoted = !quoted; break; + default: *dest++ = ch; break; + } + + *dest = '\0'; + for (jj = nfields; jj < MAX_FIELDS; ++jj) + output[jj] = dest; + return nfields; +} + +static void simple_line(const char *block, const char **names, const char *extra) +{ + size_t ii; + + /* Print the current line and start the new block. */ + fprintf(stdout, "# %s\n%s {\n", orig_line, block); + + /* Iterate over fields in input line, formatting each. */ + for (ii = 0; ii < nfields && names[ii]; ++ii) { + if (!fields[ii][0] || !names[ii][0]) + continue; + else if (names[ii][0] == '#') + fprintf(stdout, "\t%s = %s;\n", names[ii] + 1, fields[ii]); + else + fprintf(stdout, "\t%s = \"%s\";\n", names[ii], fields[ii]); + } + + /* Close the new block (including any fixed-form text). */ + if (extra) + fprintf(stdout, "\t%s\n", extra); + fputs("};\n", stdout); +} + +#define dupstring(TARGET, SOURCE) do { free(TARGET); if (SOURCE) { size_t len = strlen(SOURCE); (TARGET) = malloc(len+1); memcpy((TARGET), (SOURCE), len); } else (TARGET) = 0; } while(0) + +/*** MANAGING LISTS OF STRINGS ***/ + +struct string_list { + struct string_list *next; + char *origin; + char *extra; + char value[1]; +}; + +static struct string_list *string_get(struct string_list **list, const char *value) +{ + struct string_list *curr; + size_t len = strlen(value), ii; + + while ((curr = *list)) { + for (ii = 0; tolower(curr->value[ii]) == tolower(value[ii]) && ii < len; ++ii) ; + if (curr->value[ii] == '\0' && value[ii] == '\0') + return curr; + list = &curr->next; + } + + *list = calloc(1, sizeof(**list) + len); + memcpy((*list)->value, value, len); + return *list; +} + +/*** SERVER CONNECTION RELATED CODE ***/ + +struct connect { + char *host; + char *password; + char *port; + char *class; + char *hub; + char *maximum; + struct connect *next; + struct string_list *origins; + char name[1]; +} *connects; + +static struct connect *get_connect(const char *name) +{ + struct connect *conn; + size_t ii, nlen; + + /* Look for a pre-existing connection with the same name. */ + nlen = strlen(name); + for (conn = connects; conn; conn = conn->next) + { + for (ii = 0; tolower(name[ii]) == conn->name[ii] && ii < nlen; ++ii) ; + if (conn->name[ii] == '\0' && name[ii] == '\0') + break; + } + + /* If none was found, create a new one. */ + if (!conn) + { + conn = calloc(1, sizeof(*conn) + nlen); + for (ii = 0; ii < nlen; ++ii) + conn->name[ii] = tolower(name[ii]); + conn->next = connects; + connects = conn; + } + + /* Return the connection. */ + return conn; +} + +static void do_connect(void) +{ + struct connect *conn = get_connect(fields[2]); + dupstring(conn->host, fields[0]); + dupstring(conn->password, fields[1]); + dupstring(conn->port, fields[3]); + dupstring(conn->class, fields[4]); + string_get(&conn->origins, orig_line); +} + +static void do_hub(void) +{ + struct connect *conn = get_connect(fields[2]); + dupstring(conn->hub, fields[0]); + dupstring(conn->maximum, fields[3]); + string_get(&conn->origins, orig_line); +} + +static void do_leaf(void) +{ + struct connect *conn = get_connect(fields[2]); + free(conn->hub); + conn->hub = 0; + string_get(&conn->origins, orig_line); +} + +static void finish_connects(void) +{ + struct connect *conn; + struct string_list *sl; + + for (conn = connects; conn; conn = conn->next) + { + for (sl = conn->origins; sl; sl = sl->next) + fprintf(stdout, "# %s\n", sl->value); + fprintf(stdout, + "Connect {\n\tname =\"%s\";\n\thost = \"%s\";\n" + "\tpassword = \"%s\";\n\tclass = \"%s\";\n", + conn->name, conn->host, conn->password, conn->class); + if (conn->port && conn->port[0] != '\0') + fprintf(stdout, "\tport = %s;\n", conn->port); + else + fprintf(stdout, + "# Every Connect block should have a port number.\n" + "# To prevent autoconnects, set autoconnect = no.\n" + "#\tport = 4400;\n" + "\tautoconnect = no;\n"); + if (conn->maximum && conn->maximum[0] != '\0') + fprintf(stdout, "\tmaxhops = %s;\n", conn->maximum); + if (conn->hub && conn->hub[0] != '\0') + fprintf(stdout, "\thub = \"%s\";\n", conn->hub); + fprintf(stdout, "};\n\n"); + + } +} + +/*** FEATURE MANAGEMENT CODE ***/ + +struct feature { + struct string_list *values; + struct string_list *origins; + struct feature *next; + char name[1]; +} *features; + +struct remapped_feature { + const char *name; + const char *privilege; + int flags; /* 2 = global, 1 = local */ + struct feature *feature; +} remapped_features[] = { + /* Specially handled privileges: If you change the index of + * anything with NULL privilege, change the code in + * finish_operators() to match! + */ + { "CRYPT_OPER_PASSWORD", NULL, 0, 0 }, /* default: true */ + { "OPER_KILL", NULL, 2, 0 }, /* default: true */ + { "LOCAL_KILL_ONLY", NULL, 2, 0 }, /* default: false */ + /* remapped features that affect all opers */ + { "OPER_NO_CHAN_LIMIT", "chan_limit", 3, 0 }, + { "OPER_MODE_LCHAN", "mode_lchan", 3, 0 }, + { "OPER_WALK_THROUGH_LMODES", "walk_lchan", 3, 0 }, + { "NO_OPER_DEOP_LCHAN", "deop_lchan", 3, 0 }, + { "SHOW_INVISIBLE_USERS", "show_invis", 3, 0 }, + { "SHOW_ALL_INVISIBLE_USERS", "show_all_invis", 3, 0 }, + { "UNLIMIT_OPER_QUERY", "unlimit_query", 3, 0 }, + /* remapped features affecting only global opers */ + { "OPER_REHASH", "rehash", 2, 0 }, + { "OPER_RESTART", "restart", 2, 0 }, + { "OPER_DIE", "die", 2, 0 }, + { "OPER_GLINE", "gline", 2, 0 }, + { "OPER_LGLINE", "local_gline", 2, 0 }, + { "OPER_JUPE", "jupe", 2, 0 }, + { "OPER_LJUPE", "local_jupe", 2, 0 }, + { "OPER_OPMODE", "opmode", 2, 0 }, + { "OPER_LOPMODE", "local_opmode", 2, 0 }, + { "OPER_FORCE_OPMODE", "force_opmode", 2, 0 }, + { "OPER_FORCE_LOPMODE", "force_local_opmode", 2, 0 }, + { "OPER_BADCHAN", "badchan", 2, 0 }, + { "OPER_LBADCHAN", "local_badchan", 2, 0 }, + { "OPER_SET", "set", 2, 0 }, + { "OPER_WIDE_GLINE", "wide_gline", 2, 0 }, + /* remapped features affecting only local opers */ + { "LOCOP_KILL", "kill", 1, 0 }, + { "LOCOP_REHASH", "rehash", 1, 0 }, + { "LOCOP_RESTART", "restart", 1, 0 }, + { "LOCOP_DIE", "die", 1, 0 }, + { "LOCOP_LGLINE", "local_gline", 1, 0 }, + { "LOCOP_LJUPE", "local_jupe", 1, 0 }, + { "LOCOP_LOPMODE", "local_opmode", 1, 0 }, + { "LOCOP_FORCE_LOPMODE", "force_local_opmode", 1, 0 }, + { "LOCOP_LBADCHAN", "local_badchan", 1, 0 }, + { "LOCOP_WIDE_GLINE", "wide_gline", 1, 0 }, + { 0, 0, 0, 0 } +}; + +static void do_feature(void) +{ + struct feature *feat; + size_t ii; + + ii = strlen(fields[0]); + feat = calloc(1, sizeof(*feat) + ii); + while (ii-- > 0) + feat->name[ii] = toupper(fields[0][ii]); + feat->next = features; + features = feat; + string_get(&feat->origins, orig_line); + for (ii = 1; fields[ii] && fields[ii][0]; ++ii) + string_get(&feat->values, fields[ii]); +} + +static void finish_features(void) +{ + struct remapped_feature *rmf; + struct string_list *sl; + struct feature *feat; + size_t ii; + + fputs("Features {\n\t\"OPLEVELS\" = \"FALSE\";\n", stdout); + + for (feat = features; feat; feat = feat->next) { + /* See if the feature was remapped to an oper privilege. */ + for (rmf = remapped_features; rmf->name; rmf++) + if (0 == strcmp(feat->name, rmf->name)) + break; + if (rmf->name) { + rmf->feature = feat; + fprintf(stdout, "# Above feature mapped to an oper privilege.\n"); + continue; + } + + /* Was it removed? */ + for (ii = 0; removed_features[ii]; ++ii) + if (0 == strcmp(feat->name, removed_features[ii])) + break; + if (removed_features[ii]) { + fprintf(stdout, "# Above feature no longer exists.\n"); + continue; + } + + /* Wasn't remapped, wasn't removed: print it out. */ + fprintf(stdout, "\t\"%s\" =", feat->name); + for (sl = feat->values; sl; sl = sl->next) + fprintf(stdout, " \"%s\"", sl->value); + fprintf(stdout, ";\n"); + } + fputs("};\n\n", stdout); + +} + +/*** OPERATOR BLOCKS ***/ + +struct operator { + char *name; + char *host; + char *password; + char *class; + char *origin; + int is_local; + struct operator *next; +} *operators; + +static void do_operator(int is_local) +{ + struct operator *oper; + + oper = calloc(1, sizeof(*oper)); + dupstring(oper->host, fields[0]); + dupstring(oper->password, fields[1]); + dupstring(oper->name, fields[2]); + dupstring(oper->class, fields[4]); + dupstring(oper->origin, orig_line); + oper->is_local = is_local; + oper->next = operators; + operators = oper; +} + +static void finish_operators(void) +{ + struct remapped_feature *remap; + struct operator *oper; + struct feature *feat; + char *pw_salt = ""; + int global_kill = 0, mask = 0; + size_t ii; + + if ((feat = remapped_features[0].feature) && feat->values + && 0 == strcmp(feat->values->value, "FALSE")) + pw_salt = "$PLAIN$"; + + if ((feat = remapped_features[1].feature) && feat->values + && 0 == strcmp(feat->values->value, "FALSE")) + global_kill = 1; + else if ((feat = remapped_features[2].feature) && feat->values + && 0 == strcmp(feat->values->value, "FALSE")) + global_kill = 2; + + for (oper = operators; oper; oper = oper->next) { + fprintf(stdout, "# %s\nOperator {\n\tname = \"%s\";\n" + "\thost = \"%s\";\n\tpassword = \"%s%s\";\n" + "\tclass = \"%s\";\n", + oper->origin, oper->name, oper->host, pw_salt, + oper->password, oper->class); + if (oper->is_local) { + fputs("\tlocal = yes;\n", stdout); + mask = 1; + } else { + fputs("\tlocal = no;\n", stdout); + if (global_kill == 1) + fputs("\tkill = no;\n\tlocal_kill = no;\n", stdout); + else if (global_kill == 2) + fputs("\tkill = no;\n\tlocal_kill = yes;\n", stdout); + mask = 2; + } + for (ii = 0; (remap = &remapped_features[ii++])->name; ) { + if (!remap->feature || !remap->privilege + || !remap->feature->values || !remap->flags & mask) + continue; + fprintf(stdout, "\t%s = %s;\n", remap->privilege, + strcmp(remap->feature->values->value, "TRUE") ? "no" : "yes"); + } + fputs("};\n\n", stdout); + } +} + +/*** OTHER CONFIG TRANSFORMS ***/ + +static void do_kill(void) +{ + const char *host = fields[0], *reason = fields[1], *user = fields[2]; + + if (!memcmp(host, "$R", 3)) { + fprintf(stderr, "Empty realname K: line at line %u.\n", lineno); + return; + } + + /* Print the current line and start the new block. */ + fprintf(stdout, "# %s\nKill {\n", orig_line); + + /* Translate the user-matching portions. */ + if (host[0] == '$' && host[1] == 'R') { + /* Realname kill, possibly with a username */ + fprintf(stdout, "\trealname = \"%s\";\n", host + 2); + if (user[0] != '\0' && (user[0] != '*' || user[1] != '\0')) + fprintf(stdout, "\thost = \"%s@*\";\n", user); + } else { + /* Normal host or IP-based kill */ + if (user[0] != '\0' && (user[0] != '*' || user[1] != '\0')) + fprintf(stdout, "\thost = \"%s@%s\";\n", user, host); + else + fprintf(stdout, "\thost = \"%s\";\n", host); + } + + /* Translate the reason section. */ + if (reason[0] == '!') + fprintf(stdout, "\tfile = \... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-10-25 09:47:45
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-25 09:47:39 UTC Modified files: TODO.es Log message: Mas todo ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.30 ircd-ircdev/TODO.es:1.31 --- ircd-ircdev/TODO.es:1.30 Thu Oct 13 03:01:58 2005 +++ ircd-ircdev/TODO.es Tue Oct 25 02:47:29 2005 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.30 2005/10/13 10:01:58 zolty Exp $ +# $Id: TODO.es,v 1.31 2005/10/25 09:47:29 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -26,6 +26,7 @@ notices de auth y dnslookup al conectar. - [D] U-lines a traves de la DDB. - [D] Mejorar la inicializacion de las DDB con los eventos. + - [G] Con la introduccion de &his, comprobar TODO. PRIORIDAD MEDIA @@ -73,6 +74,16 @@ [18:11:38] <Tor> quote opmode #opers +nk lalala [18:14:59] <Tor> burst de aways +[16:01:38] <Daijo> -mcpu=k8 -pipe -fomit-frame-pointer -mfpmath=sse +[16:01:45] <Daijo> -Os -mcpu=k8 -pipe -fomit-frame-pointer -mfpmath=sse +[16:01:48] <Daijo> con eso no veas como ganaria +[16:03:28] <Daijo> -O2 -march=i586 -pipe -fomit-frame-pointer +[16:03:30] <Daijo> eso es generico +[16:03:44] <Daijo> el omit-frame-pointer no es nada recomendado para depuracion +[16:04:23] <Daijo> y mi linea primera hace que compile para un binario menor (lo cual va de cabeza a la cache del +procesador), optimizando para 64 bits, y utilizando sse como funciones de coma flotante +[16:04:35] <Daijo> el -pipe hace que compile en memoria xa tardar menos + DOCUMENTACION PENDIENTE -------------------------------------------------------------------------------------- - [G] Documentar para Doxygen el Watch ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-10-25 09:53:03
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-25 09:52:53 UTC Modified files: ChangeLog ChangeLog.es RELEASE.NOTES RELEASE.NOTES.es doc/en/features.txt include/channel.h include/class.h include/ircd_features.h include/patchlevel.h include/s_stats.h include/s_user.h ircd/Makefile.in ircd/channel.c ircd/class.c ircd/client.c ircd/gline.c ircd/ircd.c ircd/ircd_features.c ircd/ircd_parser.y ircd/ircd_res.c ircd/m_burst.c ircd/m_clearmode.c ircd/m_create.c ircd/m_defaults.c ircd/m_gline.c ircd/m_invite.c ircd/m_join.c ircd/m_kick.c ircd/m_kill.c ircd/m_names.c ircd/m_proto.c ircd/m_stats.c ircd/m_topic.c ircd/m_version.c ircd/m_who.c ircd/m_whois.c ircd/parse.c ircd/s_conf.c ircd/s_misc.c ircd/s_numeric.c ircd/s_stats.c ircd/s_user.c ircd/test/Makefile.in Removed files: include/supported.h include/whocmds.h ircd/whocmds.c Log message: Author: zoltan <zo...@ir...> Log message: 2005-10-25 Toni García <zo...@ir...> 1.0.alpha45 * ISSUPORT dinámico ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.46 ircd-ircdev/ChangeLog:1.47 --- ircd-ircdev/ChangeLog:1.46 Mon Oct 17 07:02:32 2005 +++ ircd-ircdev/ChangeLog Tue Oct 25 02:52:43 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.46 2005/10/17 14:02:32 zolty Exp $ +# $Id: ChangeLog,v 1.47 2005/10/25 09:52:43 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-10-25 Toni García <zo...@ir...> 1.0.alpha45 + * Dynamic ISSUPORT + 2005-10-17 Toni García <zo...@ir...> 1.0.alpha44 * Undernet synchronization Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.46 ircd-ircdev/ChangeLog.es:1.47 --- ircd-ircdev/ChangeLog.es:1.46 Mon Oct 17 07:02:32 2005 +++ ircd-ircdev/ChangeLog.es Tue Oct 25 02:52:43 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.46 2005/10/17 14:02:32 zolty Exp $ +# $Id: ChangeLog.es,v 1.47 2005/10/25 09:52:43 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-10-25 Toni García <zo...@ir...> 1.0.alpha45 + * ISSUPORT dinámico + 2005-10-17 Toni García <zo...@ir...> 1.0.alpha44 * Sincronización Undernet Index: ircd-ircdev/RELEASE.NOTES diff -u ircd-ircdev/RELEASE.NOTES:1.3 ircd-ircdev/RELEASE.NOTES:1.4 --- ircd-ircdev/RELEASE.NOTES:1.3 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/RELEASE.NOTES Tue Oct 25 02:52:43 2005 @@ -1,5 +1,5 @@ Release notes for IRC-Dev IRCD version 1.0 -Last updated: 23 Apr 2005 +Last updated: 25 October 2005 Written by Toni Garcia <zo...@ir...> Based on earlier documents by Kev <kl...@mi...>, Braden <db...@ya...> and Michael Poole <md...@tr...> @@ -11,6 +11,16 @@ IPv6 support and oplevels) are not supported by old ircds. +Semantic Changes (TAKE NOTE): + +Channel keys and passwords (see the "oplevels" enhancement below) +listed in a JOIN are now only checked against the corresponding +channel. In an old ircd, "JOIN #a,#b key" would attempt to use "key" +as the key for both #a and #b. IRC-Dev IRCD will only attempt to use +it as the key for #a. IRC-Dev IRCD's behavior matches that documented +in RFC 1459. + + Enhancements: The configuration file format has changed to one that is easier to @@ -78,6 +88,11 @@ The server will no longer kick "net riders" in keyed (+k) channels if both sides of the net join have the same key. +IP masks (as used in bans, G-lines, etc) are now parsed in a more +forgiving manner. 127.0.0.0/8, 127.* and 127/8 are all accepted and +mean the same thing. Ambiguous expressions like 127/8 are interpreted +as IPv4 masks; to interpret it as an IPv6 mask, use 127:/8. + GLINE has been extended to allow IRC operators to issue global G-lines; see doc/en/gline.txt for more information about how to use this feature. @@ -175,6 +190,11 @@ when you join using those keys. Part of this channel protection is that you cannot be deopped in channel by someone who you opped. +IP masks (as used in bans, G-lines, etc) are now parsed in a more +forgiving manner. 127.0.0.0/8, 127.* and 127/8 are all accepted and +mean the same thing. Ambiguous expressions like 127/8 are interpreted +as IPv4 masks; to interpret it as an IPv6 mask, use 127:/8. + Configuration Changes: Index: ircd-ircdev/RELEASE.NOTES.es diff -u ircd-ircdev/RELEASE.NOTES.es:1.3 ircd-ircdev/RELEASE.NOTES.es:1.4 --- ircd-ircdev/RELEASE.NOTES.es:1.3 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/RELEASE.NOTES.es Tue Oct 25 02:52:43 2005 @@ -1,5 +1,5 @@ Notas de lanzamiento para IRCD de IRC-Dev version 1.0 -Ultima actualización: 23 Abril 2005 +Ultima actualización: 25 Octubre 2005 Escrito y traducido por Toni Garcia <zo...@ir...> Basado en anteriores documentos por Kev <kl...@mi...>, Braden <db...@ya...> y Michael Poole <md...@tr...> @@ -12,6 +12,17 @@ IPv6 y oplevels) no están soportadas por ircds viejos. +Cambios semántico (NOTA): + +Las contraseñas de canales (vease la implementación de "oplevels" +abajo) eumeradas en un JOIN ahora se comprueban solamente al canal +correspondiente. En un ircd viejo, "JOIN #a,#b key" procuraría +utilizar la "key" como la contraseña para ambos canales #a y #b. +El IRCD de IRC-Dev procurará utilizar solamente para la contraseña +del canal #a. El comportamiento del IRCD de IRC-Dev está documentado +en el RFC 1459. + + Implementaciones: El formato del archivo de la configuración ha cambiado a uno que es @@ -83,6 +94,11 @@ El servidor no puede kickear por "net riders" en los canales con llave (+k) si ambos lados de la red al unirse tienen la misma llave. +Las máscaras de IP (utilizadas en bans, G-lines, etc) ahora se analizan +de una manera más extensa. 127.0.0.0/8, 127.* y 127/8 son todos aceptadas +y significan la misma cosa. Expresiones ambiguas como 127/8 son interpretadas +como máscaras de IPv4, para interpretarlo como una máscara IPv6 use 127:/8. + GLINE se ha ampliado para permitir a los Operadores de IRC (IRCops) publicar G-lines globales; vea doc/es/gline.txt para más información sobre cómo utilizar esta característica. Index: ircd-ircdev/doc/en/features.txt diff -u ircd-ircdev/doc/en/features.txt:1.3 ircd-ircdev/doc/en/features.txt:1.4 --- ircd-ircdev/doc/en/features.txt:1.3 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/doc/en/features.txt Tue Oct 25 02:52:43 2005 @@ -1,4 +1,4 @@ -$Id: features.txt,v 1.3 2005/09/01 11:25:42 zolty Exp $ +$Id: features.txt,v 1.4 2005/10/25 09:52:43 zolty Exp $ Many of the old compile-time options are now configured through the server configuration file, ircd.conf. This file is intended to @@ -351,6 +351,12 @@ larger than the CHANNELLEN #define. Like the NICKLEN feature, this is intended to ease changes in channel name length across a network. +USER_GLIST +* Type: boolean +* Default: FALSE + +Optionally removes the ability to list glines by users +(ie /GLINE id...@ho..., shows reason, expiry time etc) AVBANLEN * Type: integer Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.14 ircd-ircdev/include/channel.h:1.15 --- ircd-ircdev/include/channel.h:1.14 Mon Oct 17 07:02:32 2005 +++ ircd-ircdev/include/channel.h Tue Oct 25 02:52:43 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Channel management and maintenance. - * @version $Id: channel.h,v 1.14 2005/10/17 14:02:32 zolty Exp $ + * @version $Id: channel.h,v 1.15 2005/10/25 09:52:43 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -376,6 +376,9 @@ char *mbma_string; /**< A string */ struct Client *mbma_client; /**< A client */ } mbm_arg; /**< The mode argument */ +#if defined(UNDERNET) + unsigned short mbm_oplevel; /**< Oplevel for a bounce */ +#endif } mb_modeargs[MAXMODEPARAMS]; /**< A mode w/args */ }; @@ -401,6 +404,9 @@ #define MB_UINT(mb, i) ((mb)->mb_modeargs[(i)].mbm_arg.mbma_uint) #define MB_STRING(mb, i) ((mb)->mb_modeargs[(i)].mbm_arg.mbma_string) #define MB_CLIENT(mb, i) ((mb)->mb_modeargs[(i)].mbm_arg.mbma_client) +#if defined(UNDERNET) +#define MB_OPLEVEL(mb, i) ((mb)->mb_modeargs[(i)].mbm_oplevel) +#endif /** A buffer represeting a list of joins to send */ struct JoinBuf { @@ -486,7 +492,7 @@ extern void modebuf_mode_string(struct ModeBuf *mbuf, unsigned int mode, char *string, int free); extern void modebuf_mode_client(struct ModeBuf *mbuf, unsigned int mode, - struct Client *client); + struct Client *client, int oplevel); extern int modebuf_flush(struct ModeBuf *mbuf); extern void modebuf_extract(struct ModeBuf *mbuf, char *buf); Index: ircd-ircdev/include/class.h diff -u ircd-ircdev/include/class.h:1.7 ircd-ircdev/include/class.h:1.8 --- ircd-ircdev/include/class.h:1.7 Wed Jun 22 00:54:29 2005 +++ ircd-ircdev/include/class.h Tue Oct 25 02:52:43 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Declarations and interfaces for handling connection classes. - * @version $Id: class.h,v 1.7 2005/06/22 07:54:29 zolty Exp $ + * @version $Id: class.h,v 1.8 2005/10/25 09:52:43 zolty Exp $ */ #ifndef INCLUDED_class_h #define INCLUDED_class_h @@ -89,6 +89,8 @@ #define ConfLinks(x) ((x)->conn_class->ref_count) /** Get default usermode for ConfItem \a x. */ #define ConfUmode(x) ((x)->conn_class->default_umode) +/** Find a valid configuration class by name. */ +#define find_class(name) do_find_class((name), 0) /* * Proto types @@ -100,7 +102,7 @@ extern void class_mark_delete(void); extern void class_delete_marked(void); -extern struct ConnectionClass *find_class(const char *name); +extern struct ConnectionClass *do_find_class(const char *name, int extras); extern struct ConnectionClass *make_class(void); extern void free_class(struct ConnectionClass * tmp); extern char *get_conf_class(const struct ConfItem *aconf); Index: ircd-ircdev/include/ircd_features.h diff -u ircd-ircdev/include/ircd_features.h:1.13 ircd-ircdev/include/ircd_features.h:1.14 --- ircd-ircdev/include/ircd_features.h:1.13 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/include/ircd_features.h Tue Oct 25 02:52:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Public interfaces and declarations for dealing with configurable features. - * @version $Id: ircd_features.h,v 1.13 2005/09/01 11:25:42 zolty Exp $ + * @version $Id: ircd_features.h,v 1.14 2005/10/25 09:52:43 zolty Exp $ */ #ifndef INCLUDED_features_h #define INCLUDED_features_h @@ -58,11 +58,10 @@ FEAT_HIDDEN_HOST, FEAT_HIDDEN_IP, FEAT_CONNEXIT_NOTICES, -#if defined(UNDERNET) FEAT_OPLEVELS, -#endif FEAT_LOCAL_CHANNELS, FEAT_TOPIC_BURST, + FEAT_USER_GLIST, /* features that probably should not be touched */ FEAT_KILLCHASETIMELIMIT, Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.45 ircd-ircdev/include/patchlevel.h:1.46 --- ircd-ircdev/include/patchlevel.h:1.45 Mon Oct 17 07:02:32 2005 +++ ircd-ircdev/include/patchlevel.h Tue Oct 25 02:52:43 2005 @@ -17,12 +17,12 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.45 2005/10/17 14:02:32 zolty Exp $ + * $Id: patchlevel.h,v 1.46 2005/10/25 09:52:43 zolty Exp $ * */ -#define PATCHLEVEL ".alpha44" +#define PATCHLEVEL "45" -#define RELEASE "1.0" +#define RELEASE "1.0.alpha" /* * Deliberate empty lines Index: ircd-ircdev/include/s_stats.h diff -u ircd-ircdev/include/s_stats.h:1.4 ircd-ircdev/include/s_stats.h:1.5 --- ircd-ircdev/include/s_stats.h:1.4 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/s_stats.h Tue Oct 25 02:52:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Report configuration lines and other statistics from this server. - * @version $Id: s_stats.h,v 1.4 2005/01/10 12:22:00 zolty Exp $ + * @version $Id: s_stats.h,v 1.5 2005/10/25 09:52:43 zolty Exp $ */ #ifndef INCLUDED_s_stats_h #define INCLUDED_s_stats_h @@ -55,8 +55,9 @@ #define STAT_FLAG_OPERONLY 0x01 /**< Oper-only stat */ #define STAT_FLAG_OPERFEAT 0x02 /**< Oper-only if the feature is true */ -#define STAT_FLAG_CASESENS 0x04 /**< Flag is case-sensitive */ -#define STAT_FLAG_VARPARAM 0x08 /**< May have an extra parameter */ +#define STAT_FLAG_LOCONLY 0x04 /**< Local user only */ +#define STAT_FLAG_CASESENS 0x08 /**< Flag is case-sensitive */ +#define STAT_FLAG_VARPARAM 0x10 /**< May have an extra parameter */ extern void stats_init(void); const struct StatDesc *stats_find(const char *name_or_char); Index: ircd-ircdev/include/s_user.h diff -u ircd-ircdev/include/s_user.h:1.8 ircd-ircdev/include/s_user.h:1.9 --- ircd-ircdev/include/s_user.h:1.8 Sun Jul 3 11:44:51 2005 +++ ircd-ircdev/include/s_user.h Tue Oct 25 02:52:43 2005 @@ -21,7 +21,7 @@ */ /** @file s_user.h * @brief Miscellaneous user-related helper functions. - * @version $Id: s_user.h,v 1.8 2005/07/03 18:44:51 zolty Exp $ + * @version $Id: s_user.h,v 1.9 2005/10/25 09:52:43 zolty Exp $ */ #ifndef INCLUDED_s_user_h #define INCLUDED_s_user_h @@ -146,6 +146,12 @@ extern void add_target(struct Client *sptr, void *target); extern unsigned int umode_make_snomask(unsigned int oldmask, char *arg, int what); + +extern void init_isupport(void); +extern void add_isupport(const char *name); +extern void add_isupport_i(const char *name, int value); +extern void add_isupport_s(const char *name, const char *value); +extern void del_isupport(const char *name); extern int send_supported(struct Client *cptr); #define NAMES_ALL 1 /**< List all users in channel */ Index: ircd-ircdev/include/supported.h diff -u ircd-ircdev/include/supported.h:1.9 ircd-ircdev/include/supported.h:removed --- ircd-ircdev/include/supported.h:1.9 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/include/supported.h Tue Oct 25 02:52:53 2005 @@ -1,90 +0,0 @@ -/* - * IRC-Dev IRCD - An advanced and innovative IRC Daemon, include/supported.h - * - * Copyright (C) 2002-2005 IRC-Dev Development Team <de...@ir...> - * Copyright (C) 1999 Perry Lorier - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id: supported.h,v 1.9 2005/09/01 11:25:42 zolty Exp $ - * - */ -#ifndef INCLUDED_supported_h -#define INCLUDED_supported_h - -/* - * Description: This file has the featureset that ircu announces on connecting - * a client. It's in this .h because it's likely to be appended - * to frequently and s_user.h is included by basically everyone. - */ -#include "channel.h" -#include "ircd_defs.h" - -/* - * 'Features' supported by this ircd - */ -#define FEATURES1 \ - "AWAYLEN=%i" \ - " MAXCHANNELLEN=%i" \ - " CHANNELLEN=%i" \ - " MAXNICKLEN=%i" \ - " NICKLEN=%i" \ - " TOPICLEN=%i" - -#define FEATURES2 \ - "CHANMODES=%s" \ - " CHANTYPES=%s" \ - " PREFIX=%s" \ - " STATUSMSG=%s" \ - -#define FEATURES3 \ - "MAXCHANNELS=%i" \ - " MAXBANS=%i" \ - " MAXTARGETS=%i" \ - " MODES=%i" \ - " SILENCE=%i" \ - " WATCH=%i" - -#define FEATURES4 \ - "CNOTICE" \ - " CPRIVMSG" \ - " MAP" \ - " USERIP" \ - " WALLCHOPS" \ - " WALLVOICES" \ - " WHOX" - -#define FEATURES5 "CHARMAPPING=%s" \ - " NETWORK=%s" \ - " FNC" \ - " SAFELIST" - - -#define FEATURESVALUES1 AWAYLEN, CHANNELLEN, feature_int(FEAT_CHANNELLEN), NICKLEN, feature_int(FEAT_NICKLEN), TOPICLEN - -#if defined(DDB) || defined(SERVICES) -#define FEATURESVALUES2 "b,k,l,imnpstrRDd", feature_bool(FEAT_LOCAL_CHANNELS) ? "#&" : "#", "(qov).@+", ".@+" -#else -#define FEATURESVALUES2 "b,k,l,imnpstRDd", feature_bool(FEAT_LOCAL_CHANNELS) ? "#&" : "#", "(ov)@+", "@+" -#endif - -#define FEATURESVALUES3 feature_int(FEAT_MAXCHANNELSPERUSER), feature_int(FEAT_MAXBANS), \ - MAXTARGETS, MAXMODEPARAMS, feature_int(FEAT_MAXSILES), \ - feature_int(FEAT_MAXWATCHS) - -#define FEATURESVALUES5 "rfc1459", feature_str(FEAT_NETWORK) - - -#endif /* INCLUDED_supported_h */ Index: ircd-ircdev/include/whocmds.h diff -u ircd-ircdev/include/whocmds.h:1.5 ircd-ircdev/include/whocmds.h:removed --- ircd-ircdev/include/whocmds.h:1.5 Mon Jan 10 04:22:00 2005 +++ ircd-ircdev/include/whocmds.h Tue Oct 25 02:52:53 2005 @@ -1,114 +0,0 @@ -/* - * IRC-Dev IRCD - An advanced and innovative IRC Daemon, include/whocmds.h - * - * Copyright (C) 2002-2005 IRC-Dev Development Team <de...@ir...> - * Copyright (C) 1990 Jarkko Oikarinen - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - */ -/** @file whocmds.h - * @brief Support functions for /WHO-like commands. - * @version $Id: whocmds.h,v 1.5 2005/01/10 12:22:00 zolty Exp $ - */ -#ifndef INCLUDED_whocmds_h -#define INCLUDED_whocmds_h - -struct Client; -struct Channel; - - -/* - * m_who() - * m_who with support routines rewritten by Nemesi, August 1997 - * - Alghoritm have been flattened (no more recursive) - * - Several bug fixes - * - Strong performance improvement - * - Added possibility to have specific fields in the output - * See readme.who for further details. - */ - -/* Macros used only in here by m_who and its support functions */ - -#define WHOSELECT_OPER 1 /**< Flag for /WHO: Show IRC operators. */ -#define WHOSELECT_EXTRA 2 /**< Flag for /WHO: Pull rank to see users. */ - -#define WHO_FIELD_QTY 1 /**< Display query type. */ -#define WHO_FIELD_CHA 2 /**< Show common channel name. */ -#define WHO_FIELD_UID 4 /**< Show username. */ -#define WHO_FIELD_NIP 8 /**< Show IP address. */ -#define WHO_FIELD_HOS 16 /**< Show hostname. */ -#define WHO_FIELD_SER 32 /**< Show server. */ -#define WHO_FIELD_NIC 64 /**< Show nickname. */ -#define WHO_FIELD_FLA 128 /**< Show flags (away, oper, chanop, etc). */ -#define WHO_FIELD_DIS 256 /**< Show hop count (distance). */ -#define WHO_FIELD_REN 512 /**< Show realname (info). */ -#define WHO_FIELD_IDL 1024 /**< Show idle time. */ -#if defined(UNDERNET) -#define WHO_FIELD_ACC 2048 /**< Show account name. */ -#endif - -/** Default fields for /WHO */ -#define WHO_FIELD_DEF ( WHO_FIELD_NIC | WHO_FIELD_UID | WHO_FIELD_HOS | WHO_FIELD_SER ) - -/** Is \a ac plainly visible to \a s? - * @param[in] s Client trying to see \a ac. - * @param[in] ac Client being looked at. - */ -#define IS_VISIBLE_USER(s,ac) ((s==ac) || (!IsInvisible(ac))) - -/** Can \a s see \a ac by using the flags in \a b? - * @param[in] s Client trying to see \a ac. - * @param[in] ac Client being looked at. - * @param[in] b Bitset of extra flags (options: WHOSELECT_EXTRA). - */ -#define SEE_LUSER(s, ac, b) (IS_VISIBLE_USER(s, ac) || \ - ((b & WHOSELECT_EXTRA) && MyConnect(ac) && \ - (HasPriv((s), PRIV_SHOW_INVIS) || \ - HasPriv((s), PRIV_SHOW_ALL_INVIS)))) - -/** Can \a s see \a ac by using the flags in \a b? - * @param[in] s Client trying to see \a ac. - * @param[in] ac Client being looked at. - * @param[in] b Bitset of extra flags (options: WHOSELECT_EXTRA). - */ -#define SEE_USER(s, ac, b) (SEE_LUSER(s, ac, b) || \ - ((b & WHOSELECT_EXTRA) && \ - HasPriv((s), PRIV_SHOW_ALL_INVIS))) - -/** Should we show more clients to \a sptr? - * @param[in] sptr Client listing other users. - * @param[in,out] counter Default count for clients. - */ -#define SHOW_MORE(sptr, counter) (HasPriv(sptr, PRIV_UNLIMIT_QUERY) || (!(counter-- < 0)) ) - -/** Can \a s see \a chptr? - * @param[in] s Client trying to see \a chptr. - * @param[in] chptr Channel being looked at. - * @param[in] b Bitset of extra flags (options: WHOSELECT_EXTRA). - */ -#define SEE_CHANNEL(s, chptr, b) (!SecretChannel(chptr) || ((b & WHOSELECT_EXTRA) && HasPriv((s), PRIV_SEE_CHAN))) - -/** Maximum number of lines to send in response to a /WHOIS. */ -#define MAX_WHOIS_LINES 50 - -/* - * Prototypes - */ -extern void do_who(struct Client* sptr, struct Client* acptr, struct Channel* repchan, - int fields, char* qrt); -extern int count_users(char* mask); - -#endif /* INCLUDED_whocmds_h */ Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.28 ircd-ircdev/ircd/Makefile.in:1.29 --- ircd-ircdev/ircd/Makefile.in:1.28 Mon Oct 17 07:02:32 2005 +++ ircd-ircdev/ircd/Makefile.in Tue Oct 25 02:52:43 2005 @@ -18,7 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.28 2005/10/17 14:02:32 zolty Exp $ +# $Id: Makefile.in,v 1.29 2005/10/25 09:52:43 zolty Exp $ #### Start of system configuration section. #### @@ -236,7 +236,6 @@ uping.c \ userload.c \ watch.c \ - whocmds.c \ whowas.c \ y.tab.c @@ -403,32 +402,29 @@ # DO NOT DELETE THIS LINE (or the blank line after it) -- make depend depends on them. -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" IPcheck.o: IPcheck.c ../config.h ../include/IPcheck.h ../include/client.h \ ../include/ircd_defs.h ../include/dbuf.h ../include/msgq.h \ ../include/ircd_events.h ../include/ircd_handler.h ../include/res.h \ ../include/capab.h ../include/ircd.h ../include/struct.h \ - ../include/match.h ../include/msg.h ../include/numnicks.h \ - ../include/ircd_alloc.h ../include/ircd_events.h \ - ../include/ircd_features.h ../include/ircd_log.h ../include/s_debug.h \ - ../include/s_user.h ../include/send.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" + ../include/match.h ../include/msg.h ../include/ircd_alloc.h \ + ../include/ircd_events.h ../include/ircd_features.h \ + ../include/ircd_log.h ../include/ircd_string.h ../include/ircd_chattr.h \ + ../include/s_debug.h ../include/s_user.h ../include/send.h channel.o: channel.c ../config.h ../include/channel.h \ ../include/ircd_defs.h ../include/res.h ../include/client.h \ ../include/dbuf.h ../include/msgq.h ../include/ircd_events.h \ - ../include/ircd_handler.h ../include/capab.h \ - ../include/destruct_event.h ../include/hash.h ../include/ircd.h \ - ../include/struct.h ../include/ircd_alloc.h ../include/ircd_chattr.h \ - ../include/ircd_defs.h ../include/ircd_features.h ../include/ircd_log.h \ + ../include/ircd_handler.h ../include/capab.h ../include/ddb.h \ + ../config.h ../include/client.h ../include/destruct_event.h \ + ../include/hash.h ../include/ircd.h ../include/struct.h \ + ../include/ircd_alloc.h ../include/ircd_chattr.h ../include/ircd_defs.h \ + ../include/ircd_features.h ../include/ircd_log.h \ ../include/ircd_reply.h ../include/ircd_snprintf.h \ ../include/ircd_string.h ../include/list.h ../include/match.h \ ../include/msg.h ../include/msgq.h ../include/numeric.h \ ../include/numnicks.h ../include/querycmds.h ../include/ircd_features.h \ - ../include/s_bsd.h ../include/s_conf.h ../include/client.h \ - ../include/s_debug.h ../include/s_misc.h ../include/s_user.h \ - ../include/send.h ../include/struct.h ../include/sys.h \ - ../include/whowas.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" + ../include/s_bsd.h ../include/s_conf.h ../include/s_debug.h \ + ../include/s_misc.h ../include/s_user.h ../include/send.h \ + ../include/struct.h ../include/sys.h ../include/whowas.h class.o: class.c ../config.h ../include/class.h ../include/client.h \ ../include/ircd_defs.h ../include/dbuf.h ../include/msgq.h \ ../include/ircd_events.h ../include/ircd_handler.h ../include/res.h \ @@ -437,7 +433,6 @@ ../include/ircd_log.h ../include/ircd_reply.h ../include/ircd_string.h \ ../include/ircd_chattr.h ../include/list.h ../include/numeric.h \ ../include/s_conf.h ../include/s_debug.h ../include/send.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" client.o: client.c ../config.h ../include/client.h ../include/ircd_defs.h \ ../include/dbuf.h ../include/msgq.h ../include/ircd_events.h \ ../include/ircd_handler.h ../include/res.h ../include/capab.h \ @@ -446,7 +441,6 @@ ../include/ircd_reply.h ../include/list.h ../include/msgq.h \ ../include/numeric.h ../include/s_conf.h ../include/s_debug.h \ ../include/send.h ../include/struct.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" crule.o: crule.c ../config.h ../include/crule.h ../include/client.h \ ../include/ircd_defs.h ../include/dbuf.h ../include/msgq.h \ ../include/ircd_events.h ../include/ircd_handler.h ../include/res.h \ @@ -454,20 +448,16 @@ ../include/ircd_alloc.h ../include/ircd_chattr.h \ ../include/ircd_string.h ../include/match.h ../include/s_bsd.h \ ../include/s_debug.h ../include/struct.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" dbuf.o: dbuf.c ../config.h ../include/dbuf.h ../include/ircd_alloc.h \ ../include/ircd_chattr.h ../include/ircd_features.h \ ../include/ircd_log.h ../include/send.h ../include/sys.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" destruct_event.o: destruct_event.c ../config.h ../include/channel.h \ ../include/ircd_defs.h ../include/res.h ../include/s_debug.h \ ../include/ircd_alloc.h ../include/ircd.h ../include/struct.h \ ../include/ircd_events.h ../include/ircd_log.h ../include/send.h \ ../include/msg.h ../include/ircd_handler.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" fileio.o: fileio.c ../config.h ../include/fileio.h \ ../include/ircd_alloc.h ../include/ircd_log.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" gline.o: gline.c ../config.h ../include/gline.h ../include/res.h \ ../include/client.h ../include/ircd_defs.h ../include/dbuf.h \ ../include/msgq.h ../include/ircd_events.h ../include/ircd_handler.h \ @@ -478,18 +468,17 @@ ../include/ircd_chattr.h ../include/match.h ../include/numeric.h \ ../include/s_bsd.h ../include/s_debug.h ../include/s_misc.h \ ../include/s_stats.h ../include/send.h ../include/struct.h \ - ../include/msg.h ../include/numnicks.h ../include/whocmds.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" + ../include/msg.h ../include/numnicks.h hash.o: hash.c ../config.h ../include/hash.h ../include/client.h \ ../include/ircd_defs.h ../include/dbuf.h ../include/msgq.h \ ../include/ircd_events.h ../include/ircd_handler.h ../include/res.h \ ../include/capab.h ../include/channel.h ../include/ddb.h ../config.h \ ../include/client.h ../include/ircd_alloc.h ../include/ircd_chattr.h \ ../include/ircd_log.h ../include/ircd_reply.h ../include/ircd_string.h \ - ../include/ircd.h ../include/struct.h ../include/msg.h \ - ../include/numeric.h ../include/random.h ../include/send.h \ - ../include/struct.h ../include/sys.h ../include/watch.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" + ../include/ircd.h ../include/struct.h ../include/match.h \ + ../include/msg.h ../include/numeric.h ../include/random.h \ + ../include/send.h ../include/struct.h ../include/sys.h \ + ../include/watch.h ircd.o: ircd.c ../config.h ../include/ircd.h ../include/struct.h \ ../include/ircd_defs.h ../include/IPcheck.h ../include/class.h \ ../include/client.h ../include/dbuf.h ../include/msgq.h \ @@ -508,11 +497,9 @@ ../include/s_misc.h ../include/s_stats.h ../include/send.h \ ../include/sys.h ../include/uping.h ../include/userload.h \ ../include/version.h ../include/whowas.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" ircd_alloc.o: ircd_alloc.c ../config.h ../include/ircd_alloc.h \ ../include/ircd_log.h ../include/ircd_string.h ../include/ircd_chattr.h \ ../include/s_debug.h ../include/ircd_defs.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" ircd_auth.o: ircd_auth.c ../config.h ../include/client.h \ ../include/ircd_defs.h ../include/dbuf.h ../include/msgq.h \ ../include/ircd_events.h ../include/ircd_handler.h ../include/res.h \ @@ -524,19 +511,16 @@ ../include/msg.h ../include/msgq.h ../include/res.h ../include/s_bsd.h \ ../include/s_debug.h ../include/s_misc.h ../include/s_user.h \ ../include/send.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" ircd_crypt.o: ircd_crypt.c ../config.h ../include/ircd_crypt.h \ ../include/ircd_alloc.h ../include/ircd_features.h \ ../include/ircd_log.h ../include/ircd_string.h ../include/ircd_chattr.h \ ../include/s_debug.h ../include/ircd_defs.h \ ../include/ircd_crypt_native.h ../include/ircd_crypt_plain.h \ ../include/ircd_crypt_smd5.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" ircd_events.o: ircd_events.c ../config.h ../include/ircd_events.h \ ../include/ircd.h ../include/struct.h ../include/ircd_defs.h \ ../include/ircd_alloc.h ../include/ircd_log.h \ ../include/ircd_snprintf.h ../include/s_debug.h -# 1 "/usr/home/zoltan/ircd-ircdev/ircd//" ircd_features.o: ircd_features.c ../config.h ../include/ircd_features.h \ ../include/channel.h ../include/ircd_defs.h ../include/res.h \ ../include/cl... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-10-25 11:27:29
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-25 11:27:21 UTC Modified files: ircd/test/Makefile.in Log message: Prueba ---------------------- diff included ---------------------- Index: ircd-ircdev/ircd/test/Makefile.in diff -u ircd-ircdev/ircd/test/Makefile.in:1.6 ircd-ircdev/ircd/test/Makefile.in:1.7 --- ircd-ircdev/ircd/test/Makefile.in:1.6 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ircd/test/Makefile.in Tue Oct 25 04:27:10 2005 @@ -18,13 +18,14 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.6 2005/10/25 09:52:43 zolty Exp $ +# $Id: Makefile.in,v 1.7 2005/10/25 11:27:10 zolty Exp $ top_srcdir = @top_srcdir@ srcdir = @srcdir@ VPATH = @srcdir@ CPPFLAGS = -I${top_srcdir}/include -I../.. CFLAGS = -g -Wall +LDFLAGS = CC = @CC@ TESTPROGS = \ ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-10-26 14:55:38
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-26 14:55:18 UTC Modified files: ChangeLog ChangeLog.es Makefile.in include/capab.h include/dbuf.h include/hash.h include/ircd_features.h include/msg.h include/numeric.h include/patchlevel.h include/s_conf.h include/s_user.h ircd/IPcheck.c ircd/Makefile.in ircd/channel.c ircd/class.c ircd/gline.c ircd/hash.c ircd/ircd.c ircd/ircd_alloc.c ircd/ircd_auth.c ircd/ircd_crypt.c ircd/ircd_crypt_smd5.c ircd/ircd_events.c ircd/ircd_features.c ircd/ircd_log.c ircd/ircd_parser.y ircd/ircd_relay.c ircd/ircd_res.c ircd/ircd_string.c ircd/jupe.c ircd/list.c ircd/m_burst.c ircd/m_cap.c ircd/m_clearmode.c ircd/m_connect.c ircd/m_create.c ircd/m_destruct.c ircd/m_join.c ircd/m_kick.c ircd/m_kill.c ircd/m_list.c ircd/m_mode.c ircd/m_nick.c ircd/m_oper.c ircd/m_privs.c ircd/m_quit.c ircd/m_settime.c ircd/m_stats.c ircd/m_time.c ircd/m_topic.c ircd/m_trace.c ircd/m_userhost.c ircd/m_userip.c ircd/m_version.c ircd/m_who.c ircd/m_whois.c ircd/m_whowas.c ircd/match.c ircd/msgq.c ircd/numnicks.c ircd/packet.c ircd/parse.c ircd/s_auth.c ircd/s_conf.c ircd/s_debug.c ircd/s_err.c ircd/s_misc.c ircd/s_numeric.c ircd/s_serv.c ircd/s_stats.c ircd/s_user.c ircd/send.c ircd/umkpasswd.c ircd/test/ircd_chattr_t.c ircd/test/ircd_in_addr_t.c tools/Bounce/Bounce.cpp tools/Bounce/Bounce.h tools/convert-conf.py tools/hashtoy tools/untabify tools/linesync/linesync.sh Log message: Author: zoltan <zo...@ir...> Log message: 2005-10-26 Toni García <zo...@ir...> 1.0.alpha46 * Limpieza de código ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.47 ircd-ircdev/ChangeLog:1.48 --- ircd-ircdev/ChangeLog:1.47 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ChangeLog Wed Oct 26 07:54:43 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.47 2005/10/25 09:52:43 zolty Exp $ +# $Id: ChangeLog,v 1.48 2005/10/26 14:54:43 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-10-26 Toni García <zo...@ir...> 1.0.alpha46 + * Cleanup code + 2005-10-25 Toni García <zo...@ir...> 1.0.alpha45 * Dynamic ISSUPORT Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.47 ircd-ircdev/ChangeLog.es:1.48 --- ircd-ircdev/ChangeLog.es:1.47 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ChangeLog.es Wed Oct 26 07:54:43 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.47 2005/10/25 09:52:43 zolty Exp $ +# $Id: ChangeLog.es,v 1.48 2005/10/26 14:54:43 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-10-26 Toni García <zo...@ir...> 1.0.alpha46 + * Limpieza de código + 2005-10-25 Toni García <zo...@ir...> 1.0.alpha45 * ISSUPORT dinámico Index: ircd-ircdev/Makefile.in diff -u ircd-ircdev/Makefile.in:1.8 ircd-ircdev/Makefile.in:1.9 --- ircd-ircdev/Makefile.in:1.8 Tue Feb 15 08:31:49 2005 +++ ircd-ircdev/Makefile.in Wed Oct 26 07:54:43 2005 @@ -151,7 +151,7 @@ # Indent all headers and source files: indent: @test "`indent --version`" = "GNU indent 2.2.8" || \ - (echo "You need GNU indent 2.2.8; See doc/<language>/readme.indent" && exit -1); + (echo "You need GNU indent 2.2.8; See doc/<language>/indent.txt" && exit -1); VERSION_CONTROL=none indent include/*.h ircd/*.c # do a cvs update Index: ircd-ircdev/include/capab.h diff -u ircd-ircdev/include/capab.h:1.3 ircd-ircdev/include/capab.h:1.4 --- ircd-ircdev/include/capab.h:1.3 Mon Apr 11 01:44:59 2005 +++ ircd-ircdev/include/capab.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Interface and public definitions for capabilities extension - * @version $Id: capab.h,v 1.3 2005/04/11 08:44:59 zolty Exp $ + * @version $Id: capab.h,v 1.4 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_capab_h #define INCLUDED_capab_h @@ -35,11 +35,7 @@ #define CAPFL_PROTO 0x0004 /**< Cap must be acknowledged by client */ #define CAPFL_STICKY 0x0008 /**< Cap may not be cleared once set */ - -/* XXX You can safely ignore all of these; they're only for testing purposes, - * XXX and don't result in any behavioral change. - */ -#define CAPLIST \ +#define CAPLIST \ _CAP(USERPFX, 0, "undernet.org/userpfx") /** Client capabilities */ Index: ircd-ircdev/include/dbuf.h diff -u ircd-ircdev/include/dbuf.h:1.4 ircd-ircdev/include/dbuf.h:1.5 --- ircd-ircdev/include/dbuf.h:1.4 Mon Jan 10 04:21:59 2005 +++ ircd-ircdev/include/dbuf.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Interfaces and declarations for dealing with data buffers. - * @version $Id: dbuf.h,v 1.4 2005/01/10 12:21:59 zolty Exp $ + * @version $Id: dbuf.h,v 1.5 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_dbuf_h #define INCLUDED_dbuf_h @@ -62,4 +62,5 @@ extern unsigned int dbuf_getmsg(struct DBuf *dyn, char *buf, unsigned int length); extern void dbuf_count_memory(size_t *allocated, size_t *used); + #endif /* INCLUDED_dbuf_h */ Index: ircd-ircdev/include/hash.h diff -u ircd-ircdev/include/hash.h:1.7 ircd-ircdev/include/hash.h:1.8 --- ircd-ircdev/include/hash.h:1.7 Sat Apr 2 11:47:34 2005 +++ ircd-ircdev/include/hash.h Wed Oct 26 07:54:43 2005 @@ -22,7 +22,7 @@ */ /** @file * @brief Hash table management APIs. - * @version $Id: hash.h,v 1.7 2005/04/02 19:47:34 zolty Exp $ + * @version $Id: hash.h,v 1.8 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_hash_h #define INCLUDED_hash_h @@ -100,7 +100,7 @@ extern int addNickJupes(const char *nicks); extern void clearNickJupes(void); extern void stats_nickjupes(struct Client* to, const struct StatDesc* sd, - char* param); + char* param); extern void list_next_channels(struct Client *cptr); #endif /* INCLUDED_hash_h */ Index: ircd-ircdev/include/ircd_features.h diff -u ircd-ircdev/include/ircd_features.h:1.14 ircd-ircdev/include/ircd_features.h:1.15 --- ircd-ircdev/include/ircd_features.h:1.14 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/include/ircd_features.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Public interfaces and declarations for dealing with configurable features. - * @version $Id: ircd_features.h,v 1.14 2005/10/25 09:52:43 zolty Exp $ + * @version $Id: ircd_features.h,v 1.15 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_features_h #define INCLUDED_features_h @@ -67,7 +67,6 @@ FEAT_KILLCHASETIMELIMIT, FEAT_MAXCHANNELSPERUSER, FEAT_NICKLEN, - FEAT_AVBANLEN, FEAT_MAXBANS, FEAT_MAXSILES, @@ -124,7 +123,6 @@ FEAT_HIS_STATS_e, FEAT_HIS_STATS_f, FEAT_HIS_STATS_g, - FEAT_HIS_STATS_h, FEAT_HIS_STATS_i, FEAT_HIS_STATS_j, FEAT_HIS_STATS_J, Index: ircd-ircdev/include/msg.h diff -u ircd-ircdev/include/msg.h:1.13 ircd-ircdev/include/msg.h:1.14 --- ircd-ircdev/include/msg.h:1.13 Wed May 25 09:56:23 2005 +++ ircd-ircdev/include/msg.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Command and token declarations and structures. - * @version $Id: msg.h,v 1.13 2005/05/25 16:56:23 zolty Exp $ + * @version $Id: msg.h,v 1.14 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_msg_h #define INCLUDED_msg_h @@ -343,9 +343,9 @@ #define TOK_ACCOUNT "AC" #define CMD_ACCOUNT MSG_ACCOUNT, TOK_ACCOUNT -#define MSG_ASLL "ASLL" /* ASLL */ -#define TOK_ASLL "LL" -#define CMD_ASLL MSG_ASLL, TOK_ASLL +#define MSG_ASLL "ASLL" /* ASLL */ +#define TOK_ASLL "LL" +#define CMD_ASLL MSG_ASLL, TOK_ASLL #define MSG_POST "POST" /* POST */ #define TOK_POST "POST" Index: ircd-ircdev/include/numeric.h diff -u ircd-ircdev/include/numeric.h:1.15 ircd-ircdev/include/numeric.h:1.16 --- ircd-ircdev/include/numeric.h:1.15 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/include/numeric.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Declarations of numeric replies and supporting functions. - * @version $Id: numeric.h,v 1.15 2005/09/01 11:25:42 zolty Exp $ + * @version $Id: numeric.h,v 1.16 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_numeric_h #define INCLUDED_numeric_h @@ -66,9 +66,9 @@ #define RPL_MAP 15 /* Undernet extension */ #define RPL_MAPMORE 16 /* Undernet extension */ #define RPL_MAPEND 17 /* Undernet extension */ -#define RPL_APASSWARN_SET 30 /* Undernet extension */ -#define RPL_APASSWARN_SECRET 31 /* Undernet extension */ -#define RPL_APASSWARN_CLEAR 32 /* Undernet extension */ +#define RPL_APASSWARN_SET 30 /* Undernet extension */ +#define RPL_APASSWARN_SECRET 31 /* Undernet extension */ +#define RPL_APASSWARN_CLEAR 32 /* Undernet extension */ /* RPL_YOURID 42 IRCnet extension */ /* RPL_ATTEMPTINGJUNC 50 aircd extension */ /* RPL_ATTEMPTINGREROUTE 51 aircd extension */ @@ -106,7 +106,7 @@ /* RPL_STATSBLINE 220 Numerics List: Dalnet,unreal */ #define RPL_UMODEIS 221 /* RPL_SQLINE_NICK 222 Numerics List: Dalnet */ -#define RPL_STATSJLINE 222 /* Undernet extension */ +#define RPL_STATSJLINE 222 /* Undernet extension */ /* RPL_STATSELINE 223 dalnet */ /* RPL_STATSGLINE 223 unreal */ /* RPL_STATSFLINE 224 Hybrid extension,Dalnet */ @@ -121,12 +121,12 @@ #define RPL_STATSALINE 226 /* Hybrid, Undernet */ #define RPL_STATSQLINE 228 /* Undernet extension */ -/* RPL_SERVICEINFO 231 unused */ -/* RPL_ENDOFSERVICES 232 unused */ +/* RPL_SERVICEINFO 231 unused */ +/* RPL_ENDOFSERVICES 232 unused */ /* RPL_RULES 232 unreal */ -/* RPL_SERVICE 233 unused */ -/* RPL_SERVLIST 234 unused */ -/* RPL_SERVLISTEND 235 unused */ +/* RPL_SERVICE 233 unused */ +/* RPL_SERVLIST 234 unused */ +/* RPL_SERVLISTEND 235 unused */ #define RPL_STATSVERBOSE 236 /* Undernet verbose server list */ #define RPL_STATSENGINE 237 /* Undernet engine name */ @@ -161,7 +161,7 @@ #define RPL_ADMINLOC2 258 #define RPL_ADMINEMAIL 259 -/* RPL_TRACELOG 261 unused */ +/* RPL_TRACELOG 261 unused */ #define RPL_TRACEEND 262 /* efnet/IRCnet */ /* RPL_LOAD_THROTTLED 263 efnet/hybrid */ /* RPL_TRYAGAIN 263 Numerics List: IRCnet */ @@ -206,11 +206,11 @@ /* RPL_END_CHANINFO 299 aircd */ -/* RPL_NONE 300 unused */ +/* RPL_NONE 300 unused */ #define RPL_AWAY 301 #define RPL_USERHOST 302 #define RPL_ISON 303 -/* RPL_TEXT 304 unused */ +/* RPL_TEXT 304 unused */ #define RPL_UNAWAY 305 #define RPL_NOWAWAY 306 /* NotAway, aircd */ @@ -258,7 +258,7 @@ /* RPL_LISTSYNTAX 334 unreal */ /* RPL_CHANPASSOK 338 IRCnet extension (?)*/ #define RPL_WHOISACTUALLY 338 /* Undernet extension, dalnet */ -/* RPL_BADCHANPASS 339 IRCnet extension (?)*/ +/* RPL_BADCHANPASS 339 IRCnet extension (?) */ #define RPL_USERIP 340 /* Undernet extension */ #define RPL_INVITING 341 /* RPL_SUMMONING 342 removed from RFC1459 */ @@ -276,7 +276,7 @@ See also RPL_ENDOFWHO */ #define RPL_DELNAMREPLY 355 /* QuakeNet extension */ -/* RPL_KILLDONE 361 not used */ +/* RPL_KILLDONE 361 not used */ #define RPL_CLOSING 362 #define RPL_CLOSEEND 363 #define RPL_LINKS 364 @@ -288,7 +288,7 @@ #define RPL_INFO 371 #define RPL_MOTD 372 -#define RPL_INFOSTART 373 /* not used */ +/* RPL_INFOSTART 373 not used */ #define RPL_ENDOFINFO 374 #define RPL_MOTDSTART 375 #define RPL_ENDOFMOTD 376 @@ -303,8 +303,8 @@ #define RPL_YOUREOPER 381 #define RPL_REHASHING 382 /* RPL_YOURSERVICE 383 Numeric List: various */ -/* RPL_MYPORTIS 384 not used */ -/* RPL_NOTOPERANYMORE 385 Extension to RFC1459, not used */ +/* RPL_MYPORTIS 384 not used */ +/* RPL_NOTOPERANYMORE 385 Extension to RFC1459, not used */ /* RPL_QLIST 386 unreal */ /* RPL_ENDOFQLIST 387 unreal */ /* RPL_ALIST 388 unreal */ @@ -322,7 +322,7 @@ * Errors are in the range from 400-599 currently and are grouped by what * commands they come from. */ -/* ERR_FIRSTERROR 400 unused */ +/* ERR_FIRSTERROR 400 unused */ #define ERR_NOSUCHNICK 401 #define ERR_NOSUCHSERVER 402 #define ERR_NOSUCHCHANNEL 403 @@ -333,7 +333,6 @@ /* ERR_NOSUCHSERVICE 408 IRCnet */ /* ERR_NOCOLORSONCHAN 408 Dalnet */ #define ERR_NOORIGIN 409 - #define ERR_UNKNOWNCAPCMD 410 #define ERR_NORECIPIENT 411 #define ERR_NOTEXTTOSEND 412 @@ -455,12 +454,12 @@ #define ERR_TOOMANYUSERS 519 /* Undernet extension -Kev */ /* ERR_OPERONLY 520 unreal */ #define ERR_MASKTOOWIDE 520 /* Undernet extension -Kev */ -/* ERR_WHOTRUNC 520 austnet */ +/* ERR_WHOTRUNC 520 austnet */ #define ERR_NOSUCHGLINE 521 /* Undernet extension (new) */ /* ERR_LISTSYNTAX 521 dalnet ERR_WHOSYNTAX 522 dalnet ERR_WHOLIMEXCEED 523 dalnet */ -#define ERR_QUARANTINED 524 /* Undernet extension -Vampire */ +#define ERR_QUARANTINED 524 /* Undernet extension -Vampire */ #define ERR_NOTLOWEROPLEVEL 560 /* Undernet extension */ #define ERR_NOTMANAGER 561 /* Undernet extension */ Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.46 ircd-ircdev/include/patchlevel.h:1.47 --- ircd-ircdev/include/patchlevel.h:1.46 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/include/patchlevel.h Wed Oct 26 07:54:43 2005 @@ -17,10 +17,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.46 2005/10/25 09:52:43 zolty Exp $ + * $Id: patchlevel.h,v 1.47 2005/10/26 14:54:43 zolty Exp $ * */ -#define PATCHLEVEL "45" +#define PATCHLEVEL "46" #define RELEASE "1.0.alpha" Index: ircd-ircdev/include/s_conf.h diff -u ircd-ircdev/include/s_conf.h:1.13 ircd-ircdev/include/s_conf.h:1.14 --- ircd-ircdev/include/s_conf.h:1.13 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/include/s_conf.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file s_conf.h * @brief ircd configuration file API. - * @version $Id: s_conf.h,v 1.13 2005/09/01 11:25:42 zolty Exp $ + * @version $Id: s_conf.h,v 1.14 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_s_conf_h #define INCLUDED_s_conf_h @@ -105,7 +105,7 @@ /** Local K-line structure. */ struct DenyConf { struct DenyConf* next; /**< Next DenyConf in #denyConfList. */ - char* hostmask; /**< Mask for IP or hostname. */ + char* hostmask; /**< Mask for IP or hostname. */ char* message; /**< Message to send to denied users. */ char* usermask; /**< Mask for client's username. */ char* realmask; /**< Mask for realname. */ Index: ircd-ircdev/include/s_user.h diff -u ircd-ircdev/include/s_user.h:1.9 ircd-ircdev/include/s_user.h:1.10 --- ircd-ircdev/include/s_user.h:1.9 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/include/s_user.h Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file s_user.h * @brief Miscellaneous user-related helper functions. - * @version $Id: s_user.h,v 1.9 2005/10/25 09:52:43 zolty Exp $ + * @version $Id: s_user.h,v 1.10 2005/10/26 14:54:43 zolty Exp $ */ #ifndef INCLUDED_s_user_h #define INCLUDED_s_user_h @@ -117,7 +117,7 @@ extern int set_nick_name(struct Client* cptr, struct Client* sptr, const char* nick, int parc, char* parv[], int flags); extern void send_umode_out(struct Client* cptr, struct Client* sptr, - struct Flags* old, int prop); + struct Flags* old, int prop); extern int whisper(struct Client* source, const char* nick, const char* channel, const char* text, int is_notice); extern void send_user_info(struct Client* to, char* names, int rpl, Index: ircd-ircdev/ircd/IPcheck.c diff -u ircd-ircdev/ircd/IPcheck.c:1.12 ircd-ircdev/ircd/IPcheck.c:1.13 --- ircd-ircdev/ircd/IPcheck.c:1.12 Thu Sep 1 04:25:42 2005 +++ ircd-ircdev/ircd/IPcheck.c Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Code to count users connected from particular IP addresses. - * @version $Id: IPcheck.c,v 1.12 2005/09/01 11:25:42 zolty Exp $ + * @version $Id: IPcheck.c,v 1.13 2005/10/26 14:54:43 zolty Exp $ */ #include "config.h" @@ -284,7 +284,6 @@ } /* Note that this also counts server connects. * It is hard and not interesting, to change that. - * * Refuse connection if it would overflow the counter. */ if (0 == ++entry->connected) @@ -311,7 +310,7 @@ /* * Don't refuse connection when we just rebooted the server */ -#ifndef NOTHROTTLE +#ifndef NOTHROTTLE assert(entry->connected > 0); --entry->connected; Debug((DEBUG_DNS, "IPcheck refusing local connection from %s: too fast.", ircd_ntoa(&entry->addr))); Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.29 ircd-ircdev/ircd/Makefile.in:1.30 --- ircd-ircdev/ircd/Makefile.in:1.29 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ircd/Makefile.in Wed Oct 26 07:54:43 2005 @@ -18,7 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.29 2005/10/25 09:52:43 zolty Exp $ +# $Id: Makefile.in,v 1.30 2005/10/26 14:54:43 zolty Exp $ #### Start of system configuration section. #### @@ -58,7 +58,6 @@ MPATH = ${DPATH}/ircd.motd RPATH = ${DPATH}/remote.motd - CC = @CC@ CFLAGS = @CFLAGS@ CPPFLAGS = -I. -I.. -I${top_srcdir}/include @CPPFLAGS@ Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.27 ircd-ircdev/ircd/channel.c:1.28 --- ircd-ircdev/ircd/channel.c:1.27 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ircd/channel.c Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Channel management and maintanance - * @version $Id: channel.c,v 1.27 2005/10/25 09:52:43 zolty Exp $ + * @version $Id: channel.c,v 1.28 2005/10/26 14:54:43 zolty Exp $ */ #include "config.h" @@ -152,8 +152,8 @@ for (num_free = 0, ban = free_bans; ban; ban = ban->next) num_free++; send_reply(cptr, SND_EXPLICIT | RPL_STATSDEBUG, ":Bans: inuse %zu(%zu) free %zu alloc %zu", - bans_inuse, bans_inuse * sizeof(*ban), num_free, bans_alloc); - } + bans_inuse, bans_inuse * sizeof(*ban), num_free, bans_alloc); +} /** return the struct Membership* that represents a client on a channel * This function finds a struct Membership* which holds the state about @@ -275,8 +275,7 @@ * the same time as if it had an Apass (but removing +i and +l), and * reopping the first user to rejoin. However, preventing net rides * requires a backwards-incompatible protocol change.. - */ - + */ if (!chptr->mode.apass[0]) /* If no Apass, destroy now. */ destruct_channel(chptr); else if (TStime() - chptr->creationtime < 172800) /* Channel younger than 48 hours? */ @@ -1069,7 +1068,7 @@ msgq_append(&me, mb, tbuf); new_mode = 0; } - else if (feat_oplevels && flag_cnt > 1 && last_oplevel != member->oplevel) + else if (feat_oplevels && flag_cnt > 1 && last_oplevel != member->oplevel) { /* * This can't be the first member of a (continued) BURST @@ -1669,7 +1668,7 @@ if (mbuf->mb_add == 0 && mbuf->mb_rem == 0 && mbuf->mb_count == 0) return 0; - /* Ok, if we were given the OPMODE flag or if it's a server, hide source + /* Ok, if we were given the OPMODE flag, or its a server, hide the source. */ if (mbuf->mb_dest & MODEBUF_DEST_OPMODE || IsServer(mbuf->mb_source) || IsMe(mbuf->mb_source)) app_source = &his; @@ -1869,7 +1868,7 @@ if (mbuf->mb_dest & MODEBUF_DEST_HACK4) sendto_opmask_butone(0, SNO_HACK4, "HACK(4): %s MODE %s %s%s%s%s%s%s " "[%Tu]", - cli_name(feature_bool(FEAT_HIS_SNOTICES) ? + cli_name(feature_bool(FEAT_HIS_SNOTICES) ? mbuf->mb_source : app_source), mbuf->mb_channel->chname, rembuf_i ? "-" : "", rembuf, addbuf_i ? "+" : "", Index: ircd-ircdev/ircd/class.c diff -u ircd-ircdev/ircd/class.c:1.10 ircd-ircdev/ircd/class.c:1.11 --- ircd-ircdev/ircd/class.c:1.10 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ircd/class.c Wed Oct 26 07:54:43 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Implementation of connection class handling functions. - * @version $Id: class.c,v 1.10 2005/10/25 09:52:43 zolty Exp $ + * @version $Id: class.c,v 1.11 2005/10/26 14:54:43 zolty Exp $ */ #include "config.h" @@ -304,4 +304,4 @@ send_reply(cptr, SND_EXPLICIT | RPL_STATSDEBUG, ":Classes: inuse: %d(%d)", connClassAllocCount, connClassAllocCount * sizeof(struct ConnectionClass)); -} +} \ No newline at end of file Index: ircd-ircdev/ircd/gline.c diff -u ircd-ircdev/ircd/gline.c:1.17 ircd-ircdev/ircd/gline.c:1.18 --- ircd-ircdev/ircd/gline.c:1.17 Tue Oct 25 02:52:43 2005 +++ ircd-ircdev/ircd/gline.c Wed Oct 26 07:54:43 2005 @@ -23,7 +23,7 @@ */ /** @file * @brief Implementation of Gline manipulation functions. - * @version $Id: gline.c,v 1.17 2005/10/25 09:52:43 zolty Exp $ + * @version $Id: gline.c,v 1.18 2005/10/26 14:54:43 zolty Exp $ */ #include "config.h" @@ -88,9 +88,9 @@ continue; ircd_snprintf(0, namebuf, sizeof(namebuf), "%s@%s", - cli_user(acptr)->username, cli_user(acptr)->host); + cli_user(acptr)->username, cli_user(acptr)->host); ircd_snprintf(0, ipbuf, sizeof(ipbuf), "%s@%s", cli_user(acptr)->username, - ircd_ntoa(&cli_ip(acptr))); + ircd_ntoa(&cli_ip(acptr))); if (!match(mask, namebuf) || !match(mask, ipbuf)) count++; @@ -145,10 +145,8 @@ { struct Gline *gline, *sgline, *after = 0; - if (!(flags & GLINE_BADCHAN)) { - /* search for overlapping glines first, skipping badchans and - * special $ glines. - */ + if (!(flags & GLINE_BADCHAN)) { /* search for overlapping glines first */ + for (gline = GlobalGlineList; gline; gline = sgline) { sgline = gline->gl_next; @@ -158,14 +156,14 @@ (gline->gl_host && !host) || (!gline->gl_host && host)) continue; else if (!mmatch(gline->gl_user, user) /* gline contains new mask */ - && (gline->gl_host == NULL || !mmatch(gline->gl_host, host))) { + && (gline->gl_host == NULL || !mmatch(gline->gl_host, host))) { if (expire <= gline->gl_expire) /* will expire before wider gline */ return 0; else after = gline; /* stick new gline after this one */ } else if (!mmatch(user, gline->gl_user) /* new mask contains gline */ - && (gline->gl_host==NULL || !mmatch(host, gline->gl_host)) - && gline->gl_expire <= expire) /* old expires before new */ + && (gline->gl_host==NULL || !mmatch(host, gline->gl_host)) + && gline->gl_expire <= expire) /* old expires before new */ gline_free(gline); /* save some memory */ } } @@ -269,7 +267,7 @@ /* let the ops know about it */ sendto_opmask_butone(0, SNO_GLINE, "G-line active for %s", - get_client_name(acptr, SHOW_IP)); + get_client_name(acptr, SHOW_IP)); /* and get rid of him */ if ((tval = exit_client_msg(cptr, acptr, &me, "G-lined (%s)", @@ -375,7 +373,7 @@ sendcmdto_serv_butone(sptr, CMD_GLINE, cptr, (GlineIsRemActive(gline) ? "* +%s%s%s %Tu :%s" : "* -%s%s%s"), - gline->gl_user, + gline->gl_user, gline->gl_host ? "@" : "", gline->gl_host ? gline->gl_host : "", gline->gl_expire - CurrentTime, gline->gl_reason); @@ -471,14 +469,15 @@ /* Inform ops... */ sendto_opmask_butone(0, ircd_strncmp(reason, "AUTO", 4) ? SNO_GLINE : - SNO_AUTO, "%s adding %s %s for %s%s%s, expiring at " - "%Tu: %s", - feature_bool(FEAT_HIS_SNOTICES) || IsServer(sptr) ? - cli_name(sptr) : cli_name((cli_user(sptr))->server), - flags & GLINE_LOCAL ? "local" : "global", - flags & GLINE_BADCHAN ? "BADCHAN" : "GLINE", user, - flags & (GLINE_BADCHAN|GLINE_REALNAME) ? "" : "@", - flags & (GLINE_BADCHAN|GLINE_REALNAME) ? "" : host, + SNO_AUTO, "%s adding %s %s for %s%s%s, expiring at " + "%Tu: %s", + (feature_bool(FEAT_HIS_SNOTICES) || IsServer(sptr)) ? + cli_name(sptr) : + cli_name((cli_user(sptr))->server), + (flags & GLINE_LOCAL) ? "local" : "global", + (flags & GLINE_BADCHAN) ? "BADCHAN" : "GLINE", user, + (flags & (GLINE_BADCHAN|GLINE_REALNAME)) ? "" : "@", + (flags & (GLINE_BADCHAN|GLINE_REALNAME)) ? "" : host, expire + TSoffset, reason); /* and log it */ @@ -537,19 +536,20 @@ /* Inform ops and log it */ sendto_opmask_butone(0, SNO_GLINE, "%s activating global %s for %s%s%s, " - "expiring at %Tu: %s", - feature_bool(FEAT_HIS_SNOTICES) || IsServer(sptr) ? - cli_name(sptr) : cli_name((cli_user(sptr))->server), - GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", + "expiring at %Tu: %s", + (feature_bool(FEAT_HIS_SNOTICES) || IsServer(sptr)) ? + cli_name(sptr) : + cli_name((cli_user(sptr))->server), + GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", gline->gl_user, gline->gl_host ? "@" : "", gline->gl_host ? gline->gl_host : "", - gline->gl_expire + TSoffset, gline->gl_reason); + gline->gl_expire + TSoffset, gline->gl_reason); log_write(LS_GLINE, L_INFO, LOG_NOSNOTICE, "%#C activating global %s for %s%s%s, expiring at %Tu: %s", sptr, GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", gline->gl_user, - gline->gl_host ? "@" : "", - gline->gl_host ? gline->gl_host : "", + gline->gl_host ? "@" : "", + gline->gl_host ? gline->gl_host : "", gline->gl_expire + TSoffset, gline->gl_reason); if (!(flags & GLINE_LOCAL)) /* don't propagate local changes */ @@ -605,18 +605,19 @@ /* Inform ops and log it */ sendto_opmask_butone(0, SNO_GLINE, "%s %s %s for %s%s%s, expiring at %Tu: " "%s", - feature_bool(FEAT_HIS_SNOTICES) || IsServer(sptr) ? - cli_name(sptr) : cli_name((cli_user(sptr))->server), + (feature_bool(FEAT_HIS_SNOTICES) || IsServer(sptr)) ? + cli_name(sptr) : + cli_name((cli_user(sptr))->server), msg, GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", - gline->gl_user, gline->gl_host ? "@" : "", + gline->gl_user, gline->gl_host ? "@" : "", gline->gl_host ? gline->gl_host : "", gline->gl_expire + TSoffset, gline->gl_reason); log_write(LS_GLINE, L_INFO, LOG_NOSNOTICE, "%#C %s %s for %s%s%s, expiring at %Tu: %s", sptr, msg, GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", gline->gl_user, - gline->gl_host ? "@" : "", - gline->gl_host ? gline->gl_host : "", + gline->gl_host ? "@" : "", + gline->gl_host ? gline->gl_host : "", gline->gl_expire + TSoffset, gline->gl_reason); if (!(flags & GLINE_LOCAL)) /* don't propagate local changes */ @@ -681,14 +682,14 @@ (flags & GLINE_LASTMOD && !gline->gl_lastmod)) continue; else if (flags & GLINE_EXACT) { - if (((gline->gl_host && host && ircd_strcmp(gline->gl_host,host) == 0) - ||(!gline->gl_host && !host)) && + if (((gline->gl_host && host && ircd_strcmp(gline->gl_host, host) == 0) + || (!gline->gl_host && !host)) && (ircd_strcmp(gline->gl_user, user) == 0)) break; } else { - if (((gline->gl_host && host && match(gline->gl_host,host) == 0) - ||(!gline->gl_host && !host)) && - (match(gline->gl_user, user) == 0)) + if (((gline->gl_host && host && match(gline->gl_host, host) == 0) + || (!gline->gl_host && !host)) && + (match(gline->gl_user, user) == 0)) break; } } @@ -719,13 +720,13 @@ } if ((flags & GLINE_GLOBAL && gline->gl_flags & GLINE_LOCAL) || - (flags & GLINE_LASTMOD && !gline->gl_lastmod)) + (flags & GLINE_LASTMOD && !gline->gl_lastmod)) continue; if (GlineIsRealName(gline)) { - Debug((DEBUG_DEBUG,"realname gline: '%s' '%s'",gline->gl_user,cli_info(cptr))); + Debug((DEBUG_DEBUG,"realname gline: '%s' '%s'",gline->gl_user,cli_info(cptr))); if (match(gline->gl_user+2, cli_info(cptr)) != 0) - continue; + continue; } else { if (match(gline->gl_user, (cli_user(cptr))->username) != 0) @@ -785,9 +786,9 @@ else if (!GlineIsLocal(gline) && gline->gl_lastmod) sendcmdto_one(&me, CMD_GLINE, cptr, "* %c%s%s%s %Tu %Tu :%s", GlineIsRemActive(gline) ? '+' : '-', gline->gl_user, - gline->gl_host ? "@" : "", + gline->gl_host ? "@" : "", gline->gl_host ? gline->gl_host : "", - gline->gl_expire - CurrentTime, gline->gl_lastmod, + gline->gl_expire - CurrentTime, gline->gl_lastmod, gline->gl_reason); } @@ -817,7 ... [truncated message content] |
From: Toni G. <zo...@us...> - 2005-10-26 15:13:47
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-26 15:13:37 UTC Modified files: doc/ircd.sample-en.conf Log message: ircd.conf ---------------------- diff included ---------------------- Index: ircd-ircdev/doc/ircd.sample-en.conf diff -u ircd-ircdev/doc/ircd.sample-en.conf:1.23 ircd-ircdev/doc/ircd.sample-en.conf:1.24 --- ircd-ircdev/doc/ircd.sample-en.conf:1.23 Mon Oct 17 07:02:32 2005 +++ ircd-ircdev/doc/ircd.sample-en.conf Wed Oct 26 08:13:27 2005 @@ -1,6 +1,6 @@ # ircd.conf - configuration file for IRC-Dev's IRCD. # -# Last Updated: 1, Sep 2005. +# Last Updated: 25, October 2005. # # Written by Niels <ni...@un...>, based on the original example.conf, # server code and some real-life (ahem) experience. @@ -59,7 +59,7 @@ # numeric = numericnumber; # }; # -# If present, "virtual" must contain a valid address in dotted +# If present, "vhost" must contain a valid address in dotted # quad or IPv6 numeric notation (127.0.0.1 or ::1). The address MUST # be the address of a physical interface on the host. This address is # used for outgoing connections if the "Connect" block does not override @@ -222,7 +222,8 @@ # apass_opmode (can use OPMODE/CLEARMODE on +A and +U keys) # # For global opers (with propagate = yes or local = no), the default - # is to grant all of the above privileges EXCEPT apass_opmode. For. + # is to grant all of the above privileges EXCEPT walk_lchan, + # unlimit_query, set, badchan, local_badchan and apass_opmode. For. # local opers, the default is to grant ONLY the following privileges: # chan_limit, mode_lchan, show_invis, show_all_invis, local_kill, # rehash, local_gline, local_jupe, local_opmode, whox, display, @@ -708,7 +709,7 @@ Quarantine { "#shells" = "Thou shalt not support the h4><0rz"; "&kiddies" = "They can take care of themselves"; - }; +}; # This is a server-implemented alias to send a message to a service. # The string after Pseudo is the command name; the name entry inside @@ -828,7 +829,6 @@ # "HIS_STATS_e" = "TRUE"; # "HIS_STATS_f" = "TRUE"; # "HIS_STATS_g" = "TRUE"; -# "HIS_STATS_h" = "TRUE"; # "HIS_STATS_i" = "TRUE"; # "HIS_STATS_j" = "TRUE"; # "HIS_STATS_J" = "TRUE"; @@ -847,7 +847,7 @@ # "HIS_STATS_u" = "FALSE"; # "HIS_STATS_U" = "TRUE"; # "HIS_STATS_v" = "TRUE"; -# "HIS_STATS_w" = "FALSE"; +# "HIS_STATS_w" = "TRUE"; # "HIS_STATS_x" = "TRUE"; # "HIS_STATS_y" = "TRUE"; # "HIS_STATS_z" = "TRUE"; @@ -855,7 +855,7 @@ # "HIS_WHOIS_IDLETIME" = "TRUE"; # "HIS_WHOIS_LOCALCHAN" = "TRUE"; # "HIS_WHO_SERVERNAME" = "TRUE"; -# "HIS_WHO_HOPCOUNT" = TRUE"; +# "HIS_WHO_HOPCOUNT" = "TRUE"; # "HIS_BANWHO" = "TRUE"; # "HIS_KILLWHO" = "TRUE"; # "HIS_REWRITE" = "TRUE"; ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-10-26 15:23:21
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-26 15:23:11 UTC Modified files: ircd/class.c ircd/ircd.c ircd/ircd_alloc.c ircd/ircd_relay.c ircd/m_userip.c ircd/test/Makefile.in Log message: Author: zoltan <zo...@ir...> Log message: 2005-10-26 Toni García <zo...@ir...> 1.0.alpha46 * Limpieza de código ---------------------- diff included ---------------------- Index: ircd-ircdev/ircd/class.c diff -u ircd-ircdev/ircd/class.c:1.11 ircd-ircdev/ircd/class.c:1.12 --- ircd-ircdev/ircd/class.c:1.11 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ircd/class.c Wed Oct 26 08:23:00 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Implementation of connection class handling functions. - * @version $Id: class.c,v 1.11 2005/10/26 14:54:43 zolty Exp $ + * @version $Id: class.c,v 1.12 2005/10/26 15:23:00 zolty Exp $ */ #include "config.h" @@ -304,4 +304,4 @@ send_reply(cptr, SND_EXPLICIT | RPL_STATSDEBUG, ":Classes: inuse: %d(%d)", connClassAllocCount, connClassAllocCount * sizeof(struct ConnectionClass)); -} \ No newline at end of file +} Index: ircd-ircdev/ircd/ircd.c diff -u ircd-ircdev/ircd/ircd.c:1.24 ircd-ircdev/ircd/ircd.c:1.25 --- ircd-ircdev/ircd/ircd.c:1.24 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ircd/ircd.c Wed Oct 26 08:23:01 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Entry point and other initialization functions for the daemon. - * @version $Id: ircd.c,v 1.24 2005/10/26 14:54:43 zolty Exp $ + * @version $Id: ircd.c,v 1.25 2005/10/26 15:23:01 zolty Exp $ */ #include "config.h" @@ -772,4 +772,4 @@ event_loop(); return 0; -} \ No newline at end of file +} Index: ircd-ircdev/ircd/ircd_alloc.c diff -u ircd-ircdev/ircd/ircd_alloc.c:1.7 ircd-ircdev/ircd/ircd_alloc.c:1.8 --- ircd-ircdev/ircd/ircd_alloc.c:1.7 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ircd/ircd_alloc.c Wed Oct 26 08:23:01 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief IRC daemon memory allocation functions. - * @version $Id: ircd_alloc.c,v 1.7 2005/10/26 14:54:43 zolty Exp $ + * @version $Id: ircd_alloc.c,v 1.8 2005/10/26 15:23:01 zolty Exp $ */ #include "config.h" @@ -102,4 +102,4 @@ (*noMemHandler)(); return t; } -#endif \ No newline at end of file +#endif Index: ircd-ircdev/ircd/ircd_relay.c diff -u ircd-ircdev/ircd/ircd_relay.c:1.9 ircd-ircdev/ircd/ircd_relay.c:1.10 --- ircd-ircdev/ircd/ircd_relay.c:1.9 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ircd/ircd_relay.c Wed Oct 26 08:23:01 2005 @@ -21,7 +21,7 @@ */ /** @file * @brief Helper functions to relay various types of messages. - * @version $Id: ircd_relay.c,v 1.9 2005/10/26 14:54:43 zolty Exp $ + * @version $Id: ircd_relay.c,v 1.10 2005/10/26 15:23:01 zolty Exp $ * * There are four basic types of messages, each with four subtypes. * @@ -567,4 +567,4 @@ IsServer(cli_from(sptr)) ? cli_from(sptr) : 0, host_mask ? MATCH_HOST : MATCH_SERVER, "%s :%s", mask, text); -} \ No newline at end of file +} Index: ircd-ircdev/ircd/m_userip.c diff -u ircd-ircdev/ircd/m_userip.c:1.8 ircd-ircdev/ircd/m_userip.c:1.9 --- ircd-ircdev/ircd/m_userip.c:1.8 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ircd/m_userip.c Wed Oct 26 08:23:01 2005 @@ -1,4 +1,4 @@ -* +/* * IRC-Dev IRCD - An advanced and innovative IRC Daemon, ircd/m_userip.c * * Copyright (C) 2002-2005 IRC-Dev Development Team <de...@ir...> @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: m_userip.c,v 1.8 2005/10/26 14:54:43 zolty Exp $ + * $Id: m_userip.c,v 1.9 2005/10/26 15:23:01 zolty Exp $ * */ Index: ircd-ircdev/ircd/test/Makefile.in diff -u ircd-ircdev/ircd/test/Makefile.in:1.7 ircd-ircdev/ircd/test/Makefile.in:1.8 --- ircd-ircdev/ircd/test/Makefile.in:1.7 Tue Oct 25 04:27:10 2005 +++ ircd-ircdev/ircd/test/Makefile.in Wed Oct 26 08:23:01 2005 @@ -18,7 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA -# $Id: Makefile.in,v 1.7 2005/10/25 11:27:10 zolty Exp $ +# $Id: Makefile.in,v 1.8 2005/10/26 15:23:01 zolty Exp $ top_srcdir = @top_srcdir@ srcdir = @srcdir@ @@ -92,7 +92,9 @@ ../../include/numnicks.h ../../include/client.h \ ../../include/ircd_defs.h ../../include/dbuf.h ../../include/msgq.h \ ../../include/ircd_events.h ../../config.h ../../include/ircd_handler.h \ - ../../include/res.h ../../include/capab.h + ../../include/res.h ../../include/capab.h ../../include/res.h +ircd_match_t.o: ircd_match_t.c ../../include/ircd_log.h \ + ../../include/match.h ../../include/res.h ../../config.h ircd_string_t.o: ircd_string_t.c ../../include/ircd_string.h \ ../../include/ircd_chattr.h test_stub.o: test_stub.c ../../include/client.h ../../include/ircd_defs.h \ ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2005-10-26 15:26:04
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2005-10-26 15:25:55 UTC Modified files: ChangeLog ChangeLog.es include/patchlevel.h Log message: Version 1.0.beta0 ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.48 ircd-ircdev/ChangeLog:1.49 --- ircd-ircdev/ChangeLog:1.48 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ChangeLog Wed Oct 26 08:25:45 2005 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.48 2005/10/26 14:54:43 zolty Exp $ +# $Id: ChangeLog,v 1.49 2005/10/26 15:25:45 zolty Exp $ # # Insert new changes at beginning of the change list. # +2005-10-27 Toni García <zo...@ir...> 1.0.beta0 + * First beta version + 2005-10-26 Toni García <zo...@ir...> 1.0.alpha46 * Cleanup code Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.48 ircd-ircdev/ChangeLog.es:1.49 --- ircd-ircdev/ChangeLog.es:1.48 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/ChangeLog.es Wed Oct 26 08:25:45 2005 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.48 2005/10/26 14:54:43 zolty Exp $ +# $Id: ChangeLog.es,v 1.49 2005/10/26 15:25:45 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2005-10-27 Toni García <zo...@ir...> 1.0.beta0 + * Primera versión beta + 2005-10-26 Toni García <zo...@ir...> 1.0.alpha46 * Limpieza de código Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.47 ircd-ircdev/include/patchlevel.h:1.48 --- ircd-ircdev/include/patchlevel.h:1.47 Wed Oct 26 07:54:43 2005 +++ ircd-ircdev/include/patchlevel.h Wed Oct 26 08:25:45 2005 @@ -17,12 +17,12 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id: patchlevel.h,v 1.47 2005/10/26 14:54:43 zolty Exp $ + * $Id: patchlevel.h,v 1.48 2005/10/26 15:25:45 zolty Exp $ * */ -#define PATCHLEVEL "46" +#define PATCHLEVEL "0" -#define RELEASE "1.0.alpha" +#define RELEASE "1.0.beta" /* * Deliberate empty lines ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2007-04-19 22:54:17
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2007-04-19 22:54:11 UTC Modified files: ChangeLog ChangeLog.es Makefile.in acconfig.h config.h.in configure configure.in doc/Makefile.in include/IPcheck.h include/capab.h include/channel.h include/class.h include/client.h include/crule.h include/dbuf.h include/ddb.h include/destruct_event.h include/fileio.h include/gline.h include/handlers.h include/hash.h include/ircd.h include/ircd_alloc.h include/ircd_auth.h include/ircd_chattr.h include/ircd_crypt.h include/ircd_crypt_native.h include/ircd_crypt_plain.h include/ircd_crypt_smd5.h include/ircd_defs.h include/ircd_events.h include/ircd_features.h include/ircd_handler.h include/ircd_log.h include/ircd_md5.h include/ircd_osdep.h include/ircd_relay.h include/ircd_reply.h include/ircd_reslib.h include/ircd_signal.h include/ircd_snprintf.h include/ircd_string.h include/ircd_tea.h include/jupe.h include/list.h include/listener.h include/match.h include/memdebug.h include/motd.h include/msg.h include/msgq.h include/numeric.h include/numnicks.h include/opercmds.h include/packet.h include/parse.h include/patchlevel.h include/querycmds.h include/random.h include/res.h include/s_auth.h include/s_bsd.h include/s_conf.h include/s_debug.h include/s_misc.h include/s_numeric.h include/s_serv.h include/s_stats.h include/s_user.h include/send.h include/struct.h include/sys.h include/umkpasswd.h include/uping.h include/userload.h include/version.h include/watch.h include/whowas.h ircd/.cvsignore ircd/IPcheck.c ircd/Makefile.in ircd/channel.c ircd/class.c ircd/client.c ircd/convert-conf.c ircd/crule.c ircd/dbuf.c ircd/ddb.c ircd/ddb_db_native.c ircd/ddb_db_template.c ircd/ddb_events.c ircd/destruct_event.c ircd/engine_devpoll.c ircd/engine_epoll.c ircd/engine_kqueue.c ircd/engine_poll.c ircd/engine_select.c ircd/fileio.c ircd/gline.c ircd/hash.c ircd/ircd.c ircd/ircd_alloc.c ircd/ircd_auth.c ircd/ircd_crypt.c ircd/ircd_crypt_native.c ircd/ircd_crypt_plain.c ircd/ircd_crypt_smd5.c ircd/ircd_events.c ircd/ircd_features.c ircd/ircd_lexer.l ircd/ircd_log.c ircd/ircd_md5.c ircd/ircd_parser.y ircd/ircd_relay.c ircd/ircd_reply.c ircd/ircd_res.c ircd/ircd_reslib.c ircd/ircd_signal.c ircd/ircd_snprintf.c ircd/ircd_string.c ircd/ircd_tea.c ircd/jupe.c ircd/list.c ircd/listener.c ircd/m_account.c ircd/m_admin.c ircd/m_asll.c ircd/m_away.c ircd/m_bmode.c ircd/m_burst.c ircd/m_cap.c ircd/m_clearmode.c ircd/m_close.c ircd/m_connect.c ircd/m_cprivmsg.c ircd/m_create.c ircd/m_db.c ircd/m_dbq.c ircd/m_defaults.c ircd/m_destruct.c ircd/m_desynch.c ircd/m_die.c ircd/m_endburst.c ircd/m_error.c ircd/m_get.c ircd/m_ghost.c ircd/m_gline.c ircd/m_help.c ircd/m_info.c ircd/m_invite.c ircd/m_ison.c ircd/m_join.c ircd/m_jupe.c ircd/m_kick.c ircd/m_kill.c ircd/m_links.c ircd/m_list.c ircd/m_lusers.c ircd/m_map.c ircd/m_mode.c ircd/m_motd.c ircd/m_names.c ircd/m_nick.c ircd/m_notice.c ircd/m_oper.c ircd/m_opmode.c ircd/m_part.c ircd/m_pass.c ircd/m_ping.c ircd/m_pong.c ircd/m_privmsg.c ircd/m_privs.c ircd/m_proto.c ircd/m_pseudo.c ircd/m_quit.c ircd/m_rehash.c ircd/m_reset.c ircd/m_restart.c ircd/m_rping.c ircd/m_rpong.c ircd/m_server.c ircd/m_set.c ircd/m_settime.c ircd/m_silence.c ircd/m_squit.c ircd/m_stats.c ircd/m_svsnick.c ircd/m_time.c ircd/m_tmpl.c ircd/m_topic.c ircd/m_trace.c ircd/m_uping.c ircd/m_user.c ircd/m_userhost.c ircd/m_userip.c ircd/m_users.c ircd/m_version.c ircd/m_wallchops.c ircd/m_wallops.c ircd/m_wallusers.c ircd/m_wallvoices.c ircd/m_watch.c ircd/m_who.c ircd/m_whois.c ircd/m_whowas.c ircd/match.c ircd/memdebug.c ircd/motd.c ircd/msgq.c ircd/numnicks.c ircd/opercmds.c ircd/os_generic.c ircd/packet.c ircd/parse.c ircd/querycmds.c ircd/random.c ircd/s_auth.c ircd/s_bsd.c ircd/s_conf.c ircd/s_debug.c ircd/s_err.c ircd/s_misc.c ircd/s_numeric.c ircd/s_serv.c ircd/s_stats.c ircd/s_user.c ircd/send.c ircd/table_gen.c ircd/umkpasswd.c ircd/uping.c ircd/userload.c ircd/version.c.SH ircd/watch.c ircd/whowas.c ircd/test/.cvsignore ircd/test/Makefile.in tools/ringlog.c tools/wrapper.c Log message: Author: zoltan <zo...@ir...> Log message: 2007-04-20 Toni Garc�a <zo...@ir...> 1.0.beta1 * Escribir comentarios de doxygen * Statics ---------------------- diff included ---------------------- ----------------------- End of diff ----------------------- |