From 5fcfec485b4b96c26eac26aa37b026e92ebbc1a3 Mon Sep 17 00:00:00 2001 From: Michael Poole Date: Fri, 10 Sep 2004 22:31:15 +0000 Subject: [PATCH] Remove unused features and their documentation. git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/trunk@1113 c9e4aea6-c8fd-4c43-8297-357d70d61c8c --- ChangeLog | 21 +++ doc/example.conf | 3 +- doc/readme.features | 363 +++------------------------------------- include/ircd_features.h | 4 - ircd/ircd_features.c | 4 - ircd/ircd_res.c | 8 +- ircd/s_debug.c | 3 - 7 files changed, 47 insertions(+), 359 deletions(-) diff --git a/ChangeLog b/ChangeLog index c14883a..09876b4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,24 @@ +2004-09-10 Michael Poole + + * doc/example.conf: Remove examples for unused features (TIMESEC, + CRYPT_OPER_PASSWORD) and add for new feature (ANNOUNCE_INVITES). + + * doc/readme.features: Remove documentation for unused features + (TIMESEC, CRYPT_OPER_PASSWORD, oper/locop privileges, + HIS_DESYNCS), update defaults for SOCKSENDBUF and SOCKRECVBUF, and + add documentation for ANNOUNCE_INVITES. + + * include/ircd_features.h: Remove unused features (TIMESEC, + CRYPT_OPER_PASSWORD, LIST_CHAN, HIS_DESYNCS). + + * include/ircd_features.c: Likewise. + + * ircd/ircd_res.c: Actually use FEAT_IRCD_RES_RETRIES and + FEAT_IRCD_RES_TIMEOUT where appropriate. + + * ircd/s_debug.c: Do not display setting of unused (and now + non-existent) FEAT_CRYPT_OPER_PASSWORD. + 2004-09-10 Michael Poole * ircd/os_generic.c (sockaddr_from_irc): Fix IPv4 implementation diff --git a/doc/example.conf b/doc/example.conf index c745f8a..232e5d3 100644 --- a/doc/example.conf +++ b/doc/example.conf @@ -795,7 +795,6 @@ features # "HANGONGOODLINK="300"; # "HANGONRETRYDELAY" = "10"; # "CONNECTTIMEOUT" = "90"; -# "TIMESEC" = "60"; # "MAXIMUM_LINKS" = "1"; # "PINGFREQUENCY" = "120"; # "CONNECTFREQUENCY" = "600"; @@ -814,10 +813,10 @@ features # "IPCHECK_CLONE_LIMIT" = "4"; # "IPCHECK_CLONE_PERIOD" = "40"; # "IPCHECK_CLONE_DELAY" = "600"; -# "CRYPT_OPER_PASSWORD" = "TRUE"; # "CONFIG_OPERCMDS" = "FALSE"; # "OPLEVELS" = "TRUE"; # "LOCAL_CHANNELS" = "TRUE"; +# "ANNOUNCE_INVITES" = "FALSE"; }; # Well, you have now reached the end of this sample configuration diff --git a/doc/readme.features b/doc/readme.features index c98ba10..2bad879 100644 --- a/doc/readme.features +++ b/doc/readme.features @@ -339,14 +339,6 @@ change this value, but if you do, consider the fact that users whose clients do not support NOSPOOF will have to type /QUOTE PING before registration. -TIMESEC - * Type: integer - * Default: 60 - -This is the maximum idle time for the server. If no messages are -received in TIMESEC seconds, PINGFREQUENCY and CONNECTFREQUENCY are -checked. Recommended value is 60 seconds. - MAXIMUM_LINKS * Type: integer * Default: 1 @@ -456,91 +448,6 @@ from the kernel at once. Since the number retrieved can impact performance, it can be tuned by modifying this value. The engines enforce a lower limit of 20. -CRYPT_OPER_PASSWORD - * Type: boolean - * Default: TRUE - -In order to allow certain users to become IRC operators, they must -authenticate themselves with a password. This password is matched -against an Operator block in the "ircd.conf" configuration file; see -doc/example.conf for more details. If you specify "TRUE" here, you -must use the crypted form of these passwords in your "ircd.conf" file. -Since compromises of the "ircd.conf" file have happened in the past, -you are highly encouraged to use this option. You can find a program -called "mkpasswd" in the tools directory that will allow you to -generate crypted passwords. - -OPER_NO_CHAN_LIMIT - * Type: boolean - * Default: TRUE - -If this option is set to "TRUE," IRC operators may join as many -channels as they need to. This is primarily intended to permit -administrators to run a channel service for local ("&") channels. - -OPER_MODE_LCHAN - * Type: boolean - * Default: TRUE - -If this option is set to "TRUE," IRC operators may change the channel -modes on local ("&") channels. This is primarily intended to permit -administrators to run a channel service for local channels. - -OPER_WALK_THROUGH_LMODES - * Type: boolean - * Default: FALSE - -If this option is set to "TRUE," IRC operators may join local ("&") -channels regardless of any restrictive modes, including bans. This -requires giving the special password "OVERRIDE." This is primarily -intended to permit administrators to run a channel service for local -channels. - -NO_OPER_DEOP_LCHAN - * Type: boolean - * Default: FALSE - -If this option is set to "TRUE," IRC operators may not be deopped on -local ("&") channels. This is primarily intended to permit -administrators to run a channel service for local channels. - -SHOW_INVISIBLE_USERS - * Type: boolean - * Default: TRUE - -If you specify "TRUE" here, then your (local) IRC Operators will be -able to see all local invisible users (clients connected to your own -server). This should be used only for investigating instances of -abuse; make sure your operators do not use this for spying on -individuals. - -SHOW_ALL_INVISIBLE_USERS - * Type: boolean - * Default: TRUE - -If you specify "TRUE" here, then your global IRC Operators will be -able to see ALL invisible users. This should be used only for -investigating instances of abuse; make sure your operators do not use -this for spying on individuals. - -UNLIMIT_OPER_QUERY - * Type: boolean - * Default: FALSE - -A /WHO command can sometimes return several hundred lines of -information. To reduce the flood potential, the output is truncated. -By setting this option to "TRUE," when an IRC Operator uses /WHO, the -output will not be truncated, no matter how much data is returned. - -LOCAL_KILL_ONLY - * Type: boolean - * Default: FALSE - -If this option is set to "TRUE," operators of this server may only -KILL clients directly connected to this server. Operators will not be -able to issue KILLs for clients on other servers. Some networks may -require that this be turned on for newly linking servers. - CONFIG_OPERCMDS * Type: boolean * Default: FALSE @@ -553,234 +460,6 @@ 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. -OPER_KILL - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue the /KILL command. - -OPER_REHASH - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue the /REHASH command. - -OPER_RESTART - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue the /RESTART command. - -OPER_DIE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue the /DIE command. - -OPER_GLINE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue global G-lines. - -OPER_LGLINE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue local G-lines. - -OPER_JUPE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue global jupes. - -OPER_LJUPE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to issue local jupes. - -OPER_OPMODE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to use /OPMODE and /CLEARMODE on ordinary ("#") channels. - -OPER_LOPMODE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to use /OPMODE and /CLEARMODE on local ("&") channels. - -OPER_FORCE_OPMODE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to override Q-lines set for /OPMODE and /CLEARMODE on ordinary ("#") channels - -OPER_FORCE_LOPMODE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to override Q-lines set for /OPMODE and /CLEARMODE on local ("&") channels - -OPER_BADCHAN - * Type: boolean - * Default: FALSE - -This selects whether global IRC operators on this server are permitted -to issue global BADCHANs. USE OF THIS ON THE UNDERNET IS STRICTLY -REGULATED BY THE UNDERNET ADMINISTRATION. - -OPER_LBADCHAN - * Type: boolean - * Default: FALSE - -This selects whether global IRC operators on this server are permitted -to issue local BADCHANs. USE OF THIS ON THE UNDERNET IS STRICTLY -REGULATED BY THE UNDERNET ADMINISTRATION. - -OPER_SET - * Type: boolean - * Default: FALSE - -This selects whether global IRC operators on this server are permitted -to use the /SET command to set various feature values. - -OPERS_SEE_IN_SECRET_CHANNELS - * Type: boolean - * Default: TRUE - -If you specify "TRUE" here, then your global IRC Operators will be -able to see who is on a specified secret channel, without joining -themselves. This can be used to make a reasonable judgment in the -case of a "channel takeover" being reported, while the channel is set -invite-only. See doc/readme.who for more details. - -OPER_WIDE_GLINE - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators on this server are permitted -to use the /GLINE command with the ! flag to force slightly wide -G-lines to be set. - -OPER_LIST_CHAN - * Type: boolean - * Default: TRUE - -This selects whether global IRC operators are permitted to list secret -(+s) channels. - -LOCOP_KILL - * Type: boolean - * Default: TRUE - -This selects whether local IRC operators are permitted to use the -/KILL command on local clients. - -LOCOP_REHASH - * Type: boolean - * Default: TRUE - -This selects whether local IRC operators are permitted to use the -/REHASH command. - -LOCOP_RESTART - * Type: boolean - * Default: FALSE - -This selects whether local IRC operators are permitted to use the -/RESTART command. - -LOCOP_DIE - * Type: boolean - * Default: FALSE - -This selects whether local IRC operators are permitted to use the /DIE -command. - -LOCOP_LGLINE - * Type: boolean - * Default: TRUE - -This selects whether local IRC operators are permitted to issue local -G-lines. - -LOCOP_LJUPE - * Type: boolean - * Default: TRUE - -This selects whether local IRC operators are permitted to issue local -jupes. - -LOCOP_LOPMODE - * Type: boolean - * Default: TRUE - -This selects whether local IRC operators are permitted to use /OPMODE -and /CLEARMODE on local ("&") channels. - -LOCOP_FORCE_LOPMODE - * Type: boolean - * Default: TRUE - -This selects whether local IRC operators on this server are permitted -to override Q-lines set for /OPMODE and /CLEARMODE on local ("&") channels - -LOCOP_LBADCHAN - * Type: boolean - * Default: FALSE - -This selects whether local IRC operators are permitted to issue local -BADCHANs. USE OF THIS ON THE UNDERNET IS STRICTLY REGULATED BY THE -UNDERNET ADMINISTRATION. - -LOCOP_SET - * Type: boolean - * Default: FALSE - -This selects whether local IRC operators are permitted to use the /SET -command to set various feature values. - -LOCOP_SEE_IN_SECRET_CHANNELS - * Type: boolean - * Default: FALSE - -If you specify "TRUE" here, then your local IRC Operators will be -able to see who is on a specified secret channel, without joining -themselves. This can be used to make a reasonable judgment in the -case of a "channel takeover" being reported, while the channel is set -invite-only. See doc/readme.who for more details. - -LOCOP_WIDE_GLINE - * Type: boolean - * Default: FALSE - -This selects whether local IRC operators are permitted to use the -/GLINE command with the ! flag to force slightly wide G-lines to be -set. - -LOCOP_LIST_CHAN - * Type: boolean - * Default: FALSE - -This selects whether local IRC operators are permitted to list secret -(+s) channels. - HIS_MAP * Type: boolean * Default: TRUE @@ -792,18 +471,12 @@ HIS_SNOTICES * Default: TRUE As per UnderNet CFV-165, this removes server notices from users. - + HIS_SNOTICES_OPER_ONLY * Type: boolean * Default: TRUE As per UnderNet CFV-165, this removes server notices from users. - -HIS_DESYNCS - * Type: boolean - * Default: TRUE - -As per UnderNet CFV-165, this removes server wallops from users. HIS_DEBUG_OPER_ONLY * Type: boolean @@ -904,7 +577,7 @@ As per UnderNet CFV-165, this removes /STATS p from users. HIS_STATS_q * Type: boolean * Default: TRUE - + As per UnderNet CFV-165, this removes /STATS q from users. HIS_STATS_r @@ -1049,11 +722,11 @@ HIS_SERVERINFO As per UnderNet CFV-165, this is the "info" of the server shown to users on a /WHOIS of another user. -HIS_URLSERVERS - * Type: string +HIS_URLSERVERS + * Type: string * Default: "http://www.undernet.org/servers.php" -As per UnderNet CFV-165, this is the URL shown to users when they do a /MAP or +As per UnderNet CFV-165, this is the URL shown to users when they do a /MAP or /LINKS. NETWORK @@ -1082,9 +755,8 @@ IRCD_RES_RETRIES * Type: integer * Default: 2 -This is the number of attempts the irc daemon's resolver will have at +This is the number of attempts the irc daemon's resolver will have at trying to solicit a response from the DNS server. -NOTE: Has no effect when using the adns resolver. IRCD_RES_TIMEOUT * Type: integer @@ -1100,7 +772,7 @@ AUTH_TIMEOUT * Type: integer * Default: 9 -This is the maximum number of seconds to wait for the ident lookup and +This is the maximum number of seconds to wait for the ident lookup and the DNS query to succeed. On older (pre 2.10.11.06) servers this was hard coded to 60 seconds. @@ -1113,10 +785,10 @@ seconds before you are considered abusing the server and throttled. IPCHECK_CLONE_PERIOD * Type: integer - * Defualt: 40 + * Default: 40 The number of seconds you are allowed to connect IPCHECK_CLONE_LIMIT times -within before you are considered abusing the server and throttled. +within before you are considered abusing the server and throttled. For instance if you set IPCHECK_CLONE_LIMIT to 1, and IPCHECK_CLONE_PERIOD to 10, then a user is only allowed to connect once in 10s, if they connect again within 10s, then they are considered to be connecting too fast and @@ -1127,19 +799,26 @@ IPCHECK_CLONE_DELAY * Default: 600 The number of seconds grace after restarting the server before the throttle -code kicks in. Even if a user connects repeditively during this period, -they will never get throttled. This is so after a restart users on a -multiuser box can all connect to a server simultaniously without being +code kicks in. Even if a user connects repetitively during this period, +they will never get throttled. This is so after a restart users on a +multiuser box can all connect to a server simultaniously without being considered an attack. SOCKSENDBUF * Type: integer - * Default: 0 + * Default: 61440 The send window size used for connections to other servers. SOCKRECVBUF * Type: integer - * Default: 0 + * Default: 61440 The receive window size used for connections to other servers. + +ANNOUNCE_INVITES + * Type: boolean + * Default: FALSE + +If set, send RPL_ISSUEDINVITE (345) to a channel's operators to +announce when someone is invited to the channel. diff --git a/include/ircd_features.h b/include/ircd_features.h index 05ea365..dd72b3e 100644 --- a/include/ircd_features.h +++ b/include/ircd_features.h @@ -62,7 +62,6 @@ enum Feature { FEAT_HANGONGOODLINK, FEAT_HANGONRETRYDELAY, FEAT_CONNECTTIMEOUT, - FEAT_TIMESEC, FEAT_MAXIMUM_LINKS, FEAT_PINGFREQUENCY, FEAT_CONNECTFREQUENCY, @@ -90,14 +89,11 @@ enum Feature { FEAT_ANNOUNCE_INVITES, /* features that affect all operators */ - FEAT_CRYPT_OPER_PASSWORD, FEAT_CONFIG_OPERCMDS, - FEAT_LIST_CHAN, /* HEAD_IN_SAND Features */ FEAT_HIS_SNOTICES, FEAT_HIS_SNOTICES_OPER_ONLY, - FEAT_HIS_DESYNCS, FEAT_HIS_DEBUG_OPER_ONLY, FEAT_HIS_WALLOPS, FEAT_HIS_MAP, diff --git a/ircd/ircd_features.c b/ircd/ircd_features.c index ec6e689..6756a90 100644 --- a/ircd/ircd_features.c +++ b/ircd/ircd_features.c @@ -268,7 +268,6 @@ static struct FeatureDesc { F_I(HANGONGOODLINK, 0, 300, 0), F_I(HANGONRETRYDELAY, 0, 10, 0), F_I(CONNECTTIMEOUT, 0, 90, 0), - F_I(TIMESEC, 0, 60, 0), F_I(MAXIMUM_LINKS, 0, 1, init_class), /* reinit class 0 as needed */ F_I(PINGFREQUENCY, 0, 120, init_class), F_I(CONNECTFREQUENCY, 0, 600, init_class), @@ -296,14 +295,11 @@ static struct FeatureDesc { F_B(ANNOUNCE_INVITES, 0, 0, 0), /* features that affect all operators */ - F_B(CRYPT_OPER_PASSWORD, FEAT_MYOPER | FEAT_READ, 1, 0), F_B(CONFIG_OPERCMDS, 0, 0, 0), - F_B(LIST_CHAN, 0, 1, 0), /* HEAD_IN_SAND Features */ F_B(HIS_SNOTICES, 0, 1, 0), F_B(HIS_SNOTICES_OPER_ONLY, 0, 1, 0), - F_B(HIS_DESYNCS, 0, 1, 0), F_B(HIS_DEBUG_OPER_ONLY, 0, 1, 0), F_B(HIS_WALLOPS, 0, 1, 0), F_B(HIS_MAP, 0, 1, 0), diff --git a/ircd/ircd_res.c b/ircd/ircd_res.c index c9bef27..fbc1315 100644 --- a/ircd/ircd_res.c +++ b/ircd/ircd_res.c @@ -253,9 +253,9 @@ make_request(const struct DNSQuery* query) memset(request, 0, sizeof(struct reslist)); request->sentat = CurrentTime; - request->retries = 3; + request->retries = feature_int(FEAT_IRCD_RES_RETRIES); request->resend = 1; - request->timeout = 4; /* start at 4 and exponential inc. */ + request->timeout = feature_int(FEAT_IRCD_RES_TIMEOUT); memset(&request->addr, 0, sizeof(request->addr)); request->query.vptr = query->vptr; request->query.callback = query->callback; @@ -762,14 +762,14 @@ res_readreply(struct Event *ev) if (request->state == REQ_AAAA && request->type == T_AAAA) { - request->timeout += 4; + request->timeout += feature_int(FEAT_IRCD_RES_TIMEOUT); resend_query(request); } else if (request->type == T_PTR && request->state != REQ_INT && !irc_in_addr_is_ipv4(&request->addr)) { request->state = REQ_INT; - request->timeout += 4; + request->timeout += feature_int(FEAT_IRCD_RES_TIMEOUT); resend_query(request); } else diff --git a/ircd/s_debug.c b/ircd/s_debug.c index 6899c74..b861345 100644 --- a/ircd/s_debug.c +++ b/ircd/s_debug.c @@ -99,9 +99,6 @@ const char* debug_serveropts(void) if (feature_bool(FEAT_IDLE_FROM_MSG)) AddC('M'); - if (feature_bool(FEAT_CRYPT_OPER_PASSWORD)) - AddC('p'); - if (feature_bool(FEAT_RELIABLE_CLOCK)) AddC('R'); -- 2.20.1