Commits

jdhore committed 9e8ec4b

Add option general::use_propagated_bans to allow disabling new KLINE.

If this option is yes (default), KLINE by itself sets global (propagated) bans.
If this option is no, KLINE by itself sets a local kline following cluster{},
compatible with 3.2 and older versions.

  • Participants
  • Parent commits 3ecaed2

Comments (0)

Files changed (7)

 	identify_command = "IDENTIFY";
 	non_redundant_klines = yes;
 	warn_no_nline = yes;
+	use_propagated_bans = yes;
 	stats_e_disabled = no;
 	stats_c_oper_only=no;
 	stats_h_oper_only=no;

doc/reference.conf

 	 */
 	warn_no_nline = yes;
 
+	/* use propagated bans: KLINE sets fully propagated bans. That means
+	 * the klines are part of the netburst and restarted/split servers
+	 * will get them, but they will not apply to 3.2 and older servers
+	 * at all.
+	 */
+	use_propagated_bans = yes;
+
 	/* stats e disabled: disable stats e.  useful if server ips are
 	 * exempted and you dont want them listing on irc.
 	 */
 	int default_umodes;
 	int global_snotices;
 	int operspy_dont_care_user_info;
+	int use_propagated_bans;
 	int secret_channels_in_whois;
 	int expire_override_time;
 };
 		"Display warning if connecting server lacks N-line"
 	},
 	{
+		"use_propagated_bans",
+		OUTPUT_BOOLEAN,
+		&ConfigFileEntry.use_propagated_bans,
+		"KLINE sets fully propagated bans"
+	},
+	{
 		"default_split_server_count",
 		OUTPUT_DECIMAL,
 		&ConfigChannel.default_split_server_count,

modules/m_kline.c

 	struct ConfItem *aconf;
 	int tkline_time = 0;
 	int loc = 1;
-	int propagated = 1;
+	int propagated = ConfigFileEntry.use_propagated_bans;
 
 	if(!IsOperK(source_p))
 	{
 	{ "ts_warn_delta",	CF_TIME,  NULL, 0, &ConfigFileEntry.ts_warn_delta	},
 	{ "use_whois_actually", CF_YESNO, NULL, 0, &ConfigFileEntry.use_whois_actually	},
 	{ "warn_no_nline",	CF_YESNO, NULL, 0, &ConfigFileEntry.warn_no_nline	},
+	{ "use_propagated_bans",CF_YESNO, NULL, 0, &ConfigFileEntry.use_propagated_bans	},
 	{ "expire_override_time",	CF_TIME, NULL, 0, &ConfigFileEntry.expire_override_time},
 	{ "\0", 		0, 	  NULL, 0, NULL }
 };
 	ConfigFileEntry.collision_fnc = YES;
 	ConfigFileEntry.global_snotices = YES;
 	ConfigFileEntry.operspy_dont_care_user_info = NO;
+	ConfigFileEntry.use_propagated_bans = YES;
 	ConfigFileEntry.secret_channels_in_whois = NO;
 
 #ifdef HAVE_LIBZ