]> jfr.im git - irc/freenode/Sigyn.git/blame - config.py
Merge branch 'master' of github.com:freenode/Sigyn
[irc/freenode/Sigyn.git] / config.py
CommitLineData
6f7f2f85
NC
1###
2# Copyright (c) 2016, Nicolas Coevoet
3# All rights reserved.
4#
5# Redistribution and use in source and binary forms, with or without
6# modification, are permitted provided that the following conditions are met:
7#
8# * Redistributions of source code must retain the above copyright notice,
9# this list of conditions, and the following disclaimer.
10# * Redistributions in binary form must reproduce the above copyright notice,
11# this list of conditions, and the following disclaimer in the
12# documentation and/or other materials provided with the distribution.
13# * Neither the name of the author of this software nor the name of
14# contributors to this software may be used to endorse or promote products
15# derived from this software without specific prior written consent.
16#
17# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
18# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
21# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
22# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
23# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
25# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
26# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
27# POSSIBILITY OF SUCH DAMAGE.
28
29###
30
31import supybot.conf as conf
32import supybot.registry as registry
33try:
34 from supybot.i18n import PluginInternationalization
35 _ = PluginInternationalization('Sigyn')
36except:
37 # Placeholder that allows to run the plugin on a bot
38 # without the i18n module
39 _ = lambda x:x
40
41def configure(advanced):
42 # This will be called by supybot to configure this module. advanced is
43 # a bool that specifies whether the user identified himself as an advanced
44 # user or not. You should effect your configuration by manipulating the
45 # registry as appropriate.
46 from supybot.questions import expect, anything, something, yn
47 conf.registerPlugin('Sigyn', True)
48
49
50Sigyn = conf.registerPlugin('Sigyn')
51
52conf.registerGlobalValue(Sigyn, 'enable',
53 registry.Boolean(False, """set to True to enable kill and klines, otherwise bot will only report to logChannel"""))
54
c22f5ade
NC
55conf.registerGlobalValue(Sigyn, 'mainChannel',
56 registry.String("#freenode","""main channel, where bot stay opped and op staffer on +z"""))
57
70bd3e0c
NC
58conf.registerGlobalValue(Sigyn, 'snoopChannel',
59 registry.String("", """channel where services stuff are announced"""))
60
61conf.registerGlobalValue(Sigyn, 'mxbl',
62 registry.CommaSeparatedListOfStrings([''],"""patterns to match"""))
63
9fd9b4f6
NC
64conf.registerGlobalValue(Sigyn, 'wordsList',
65 registry.CommaSeparatedListOfStrings([''],"""paths of files contains one word per line"""))
a15240d5
NC
66conf.registerGlobalValue(Sigyn, 'wordMinimum',
67 registry.PositiveInteger(4,"""minimum length of words to use for detection"""))
9fd9b4f6 68
21efdd22
NC
69conf.registerGlobalValue(Sigyn, 'minimumUsersInChannel',
70 registry.Integer(-1,"""if /invite enabled, ( see lastActionTaken ), bot will do /list #channel to ensure it has enough users before joining"""))
71
6f7f2f85
NC
72conf.registerGlobalValue(Sigyn, 'logChannel',
73 registry.String("", """channel where bot's actions is announced"""))
74conf.registerGlobalValue(Sigyn, 'useNotice',
75 registry.Boolean(False, """use notices for announces in logChannel"""))
76
b78d8847 77conf.registerGlobalValue(Sigyn,'resolverTimeout',
1d9adcdf 78 registry.PositiveInteger(3, """max duration of dns request/resolve in seconds"""))
b78d8847 79
6f7f2f85
NC
80conf.registerGlobalValue(Sigyn, 'klineDuration',
81 registry.Integer(-1, """kline duration, in minutes, with -1, bot will not kill or kline"""))
82conf.registerGlobalValue(Sigyn, 'klineMessage',
83 registry.String("Please do not spam users or channels on freenode. If in error, please contact kline@freenode.net.", """default reason used in kline's message"""))
06bd28a0 84conf.registerChannelValue(Sigyn, 'killMessage',
6f7f2f85
NC
85 registry.String("Spam is off topic on freenode.", """kill reason"""))
86
87conf.registerGlobalValue(Sigyn, 'operatorNick',
84747938 88 registry.String("", """oper's nick, must be filled""", private=True))
6f7f2f85 89conf.registerGlobalValue(Sigyn, 'operatorPassword',
84747938 90 registry.String("", """oper's password, must be filled""", private=True))
6f7f2f85
NC
91
92conf.registerGlobalValue(Sigyn, 'alertPeriod',
93 registry.PositiveInteger(1,"""interval between 2 alerts of same type in logChannel"""))
94conf.registerGlobalValue(Sigyn, 'netsplitDuration',
95 registry.PositiveInteger(1,"""duration of netsplit ( which disable some protections )"""))
96
97conf.registerGlobalValue(Sigyn, 'alertOnWideKline',
98 registry.Integer(-1,"""alert if a kline hits more than expected users"""))
99
730f1fc2
NC
100conf.registerGlobalValue(Sigyn, 'decloakPermit',
101 registry.Integer(-1,"""-1 to disable, alert in logChannel if limit reached"""))
102conf.registerGlobalValue(Sigyn, 'decloakLife',
103 registry.PositiveInteger(1,"""duration of stored akick add/del in seconds"""))
104
18f102f7
NC
105conf.registerGlobalValue(Sigyn, 'banPermit',
106 registry.Integer(-1, """-1 to disable, number of ban/quiet allowed during banLife"""))
107conf.registerGlobalValue(Sigyn, 'banLife',
108 registry.PositiveInteger(1, """duration of ban computation, used to alert that someone is collecting bans"""))
109
28164a19
NC
110conf.registerGlobalValue(Sigyn, 'lagPermit',
111 registry.Integer(-1, """max lag allowed in seconds, otherwise entering netsplit mode"""))
112conf.registerGlobalValue(Sigyn, 'lagInterval',
87804149 113 registry.PositiveInteger(1, """interval between two check about lag, also used to garbage collect useless items in internal state"""))
28164a19 114
b21941a8
NC
115conf.registerGlobalValue(Sigyn, 'serverFilteringPermit',
116 registry.Integer(-1, """-1 to disable, enable dnsbling and klining when server trigger filtering messages"""))
117conf.registerGlobalValue(Sigyn, 'serverFilteringLife',
118 registry.PositiveInteger(1, """life of message in buffer in seconds"""))
119
8732a8a6
NC
120conf.registerGlobalValue(Sigyn, 'ghostPermit',
121 registry.Integer(-1, """max number of ghost connections allowed"""))
122
5ecb3350
NC
123conf.registerGlobalValue(Sigyn, 'saslPermit',
124 registry.Integer(-1,"""sasl attempts allowed, -1 to disable"""))
125conf.registerGlobalValue(Sigyn, 'saslLife',
126 registry.PositiveInteger(300, """life of messages to keep"""))
127conf.registerGlobalValue(Sigyn, 'saslDuration',
128 registry.PositiveInteger(240, """dline duration in minutes"""))
129conf.registerGlobalValue(Sigyn, 'saslMessage',
130 registry.String("Banned due to too many failed login attempts in a short period, email kline@freenode.net when corrected. Thanks!", """dline message"""))
131
e35a4b0e
NC
132conf.registerChannelValue(Sigyn, 'lastActionTaken',
133 registry.Float(0.0, """store date of last action taken in a channel"""))
eedaff77
NC
134conf.registerChannelValue(Sigyn, 'leaveChannelIfNoActivity',
135 registry.Integer(-1, """leave channel after days of inactivity, -1 to disable"""))
2550c850 136
b888f64b
NC
137conf.registerGlobalValue(Sigyn, 'announcePermit',
138 registry.Integer(-1,"""number of announce permit in logChannel,if triggered the bot will stay quiet for alertPeriod, -1 to disable"""))
139conf.registerGlobalValue(Sigyn, 'announceLife',
140 registry.PositiveInteger(1,"""life of announce in memory (seconds)"""))
141
45ac582a
NC
142conf.registerGlobalValue(Sigyn, 'ipv4AbusePermit',
143 registry.Integer(-1, """check /24 on ipv4 klines made by the bot, -1 to disable, if triggered, announce in logChannel"""))
144conf.registerGlobalValue(Sigyn, 'ipv4AbuseLife',
145 registry.PositiveInteger(1, """life duration of those kline in seconds"""))
6f7f2f85 146
4165a619
NC
147conf.registerGlobalValue(Sigyn, 'useWhoWas',
148 registry.Boolean(False, """use whowas for resolving ip"""))
149
f35897a2
NC
150conf.registerGlobalValue(Sigyn, 'useOperServ',
151 registry.Boolean(False, """use OperServ AKILL instead of KLINE"""))
152
7f2e65ae
NC
153conf.registerGlobalValue(Sigyn,'msgInviteConfirm',
154 registry.String("Your request has been submitted to freenode staff.","""sent to op who requested /invite"""))
155
2842e065 156conf.registerGlobalValue(Sigyn,'msgTooManyGhost',
7f2e65ae
NC
157 registry.String("Banned due to too many connections in a short period, email kline@freenode.net when corrected.","""sent to op who requested /invite"""))
158
159conf.registerGlobalValue(Sigyn,'staffCloak',
f35897a2 160 registry.String("freenode/staff/","""used to identify staffers"""))
7f2e65ae 161
03ed488b
NC
162# to fight some specific spambot
163conf.registerGlobalValue(Sigyn, 'channelCreationPermit',
164 registry.Integer(-1,"""-1 to disable, announce always, kline on defcon"""))
165conf.registerGlobalValue(Sigyn, 'channelCreationLife',
166 registry.PositiveInteger(60, """life of messages to keep"""))
09e2c886
NC
167conf.registerGlobalValue(Sigyn, 'lethalChannels',
168 registry.CommaSeparatedListOfStrings([''],"""patterns to match"""))
03ed488b 169
b888f64b 170# dronebl submit
6f7f2f85 171conf.registerGlobalValue(Sigyn, 'droneblKey',
06bd28a0 172 registry.String("", """dronebl key for rpc calls""", private=True))
6f7f2f85
NC
173conf.registerGlobalValue(Sigyn, 'droneblHost',
174 registry.String("http://dronebl.org/RPC2", """where bot must do rpc calls"""))
f7007307
NC
175conf.registerGlobalValue(Sigyn, 'droneblPatterns',
176 registry.CommaSeparatedListOfStrings([''],"""patterns to match"""))
e4bec0e3
NC
177
178conf.registerGlobalValue(Sigyn, 'secretChannel',
179 registry.String("","""secretChannel"""))
6f7f2f85
NC
180# report
181conf.registerGlobalValue(Sigyn, 'reportChannel',
182 registry.String("","""channel of the instance"""))
b888f64b
NC
183conf.registerGlobalValue(Sigyn, 'reportNicks',
184 registry.CommaSeparatedListOfStrings([''],"""bots nicks"""))
6f7f2f85
NC
185conf.registerGlobalValue(Sigyn, 'reportPermit',
186 registry.Integer(-1,"""number of proxy detected, -1 to disable"""))
187conf.registerGlobalValue(Sigyn, 'reportLife',
188 registry.PositiveInteger(1,"""life duration of proxies, in seconds"""))
189conf.registerGlobalValue(Sigyn, 'defcon',
190 registry.PositiveInteger(1,"""duration of defcon mode in seconds, where bot is more agressive, with lowered abuse triggers and no ignores"""))
191
192# amsg
e6957b3f 193conf.registerGlobalValue(Sigyn, 'amsgMinimum',
6f7f2f85
NC
194 registry.PositiveInteger(1,"""length of text necessary to start amsg check"""))
195conf.registerGlobalValue(Sigyn, 'amsgPermit',
196 registry.Integer(-1,"""number of channels allowed with same message"""))
197conf.registerGlobalValue(Sigyn, 'amsgLife',
198 registry.PositiveInteger(1,"""life of channels in seconds"""))
199conf.registerGlobalValue(Sigyn, 'amsgPercent',
200 registry.Probability(1.00,"""percent of similarity between two messages"""))
201
202# service notices
203
b888f64b
NC
204# user nick changes snote
205conf.registerGlobalValue(Sigyn, 'nickChangePermit',
206 registry.Integer(-1,"""number of server notices (nick changes) allowed for a given period"""))
207conf.registerGlobalValue(Sigyn, 'nickChangeLife',
208 registry.PositiveInteger(1,"""life of notices in seconds"""))
209
6f7f2f85
NC
210# channel flood snote
211conf.registerGlobalValue(Sigyn, 'channelFloodPermit',
212 registry.Integer(-1,"""number of server notices (possible flooder) from various host allowed for a given channel"""))
213conf.registerGlobalValue(Sigyn, 'channelFloodLife',
214 registry.PositiveInteger(1,"""life of notices in seconds"""))
215
216# user flood snote
217conf.registerGlobalValue(Sigyn, 'userFloodPermit',
218 registry.Integer(-1,"""number of snotes about flood targeted a given user with differents hosts"""))
219conf.registerGlobalValue(Sigyn, 'userFloodLife',
220 registry.PositiveInteger(1,"""life of notices in seconds"""))
221
222# join/spam snote
223conf.registerGlobalValue(Sigyn, 'joinRatePermit',
224 registry.Integer(-1,"""number of snotes about join floodfor a given channel with differents users"""))
225conf.registerGlobalValue(Sigyn, 'joinRateLife',
226 registry.PositiveInteger(1,"""life of notices in seconds"""))
227
68303e96
NC
228conf.registerGlobalValue(Sigyn, 'crawlPermit',
229 registry.Integer(-1,"""number of snotes about join floodfor a given channel with differents users"""))
230conf.registerGlobalValue(Sigyn, 'crawlLife',
231 registry.PositiveInteger(1,"""life of notices in seconds"""))
232
6f7f2f85 233# NickServ ID failures
6f7f2f85
NC
234conf.registerGlobalValue(Sigyn, 'idPermit',
235 registry.Integer(-1,"""number of snotes about id failure from a given user and different account"""))
236conf.registerGlobalValue(Sigyn, 'idLife',
237 registry.PositiveInteger(1,"""life duration of message in those snote"""))
238
03ed488b
NC
239conf.registerGlobalValue(Sigyn, 'registerPermit',
240 registry.Integer(-1,"""number of register allowed per ip during registerLife"""))
241conf.registerGlobalValue(Sigyn, 'registerLife',
242 registry.PositiveInteger(1,"""life of notices in seconds"""))
243
c27f7c2a 244# change modes on defcon
47e9a74a
NC
245conf.registerChannelValue(Sigyn, 'defconMode',
246 registry.Boolean(False,"""changes +qz $~a -qz $~a on defcon"""))
247
54deeac6
NC
248# unicode exploits
249conf.registerChannelValue(Sigyn, 'badunicodeLimit',
250 registry.Integer(-1,"""score of message with bad unicode limit"""))
251conf.registerChannelValue(Sigyn, 'badunicodePermit',
252 registry.Integer(-1,"""number bad unicode message allowed"""))
253conf.registerChannelValue(Sigyn, 'badunicodeLife',
254 registry.PositiveInteger(1,"""life of bad unicode message"""))
e6957b3f
NC
255conf.registerChannelValue(Sigyn, 'badunicodeScore',
256 registry.PositiveInteger(1,"""score of message to trigger limit"""))
54deeac6 257
6f7f2f85
NC
258# Quit flood
259conf.registerChannelValue(Sigyn, 'brokenPermit',
260 registry.Integer(-1,"""number of quit allowed"""))
261conf.registerChannelValue(Sigyn, 'brokenLife',
262 registry.PositiveInteger(1,"""life duration of buffer for broken client detection"""))
263conf.registerChannelValue(Sigyn, 'brokenDuration',
264 registry.PositiveInteger(1,"""kline duration in minutes"""))
265conf.registerChannelValue(Sigyn, 'brokenReason',
266 registry.String("Your irc client seems broken and is flooding lots of channels. Banned for %s min, if in error, please contact kline@freenode.net.","""kline reason"""))
267conf.registerChannelValue(Sigyn, 'brokenHost',
268 registry.CommaSeparatedListOfStrings([''], """list of knowns broken host"""))
269
c27f7c2a 270# ignores feature
54deeac6
NC
271conf.registerChannelValue(Sigyn, 'ignoreRegisteredUser',
272 registry.Boolean(False, """ignore registered users in the channel"""))
6f7f2f85
NC
273conf.registerChannelValue(Sigyn, 'ignoreChannel',
274 registry.Boolean(False, """ignore everything in the channel"""))
8a5d024b
NC
275conf.registerChannelValue(Sigyn, 'ignoreVoicedUser',
276 registry.Boolean(False, """ignore voiced users in the channel"""))
6f7f2f85
NC
277conf.registerChannelValue(Sigyn, 'ignoreDuration',
278 registry.Integer(-1, """in secondes: if -1 disabled, otherwise bot ignores user's privmsg/notices after <seconds> in channel"""))
279
280# abuses lowered thresold for given channel and a given abuse, and lift ignores
281conf.registerChannelValue(Sigyn, 'abusePermit',
8895121b 282 registry.Integer(-1,"""-1 to disable, reduces threshold of triggers when they occurs more than abusePermit during abuseLife"""))
6f7f2f85
NC
283conf.registerChannelValue(Sigyn, 'abuseLife',
284 registry.PositiveInteger(1,"""life duration of message in the buffer detection, in seconds"""))
285conf.registerChannelValue(Sigyn, 'abuseDuration',
286 registry.PositiveInteger(1,"""duration in seconds of abuse state"""))
287
288# ignored users can still trigger klines if desired
289conf.registerChannelValue(Sigyn, 'bypassIgnorePermit',
290 registry.Integer(-1,"""number of triggers allowed while ignored, -1 to disable"""))
291conf.registerChannelValue(Sigyn, 'bypassIgnoreLife',
292 registry.PositiveInteger(1,"""in seconds"""))
293
294# channel protections
c27f7c2a
NC
295conf.registerChannelValue(Sigyn, 'clearTmpPatternOnUnkline',
296 registry.Boolean(False, """clean channel's temporary patterns on unkline requested by channel's op"""))
297
70bd3e0c 298conf.registerChannelValue(Sigyn, 'massJoinPermit',
c27f7c2a 299 registry.Integer(-1,"""number of joins allowed during massJoinLife, -1 to disable"""))
70bd3e0c 300conf.registerChannelValue(Sigyn, 'massJoinLife',
c27f7c2a
NC
301 registry.PositiveInteger(1,"""life duration of messages in the massJoin detection"""))
302
303conf.registerChannelValue(Sigyn, 'massJoinNickPermit',
304 registry.Integer(-1,"""number of smiliar nick joins allowed during massJoinNickLife, -1 to disable"""))
305conf.registerChannelValue(Sigyn, 'massJoinNickLife',
306 registry.PositiveInteger(1,"""life duration of messages in the massJoinNick detection"""))
307
308conf.registerChannelValue(Sigyn, 'massJoinHostPermit',
309 registry.Integer(-1,"""number of smiliar host joins allowed during massJoinHostLife, -1 to disable"""))
310conf.registerChannelValue(Sigyn, 'massJoinHostLife',
311 registry.PositiveInteger(1,"""life duration of messages in the massJoinHost detection"""))
312
313conf.registerChannelValue(Sigyn, 'massJoinGecosPermit',
314 registry.Integer(-1,"""number of smiliar gecos joins allowed during massJoinGecosLife, -1 to disable"""))
315conf.registerChannelValue(Sigyn, 'massJoinGecosLife',
316 registry.PositiveInteger(1,"""life duration of messages in the massJoinGecos detection"""))
317
70bd3e0c 318conf.registerChannelValue(Sigyn, 'massJoinPercent',
c27f7c2a 319 registry.Probability(1.00,"""percent of similarity between two pattern ( for nicks and gecos )"""))
70bd3e0c 320conf.registerChannelValue(Sigyn, 'massJoinMinimum',
c27f7c2a
NC
321 registry.PositiveInteger(1,"""length of pattern to match as least"""))
322
323conf.registerChannelValue(Sigyn, 'massJoinTakeAction',
324 registry.Boolean(False, """takes actions against massJoin found hosts/gecos/nicks"""))
70bd3e0c 325
6f7f2f85
NC
326conf.registerChannelValue(Sigyn, 'floodPermit',
327 registry.Integer(-1,"""number of messages allowed during floodLife, -1 to disable"""))
328conf.registerChannelValue(Sigyn, 'floodLife',
329 registry.PositiveInteger(1,"""life duration of message in the flood buffer detection"""))
330conf.registerChannelValue(Sigyn, 'floodMinimum',
331 registry.PositiveInteger(1,"""minimun number of chars to enter flood detection"""))
332
333conf.registerChannelValue(Sigyn, 'lowFloodPermit',
334 registry.Integer(-1,"""number of messages allowed during lowFoodLife, -1 to disable"""))
335conf.registerChannelValue(Sigyn, 'lowFloodLife',
336 registry.PositiveInteger(1,"""life duration of message in the lowFlood buffer detection"""))
337
645a036d
NC
338conf.registerChannelValue(Sigyn, 'capPermit',
339 registry.Integer(-1,"""number of uppercase messages allowed, -1 to disable"""))
340conf.registerChannelValue(Sigyn, 'capLife',
341 registry.PositiveInteger(1,"""life duration of message in the uppercase buffer detection"""))
342conf.registerChannelValue(Sigyn, 'capPercent',
343 registry.PositiveInteger(80,"""percent of the message in uppercase"""))
344conf.registerChannelValue(Sigyn, 'capMinimum',
345 registry.PositiveInteger(1,"""minimun number of chars to enter cap detection"""))
346
6f7f2f85 347conf.registerChannelValue(Sigyn, 'repeatPermit',
c56a3fc6 348 registry.Integer(-1,"""number of repeated trigger allowed during repeatLife, -1 to disable"""))
6f7f2f85
NC
349conf.registerChannelValue(Sigyn, 'repeatLife',
350 registry.PositiveInteger(1,"""life duration of message in the repeat buffer detection"""))
351conf.registerChannelValue(Sigyn, 'repeatPercent',
c56a3fc6 352 registry.Probability(1.00,"""percent of similarity between two pattern to trigger repeat detection"""))
6f7f2f85 353conf.registerChannelValue(Sigyn, 'repeatCount',
c56a3fc6
NC
354 registry.PositiveInteger(1,"""if pattern is smaller than computedPattern, bot may still add it anyway, if occured more than repeatCount"""))
355conf.registerChannelValue(Sigyn, 'repeatMinimum',
6f7f2f85
NC
356 registry.PositiveInteger(1,"""minimal length of a pattern, in that case, the pattern must be repeated more than at least repeatCount in the message"""))
357
358conf.registerChannelValue(Sigyn, 'lowRepeatPermit',
c56a3fc6 359 registry.Integer(-1,"""number of repeated messages allowed during lowrepeatLife, -1 to disable"""))
6f7f2f85 360conf.registerChannelValue(Sigyn, 'lowRepeatLife',
c56a3fc6 361 registry.PositiveInteger(1,"""life duration of message in the lowrepeat buffer detection"""))
6f7f2f85 362conf.registerChannelValue(Sigyn, 'lowRepeatPercent',
c56a3fc6
NC
363 registry.Probability(1.00,"""percent of similarity between two messages to trigger lowrepeat detection"""))
364conf.registerChannelValue(Sigyn, 'lowRepeatCount',
365 registry.PositiveInteger(1,"""keep this value to 1, this settings only exist because repeat and lowrepeat use nearly the same code"""))
6f7f2f85 366conf.registerChannelValue(Sigyn, 'lowRepeatMinimum',
c56a3fc6 367 registry.PositiveInteger(1,"""minimun number of chars to enter lowRepeat detection"""))
6f7f2f85
NC
368
369conf.registerChannelValue(Sigyn, 'massRepeatPermit',
370 registry.Integer(-1,"""number of mass repeat permit duration massRepeatLife, -1 to disable"""))
371conf.registerChannelValue(Sigyn, 'massRepeatLife',
372 registry.PositiveInteger(1,"""Duration of messages's life in massRepeat counter, in seconds"""))
373conf.registerChannelValue(Sigyn, 'massRepeatPercent',
374 registry.Probability(1.00,"""percentage similarity between previous and current message to trigger a massRepeat count"""))
375conf.registerChannelValue(Sigyn, 'massRepeatMinimum',
8895121b 376 registry.PositiveInteger(1,"""minimum number of chars to enter massRepeat detection"""))
6f7f2f85 377
730f1fc2
NC
378conf.registerChannelValue(Sigyn, 'joinSpamPartPermit',
379 registry.Integer(-1,"""number of messages before leaving channel, -1 to disable"""))
380conf.registerChannelValue(Sigyn, 'joinSpamPartLife',
381 registry.PositiveInteger(1,"""duration in seconds of user presence in channel"""))
382
645a036d
NC
383
384
6f7f2f85 385conf.registerChannelValue(Sigyn, 'computedPattern',
8895121b 386 registry.Integer(-1,"""minimun number of chars needed to keep it as a spam pattern, -1 to disable"""))
6f7f2f85 387conf.registerChannelValue(Sigyn, 'computedPatternLife',
8895121b 388 registry.PositiveInteger(1,"""life in seconds of computed pattern"""))
2f79d105
NC
389conf.registerChannelValue(Sigyn, 'shareComputedPatternID',
390 registry.Integer(-1,"""share the temporary pattern created to all channels with the same number, -1 to disable"""))
391
6f7f2f85
NC
392conf.registerChannelValue(Sigyn, 'lowMassRepeatPermit',
393 registry.Integer(-1,"""number of mass repeat permit duration massRepeatLife, -1 to disable"""))
394conf.registerChannelValue(Sigyn, 'lowMassRepeatLife',
395 registry.PositiveInteger(1,"""Duration of messages's life in massRepeat counter, in seconds"""))
396conf.registerChannelValue(Sigyn, 'lowMassRepeatPercent',
397 registry.Probability(1.00,"""percentage similarity between previous and current message to trigger a massRepeat count"""))
398conf.registerChannelValue(Sigyn, 'lowMassRepeatMinimum',
399 registry.PositiveInteger(1,"""minimun number of chars to enter massRepeat detection"""))
400
401conf.registerChannelValue(Sigyn, 'hilightNick',
402 registry.Integer(-1,"""number nick allowed per message, -1 to disable"""))
403conf.registerChannelValue(Sigyn, 'hilightPermit',
404 registry.Integer(-1,"""number of hilight detection allowed during hilightLife, -1 to disable"""))
405conf.registerChannelValue(Sigyn, 'hilightLife',
406 registry.PositiveInteger(1,"""life duration of hilight buffer"""))
407
408conf.registerChannelValue(Sigyn, 'lowHilightNick',
409 registry.Integer(-1,"""number nick allowed per message, -1 to disable"""))
410conf.registerChannelValue(Sigyn, 'lowHilightPermit',
411 registry.Integer(-1,"""number of hilight detection allowed during hilightLife, -1 to disable"""))
412conf.registerChannelValue(Sigyn, 'lowHilightLife',
413 registry.PositiveInteger(1,"""life duration of hilight buffer"""))
414
415conf.registerChannelValue(Sigyn, 'cyclePermit',
416 registry.Integer(-1,"""number of cycle allowed during cycleLife"""))
417conf.registerChannelValue(Sigyn, 'cycleLife',
418 registry.PositiveInteger(1,"""life duration of part/quit in the cycle buffer detection"""))
419
420conf.registerChannelValue(Sigyn, 'ctcpPermit',
421 registry.Integer(-1,"""number of channel's ctcp allowed"""))
422conf.registerChannelValue(Sigyn, 'ctcpLife',
c27f7c2a
NC
423 registry.PositiveInteger(1,"""life duration of channel's ctcp buffer detection"""))
424
425conf.registerChannelValue(Sigyn, 'noticePermit',
426 registry.Integer(-1,"""number of channel's notice allowed"""))
427conf.registerChannelValue(Sigyn, 'noticeLife',
428 registry.PositiveInteger(1,"""life duration of channel's notice buffer detection"""))
6f7f2f85
NC
429
430conf.registerChannelValue(Sigyn, 'nickPermit',
431 registry.Integer(-1,"""number of nick change allowed during cycleLife"""))
432conf.registerChannelValue(Sigyn, 'nickLife',
433 registry.PositiveInteger(1,"""life duration of nick changes buffer detection"""))
54deeac6 434