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
Ikaa
Voice
Posts: 7
Joined: Wed Dec 17, 2008 3:46 pm

Post by Ikaa »

Having some difficulty on the newest version 4.6b9 with the swear filter. The aplists file shows the phrase input both global and channel, but it doesnt seem to recognize it in when typed in the channel.

Tried reloading the default badwords and deleting the aplists file to make sure theyre input correctly, and they are now, but it still seems to fail to recognize the words.

Is it perhaps because i'm trying to use a 2 word phrase, and not a single word? It worked in 4.5, so I dont think thats the issue.

aplists bword line looks like this now -

Code: Select all

bwords global *word1 word2* "*word3 word4 *"
and chaninfo ap setting is

Code: Select all

ap:swear: {+ 15 k:kb 2}
so its on.. any ideas?

*Edit* Ah hah.. I figured it out.. the space at the end of the second phrase ("*word3 word4 *") wasnt recognizing the phrase if it came at the end of an unclosed sentence, or had punctuation right after it, as it didnt find the space at the end.. silly me.
L
Lupo
Voice
Posts: 17
Joined: Sat Dec 20, 2008 7:10 pm

Post by Lupo »

Sir_Fz wrote: This error can't happen with version 4.6b9 since it does not contain a procedure called adv:kick. Upgrading to the latest version will solve your problem. If you still want to fix it in version 4.5 then please paste the output of '.set errorInfo'
Maybe not, but i got a similar error :

Tcl error [swear:kick]: expected integer but got ""

whenever i try .set errorInfo, i get "What? You need .help" in my console.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Again, swear:kick is a proc from version 4.5 and not 4.6*. Please make sure you .restart the bot when loading the new version and not just .rehash.

Read here about how to enable the .set command.
L
Lupo
Voice
Posts: 17
Joined: Sat Dec 20, 2008 7:10 pm

Post by Lupo »

Sir_Fz wrote:Again, swear:kick is a proc from version 4.5 and not 4.6*. Please make sure you .restart the bot when loading the new version and not just .rehash.

Read here about how to enable the .set command.
My bad, thanks for your patience. :) I took my bot down and got rid of the .chan file and rebooted it and it works now like it should.

one remark/question : the bot seemed to react to http:// ftp:// # even when it was not defined in the advertizing list. I took out some parts of proc isspam. I would expect that stuff to be in adwords(global) like it was with 4.5... Any reason why you moved it there?
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Those are the general advertisement words so I set them as built-in in the script. However you can add masks to the adexempts list if you wish to exempt any particular site or word (e.g. if you add "www." in the adexempts list, it won't be detected as advertisement anymore).
L
Lupo
Voice
Posts: 17
Joined: Sat Dec 20, 2008 7:10 pm

Post by Lupo »

i took it out but its still punishing on people saying "join". For some reason excluding it doesn't work either. On top of that, I cant find where this is defined it is so i cant remove it. :cry:

"Warning: You've triggered adverting protection, advertisements are not allowed."

Where is this trigger defined so i can take it out?? It doesn't make any sense that this is hard coded into the script.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

"join" is not hard-coded in the script; if the protection is being triggered on saying "join" then you probably added it in your advlist(s).

The warning message can be edited using this setting in the script:
set adv(wmsg) "Warning: You've triggered adverting protection, advertisements are not allowed."
However, it's only sent to the offender when "w" is specified in the punishment method (which is edited via .chanset <chan> ap:adv +/- <btime> <punishment> <btype>).
L
Lupo
Voice
Posts: 17
Joined: Sat Dec 20, 2008 7:10 pm

Post by Lupo »

Sir_Fz wrote:"join" is not hard-coded in the script; if the protection is being triggered on saying "join" then you probably added it in your advlist(s).
Its not in the adwords(global) list, and i'm not using any other advertizing scripts. I also defined it like this :

set adexempts(global) { %chan join }

Its triggering when i type something like "join my crew" but not when i type join.
However, it's only sent to the offender when "w" is specified in the punishment method (which is edited via .chanset <chan> ap:adv +/- <btime> <punishment> <btype>).
I have set it to warn then kickban. But with it reacting on a simple word like join it renders the whole advertizing section useless.

EDIT : I found the issue. Apparantly adwords(global) serves as a template for scripts/aplists, so i had to flush that file for my changes to take effect.

For the rest, good work on the script :) I like the new w:k:kb format a lot, its a lot more flexible from the previous format.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

You don't need to flush the aplists file to make changes to the adwords lists. Any editing of the lists should be only done using the .ap:add/ap:rem commands. Note that when you have a channel-specific list, the script ignores the global list - For example, if you have adwords(#temp) then the script will use this list *only* (without adwords(global)) on #temp.
w
willyw
Revered One
Posts: 1204
Joined: Thu Jan 15, 2009 12:55 am

character repeating

Post by willyw »

Hello,

Just getting familiar with Allprotection.

This is about character repeating.

With a test setup, it seems that AP will not trigger on repeated question marks. It does trigger on repeated exclamation points though.

Same for repeated periods... no trigger.

Is there something I've overlooked? We have a 'help' channel, and it is not completely unusual to get the "What's wrong???????" channel message, and that's why I tested it.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

At line 1368 you'll find:

Code: Select all

set cl "abcdefghijklmnopqrstuvwxyz0123456789!@#$%^&"
add "." and "?" to that string, and replace the line at 1370:

Code: Select all

if {[string match -nocase *[string repeat [string index $cl $c] $i]* $arg]} {
with

Code: Select all

if {[string match -nocase *[string map {? \\?} [string repeat [string index $cl $c] $i]]* $arg]} {
w
willyw
Revered One
Posts: 1204
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

Sir_Fz wrote:At line 1368 you'll find:

Code: Select all

set cl "abcdefghijklmnopqrstuvwxyz0123456789!@#$%^&"
add "." and "?" to that string, and replace the line at 1370:

Code: Select all

if {[string match -nocase *[string repeat [string index $cl $c] $i]* $arg]} {
with

Code: Select all

if {[string match -nocase *[string map {? \\?} [string repeat [string index $cl $c] $i]]* $arg]} {

Just wanted to acknowledge your reply. Have not yet tried it, as the bot computer is down for some hw changes, etc. Hopefully not for long, and I'll be able to try this when we get it back online.

Thank you.
w
willyw
Revered One
Posts: 1204
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

Sir_Fz:

Have just now made the edits, as per your above.

Only briefly tested, but it seems to work. :) Thank you!

Hopefully there will be no unexpected effects.


Forgot to mention (sorry!) that we are using AP v.4.5 , because I found it here: http://www.egghelp.org/tclhtml/3478-4-0 ... ection.htm


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

Post by Sir_Fz »

I'm glad it worked. Try the newest version, it's much more better.
A
Ark
Voice
Posts: 3
Joined: Fri Jan 30, 2009 11:30 pm

Post by Ark »

hi Sir_Fz

i would like to know how i can reactivate the protection system if i use .ap:disable

and if i will lost settings if i use .ap:disable

thks for all protection script, really good work :)
Post Reply