This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

AllProtection.tcl (Stable: v4.8 / Beta: v4.9b4)

Support & discussion of released scripts, and announcements of new releases.
Post Reply
i
i.m.offline
Halfop
Posts: 74
Joined: Thu Mar 02, 2006 11:47 am

Post by i.m.offline »

Am sorry for late response sir_fz but suddenly it seems to be working fine and I dont see any error on partyline. Thanks for your response. Take care. Gr8 work.
s
sharktooth
Voice
Posts: 1
Joined: Sat Mar 25, 2006 8:19 am

Problem when compiling

Post by sharktooth »

Thanks for such a nice script. It has almost everything a channel owner might want. There was a little problem when I tried to compile the script:
invalid type. Must be one of: flag, int
while executing
"setudef str ap:textl"
(file "scripts/allprotection4.5.tcl" line 1375)
invoked from within
"source scripts/allprotection4.5.tcl"
thats what I get in my cmd window. Since its the code section, I have no clue what needs to be done. So, please reply me with a solution to fix the problem.

Thanks
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Upgrade to eggdrop1.6.17.
E
ERNEST
Voice
Posts: 2
Joined: Mon Mar 27, 2006 10:33 am

Post by ERNEST »

[17:31:14] <uMnoTeHTeH> [17:31] All Protection v4.5 by Opposing Loaded...
[17:31:14] <uMnoTeHTeH> [17:31] Userfile loaded, unpacking...
[17:31:20] <ERNEST> .set errorInfo
[17:31:20] <uMnoTeHTeH> [17:31] #ERNEST# set errorInfo
[17:31:20] <uMnoTeHTeH> Currently: no such binding
[17:31:20] <uMnoTeHTeH> Currently: while executing
[17:31:20] <uMnoTeHTeH> Currently: "unbind $foo1 $foo2 $foo3 $foo4 "
[17:31:34] <uMnoTeHTeH> [17:32] Tcl error [caps:kick]: can't read "p": no such variable
[17:31:34] <uMnoTeHTeH> [17:32] Tcl error [text:char]: can't read "o": no such variable
[17:31:34] <uMnoTeHTeH> [17:32] Tcl error [text:line]: can't read "o": no such variable
[17:31:37] <ERNEST> .set errorInfo
[17:31:37] <uMnoTeHTeH> [17:32] #ERNEST# set errorInfo
[17:31:37] <uMnoTeHTeH> Currently: can't read "o": no such variable
[17:31:37] <uMnoTeHTeH> Currently: while executing
[17:31:37] <uMnoTeHTeH> Currently: "invalid:apf $o $s"
[17:31:37] <uMnoTeHTeH> Currently: (procedure "text:line" line 4)
[17:31:37] <uMnoTeHTeH> Currently: invoked from within
[17:31:37] <uMnoTeHTeH> Currently: "text:line $_pubm1 $_pubm2 $_pubm3 $_pubm4 $_pubm5"
[17:33:48] <uMnoTeHTeH> [17:34] Tcl error [bjoinf:lock]: can't read "o": no such variable
[17:33:49] <uMnoTeHTeH> [17:34] Tcl error [cjoin:kick]: can't read "j": no such variable
[17:34:00] <ERNEST> .set errorInfo
[17:34:00] <uMnoTeHTeH> [17:34] #ERNEST# set errorInfo
[17:34:00] <uMnoTeHTeH> Currently: can't read "j": no such variable
[17:34:00] <uMnoTeHTeH> Currently: while executing
[17:34:00] <uMnoTeHTeH> Currently: "invalid:apf $j $s"
[17:34:00] <uMnoTeHTeH> Currently: (procedure "cjoin:kick" line 6)
[17:34:00] <uMnoTeHTeH> Currently: invoked from within
[17:34:00] <uMnoTeHTeH> Currently: "cjoin:kick $_jp1 $_jp2 $_jp3 $_jp4"
It seems that the tcl cann`t find a variable
Please help :)
PS: I am uMnoTeHTeH, running eggdrop v1.6.17
---------
Welcome to the UniBG Internet Relay Chat Network ERNEST
Your host is irc.telecoms.bg[irc.telecoms.bg/9001], running version ircd-ratbox+UniBG-v2.2
This server was created Wed Jan 11 2006 at 09:34:32 UTC
irc.telecoms.bg ircd-ratbox+UniBG-v2.2 oiwszcerkfydnxbauglZCD biklmnopstveI bkloveI
CHANTYPES=&# EXCEPTS INVEX CHANMODES=eIb,k,l,imnpst CHANLIMIT=&#:20 PREFIX=(ov)@+ MAXLIST=beI:150 NETWORK=UniBG MODES=4 STATUSMSG=@+ KNOCK CALLERID=g are supported by this server
SAFELIST ELIST=U CASEMAPPING=rfc1459 CHARSET=ascii NICKLEN=15 CHANNELLEN=100 TOPICLEN=390 ETRACE CPRIVMSG CNOTICE DEAF=D MONITOR=50 are supported by this server
TARGMAX=NAMES:1,LIST:1,KICK:1,WHOIS:1,PRIVMSG:4,NOTICE:4,ACCEPT:,MONITOR: are supported by this server
-
Last edited by ERNEST on Mon Mar 27, 2006 11:37 am, edited 1 time in total.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Either .restart or apply .ap:reset <#chan> on all channels. This issue will be fixed in v4.6. (I notice people don't like to .restart :P )
C
Craig
Voice
Posts: 18
Joined: Wed Feb 22, 2006 2:18 pm

Post by Craig »

i have other idea to take only letters fllod now it work..


but i want: "ththththththt" , " shshshshshshs" and other will kicking too!
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Craig wrote:i have other idea to take only letters fllod now it work..


but i want: "ththththththt" , " shshshshshshs" and other will kicking too!
In my opinion that's useless, even the letter repeats protection is not needed that much.
User avatar
De Kus
Revered One
Posts: 1361
Joined: Sun Dec 15, 2002 11:41 am
Location: Germany

Post by De Kus »

I considered making one, but dropped the idea, because even single letter repeatance would be as complex as '(?i)(a{5,}|b{5,}|c{5,}|...|z{5,})'
and therefore be too much CPU time for parsing a single line. Remember, a [a-z]{5,} would not only match "aaaaa" but also "mouse" :D. Alternately you would have to count each letter and say like only x % are allowed per letter and line. A good protection script must also consider CPU time, since excess flood might be used to timeout the bot by just the CPU time it consumes :D. If you run your bot on your own machine, you might not have to worry about it, but many shells have very limited CPU ressources per user.

however, you could consider using looking for repeated vocals like in "loooooooooooooooool".
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
User avatar
demond
Revered One
Posts: 3073
Joined: Sat Jun 12, 2004 9:58 am
Location: San Francisco, CA
Contact:

Post by demond »

De Kus wrote:I considered making one, but dropped the idea, because even single letter repeatance would be as complex as '(?i)(a{5,}|b{5,}|c{5,}|...|z{5,})'
and therefore be too much CPU time for parsing a single line. Remember, a [a-z]{5,} would not only match "aaaaa" but also "mouse" :D. Alternately you would have to count each letter and say like only x % are allowed per letter and line. A good protection script must also consider CPU time, since excess flood might be used to timeout the bot by just the CPU time it consumes :D. If you run your bot on your own machine, you might not have to worry about it, but many shells have very limited CPU ressources per user.

however, you could consider using looking for repeated vocals like in "loooooooooooooooool".
you have considered the wrong idea

it's trivial to detect repeating patterns (with sufficient precision) in a string without using regexps, and without clogging the CPU
connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use

Code: Select all

 tag when posting logs, code
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

A for loop and a string repeat will do the job, it's already implemented in AP.
User avatar
De Kus
Revered One
Posts: 1361
Joined: Sun Dec 15, 2002 11:41 am
Location: Germany

Post by De Kus »

demond wrote:you have considered the wrong idea

it's trivial to detect repeating patterns (with sufficient precision) in a string without using regexps, and without clogging the CPU
Sure that
[string match -nocase *aaaaa* $line] || [string match -nocase *bbbbb* $line] || [string match -nocase *ccccc* $line] || ... || [string match -nocase *zzzzz* $line]
would be significantly faster? Or what were you thinking of?

Though I am still the opionion that these "non critical" spams should be rather a matter of human moderation :).
Last edited by De Kus on Tue May 09, 2006 12:39 pm, edited 2 times in total.
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

I've done it like this:

Code: Select all

set i 30 ; # number of repeated letters
set cl "abcdefghijklmnopqrstuvwxyz0123456789!@#$%^&"
for {set c 0} {$c < [string length $cl]} {incr c} {
 if {[string match -nocase *[string repeat [string index $cl $c] $i]* $arg]} {
  # offense detected.
 }
}
User avatar
De Kus
Revered One
Posts: 1361
Joined: Sun Dec 15, 2002 11:41 am
Location: Germany

Post by De Kus »

so the string match thing is basicly what Fz already did ^-^.

btw. for some languages like German addional letters like the 3 umlaute (äöü) in German are likely to be used repeatedly. I doubt the ss (ß) would be often used for something like that (and could be trapped by mapping ß -> ss).
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Ok, I've been working on a new version of AllProtection but I'm finding less time to complete it. So I decided to release the beta version of v4.6 (v4.6b4). Some of the new features are:
  • New and improved DCC commands:
    .ap:import <oldchan> <*/newchan> (This sets the AP settings of <oldchan> on <newchan> or all chans if *)
    .ap:reset <*/chan> (This will reset the AP settings of chan or all chans if * to the default settings)
    .ap:disable <*/chan> (This will disable all protections on chan or all chans if *)
    .ap:monitor (displays info about followed punishments)
    .ap:add <list> <chan/global> <elements>
    .ap:rem <list> <chan/global> <elements>
    .ap:list <list> <chan/global>
    ** Available lists: bchans, bnicks, bidents, bwords & adexempts.
  • New botnet flood protection: mass codes flooding (notice/text).
  • Exempted words can be added which will not be considered as advertising (via DCC).
  • Enhanced dynamic chansettings, for example:
    .chanset #chan ap:<type> <value> <btime> <punishment> <btype>
    .chanset #chan ap:textl 5:2 30 w:k:kb 2
  • Namespace implementation to avoid variable collision with other scripts.
  • No .restart required anymore for installation, the script will set everything on load.
  • Bad chan protection (bad chans can be added via DCC for every channel)
  • Remove x bans on full banlist.
  • Queue implementation, you can set a queue (in seconds) which will allow setting several bans in one command (i.e. +bbbbb) very usefull during mass floods. (can be disabled)
  • Code structure very different and a lot, many many, bugs fixed and enhancements done.
Probably there's much more but I've forgotten (progress is slow from a fix to another).

I guarantee that this version is 100% bug-free. It has been loaded on my eggdrop for a while now, and I haven't noticed any Tcl error yet. Enjoy.

AllProtection4.6b4.zip.
S
Smurff
Voice
Posts: 7
Joined: Wed Feb 09, 2005 6:31 pm

some error

Post by Smurff »

made new bot (eggdrop1.6.17) with allprotection4.6b4.tcl
did .+chan #bot2
after doing all channel settings for AFP i did .rehash the bot gives following error. it leaves the channel. (there are no other tcls running excpt with allprotection4.6b4.tcl )

[23:20] <(bot2> Tcl error in file 'bot2.chan':
[23:20] <(bot2> while executing
[23:20] <(bot2> "channel add #bot2 { chanmode +tn idle-kick 0 stopnethack-mode 0 revenge-mode 0 need-op {} need-invite {} need-key {} need-unban {} need-limit {} fl..."
[23:20] <(bot2> (file "bot2.chan" line 3)
[23:20] <(bot2> Creating channel file
[23:20] <(bot2> No longer supporting channel #bot2
[23:20] <(bot2> Ignored masks for channel(s): #bot2
[23:20] <(bot2> Userfile loaded, unpacking...
Post Reply