| View previous topic :: View next topic |
| Author |
Message |
BlackDragon Voice
Joined: 09 Sep 2005 Posts: 15 Location: Greece - Salonika
|
Posted: Wed Mar 21, 2012 11:49 am Post subject: |
|
|
| also... ap:adv doesn't work ok... ! in the words in conf is the http:// but when i set an adword excempt like http://www.youtube.com it still kickbans the offender ! |
|
| Back to top |
|
 |
Lucifer Voice
Joined: 01 Nov 2006 Posts: 17
|
Posted: Thu May 03, 2012 12:20 pm Post subject: Crashing |
|
|
[19:16] <(FreeBSD> [16:15:43] AllProtection v4.7 by Opposing Loaded...
[19:16] <(FreeBSD> [16:15:43] Trying server irc.dal.net:6667
[19:16] <(FreeBSD> [16:15:43] * Last context: tclhash.c/721 []
[19:16] <(FreeBSD> [16:15:43] * Please REPORT this BUG!
[19:16] <(FreeBSD> [16:15:43] * Check doc/BUG-REPORT on how to do so.
[19:16] <(FreeBSD> [16:15:43] * Wrote DEBUG
[19:16] <(FreeBSD> [16:15:43] * SEGMENT VIOLATION -- CRASHING! |
|
| Back to top |
|
 |
aleepervaiz Voice
Joined: 18 Apr 2012 Posts: 10 Location: Pakistan
|
Posted: Tue May 29, 2012 10:48 pm Post subject: dynamicbans |
|
|
my setting for dynamicbans is not working with allprotection, even i have set -dynamicbans on channel setting ..... but my bot wont stop unbaning ips/users which i ban on channel ....
[07:30] <xyz> .chaninfo #fungame
[07:30] <(cracker> Settings for dynamic channel #fungame:
[07:30] <(cracker> Protect modes (chanmode): +tn
[07:30] <(cracker> Idle Kick after (idle-kick): DON'T!
[07:30] <(cracker> stopnethack: DON'T!
[07:30] <(cracker> aop-delay: 5:30
[07:30] <(cracker> revenge-mode: 0
[07:30] <(cracker> ban-type: 3
[07:30] <(cracker> ban-time: 150
[07:30] <(cracker> exempt-time: 60
[07:30] <(cracker> invite-time: 60
[07:30] <(cracker> Other modes:
[07:30] <(cracker> -inactive +statuslog -secret +shared
[07:30] <(cracker> +greet +seen +cycle +dontkickops
[07:30] <(cracker> +protectops -protectfriends -revenge -revengebot
[07:30] <(cracker> -bitch -autoop -autovoice -nodesynch
[07:30] <(cracker> -enforcebans -dynamicbans +userbans -autohalfop
[07:30] <(cracker> -protecthalfops -static
[07:30] <(cracker> +dynamicexempts +userexempts +dynamicinvites +userinvites
[07:30] <(cracker> User defined channel flags:
[07:30] <(cracker> -ping
[07:30] <(cracker> User defined channel strings:
[07:30] <(cracker> ap:textl: {5:2 60 k:kb 2}
[07:30] <(cracker> ap:textc: {350:3 120 kb 2}
[07:30] <(cracker> ap:notcl: {1:3 120 kb 4}
[07:30] <(cracker> ap:notcc: {200:3 180 kb 4}
[07:30] <(cracker> ap:caps: {60:90 120 w:k:kb 2}
[07:30] <(cracker> ap:repeatl: {3:5 60 k:kb 2}
[07:30] <(cracker> ap:repeatc: {25 30 k:kb 2}
[07:30] <(cracker> ap:codes: {r:35 b:80 u:80 c:0 90 kb 2}
[07:30] <(cracker> ap:adv: {+ 180 kb 2}
[07:30] <(cracker> ap:antispam: {- + 10 10}
[07:30] <(cracker> ap:swear: {+ 120 kb 2}
[07:30] <(cracker> ap:pqsadv: {s:1 a:1}
[07:30] <(cracker> ap:ctcps: {1:30 180 kb 4}
[07:30] <(cracker> ap:massd: {5:1 60 kb 2}
[07:30] <(cracker> ap:massk: {8:2 30 kb 2}
[07:30] <(cracker> ap:massb: {18:2 30 kb 2}
[07:30] <(cracker> ap:limit: 5
[07:30] <(cracker> ap:cjoin: {3:2 120 kb 4}
[07:30] <(cracker> ap:partmsgs: {180 120 kb 2}
[07:30] <(cracker> ap:partmsgc: {r:35 b:35 u:35 c:0 30 kb 2}
[07:30] <(cracker> ap:revdoor: {3 120 kb 4}
[07:30] <(cracker> ap:nickf: {4:12 60 w:k:kb 2}
[07:30] <(cracker> ap:clones: {4 120 kb 2}
[07:30] <(cracker> ap:bnicks: {+ 120 kb 11}
[07:30] <(cracker> ap:drones: {- 180 45 2}
[07:30] <(cracker> ap:bidents: {+ 120 kb 10}
[07:30] <(cracker> ap:bchans: {- 90 w:kb 2 1}
[07:30] <(cracker> ap:echans: {0 60 w:kb 2 0}
[07:30] <(cracker> ap:bctcrs: {- 120 kb 2 0}
[07:30] <(cracker> ap:ctcpchecks: VERSION
[07:30] <(cracker> ap:btextl: {7:2 mR-k Possible.Text.Flood 60}
[07:30] <(cracker> ap:btextc: {550:3 mR-k Possible.Text.Flood 60}
[07:30] <(cracker> ap:bnotcl: {1:2 mR-k Possible.Notice.Flood 60}
[07:30] <(cracker> ap:bnotcc: {100:2 mR-k Possible.Notice.Flood 60}
[07:30] <(cracker> ap:bctcp: {2:60 mR-k Possible.CTCP.Flood 60}
[07:30] <(cracker> ap:massjoin: {4:1 mR-k Possible.Join.Flood 60}
[07:30] <(cracker> ap:brevdoor: {5:3 mR-k Possible.Join.Part.Flood 60}
[07:30] <(cracker> ap:bpartmsg: {5:3 mR-k Part.Message.Flood 60}
[07:30] <(cracker> ap:bnickf: {5:10 mR-k Possible.Nick.Flood 60}
[07:30] <(cracker> ap:bcodes: {25:2 mR-k Possible.Control.Codes.Flood 60}
[07:30] <(cracker> flood settings: chan ctcp join kick deop nick
[07:30] <(cracker> number: 0 3 3 9 0 0
[07:30] <(cracker> time : 0 3 2 5 0 0
[07:30] <(cracker> [02:30:00] #xyz# chaninfo #fungame |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Sat Jun 02, 2012 6:17 pm Post subject: |
|
|
allprotection won't remove any bans set by someone else unless it's a ban which it tried to set but was beat to it by that someone. If that's not the case then you might have another script running which is causing this behavior. _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
bryanwny Voice
Joined: 09 Sep 2012 Posts: 24
|
Posted: Wed Nov 14, 2012 8:59 pm Post subject: |
|
|
Is there any way to exempt certain hosts from getting clone kicked? I have it set to a limit of 3 clones before KB'ing, but I have (2) people using the same BNC hosting service. They are user1@bnc.com and user2@bnc.com.
Sometimes during a netsplit, or a ghosted connection, one (or both) of the clients rejoin while their "ghost" is still present, and the bot bans *!*@bnc.com even though I actually have both user1 and user2 added as +fv (and one of them is +of, actually). It doesn't seem to check in the user list before placing an "excess clone" kick.
BTW: This is a FANTASTIC script, thank you for sharing it.
EDIT: OK, I looked around some more and found your post about this:
| Sir_Fz wrote: | Unfortunately there's no exempts-list for clones protection. You can, however, add the following check in the "clones"-clause of procedure joins which would look like this:
| Code: | ...
"clones" {
variable eclones
if {![string is integer $off] || $off <= 0} {return 0}
# Add this line (make sure you modify it with your host)
if {[string match -nocase *@yourhost.net $uhost]} {continue}
set c 0
foreach ccheck [chanlist $chan] {
...
|
|
How would I go about adding in multiple hosts? Just add a separate line for each one, or is there a more efficient way of doing this? |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Sat Nov 17, 2012 7:17 am Post subject: |
|
|
There are several ways to approach this. One way is by adding multiple checks in the condition (I.e. condition1 || condition2 || condition...etc) but this can get messy as it grows. Another approach is creating a list of exempted hosts and using lsearch to find a match. I would've written it for you but I forgot the syntax :p (shows how close I am to eggdrops and tcl these days). You can search for it though, it's fairly simple. _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
SpiKe^^ Owner

Joined: 12 May 2006 Posts: 792 Location: Tennessee, USA
|
Posted: Sat Nov 17, 2012 11:06 am Post subject: |
|
|
Maybe something like this, but I'm not familiar with the script...
| Code: | ...
"clones" {
variable eclones
if {![string is integer $off] || $off <= 0} {return 0}
# Add these lines (make sure you modify it with all your exempt hosts)
set exemptstop 0
foreach exempthost {*@yourhost.net *@anotherhost.net *@anotherhost2.net
*@anotherhost3.net *@anotherhost4.net *@anotherhost5.net} {
if {[string match -nocase $exempthost $uhost]} {
set exemptstop 1 ; break
}
}
if {$exemptstop=="1"} {continue}
# continue may need to be return 0 ,i'm not sure #
set c 0
foreach ccheck [chanlist $chan] {
... |
_________________ SpiKe^^
Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
. |
|
| Back to top |
|
 |
bryanwny Voice
Joined: 09 Sep 2012 Posts: 24
|
Posted: Tue Nov 27, 2012 5:34 pm Post subject: |
|
|
| SpiKe^^ that seems to work great! I was just going to go the sloppy way because I wasn't really sure what I was doing lol. So thanks for that little snippet! |
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Wed Nov 28, 2012 9:07 am Post subject: |
|
|
Actually, all you need is to locate line 1309 that starts with:
| Code: |
foreach ccheck [chanlist $chan] {
|
and add the following after it:
| Code: |
if {[matchattr [nick2hand $ccheck] +fv $chan]} continue
|
and it will just skip from checking the guests that have +fv on that specific channel.
Or, if you wish to push things a bit to the extreme, you can create an user, let's call it exempt, then add whatever host you wish to this user and add the following line after the foreach loop:
| Code: |
if {[string equal -nocase [nick2hand $ccheck] "exempt"]} continue
|
Basically any of this two will do the same thing you wanted in the first place.  _________________ Once the game is over, the king and the pawn go back in the same box. |
|
| Back to top |
|
 |
bryanwny Voice
Joined: 09 Sep 2012 Posts: 24
|
Posted: Wed Nov 28, 2012 10:34 am Post subject: |
|
|
Hey caesar,
I really like that first example. Nice and clean and right to the point. It would also prevent me from having to manually edit the file anytime I wanted to add another clone exempt. I have a question in regards to that method though:
Say I have user1@blah.net; user2@blah.net; and user3@blah.net.. all of which are added to the bot as +v. No problems there. Now, what if unknown1@blah.net joins? Would it see all the other *@blah.net people and slap a ban on *!*@blah.net? Or no, because the other 3 users in my example are actually added to the bot and therefore don't count towards the 3 clone kick? How about if unknown1, unknown2, and unknown3 all happen to join? I can't imagine having that many people come in to the channel from the same host, but this is more of a "what if" scenario.
As far as the second method, I already do have an 'exempt' user which I gave a +e flag to in order to allow people around the DNS blacklist checker I'm running. The list of hosts gets pretty messy looking in a hurry just from that. I could certainly make a 'cloneexempt' user or something similar though. I still prefer method #1, IF I'm not going to run into issues in the scenario in question though. |
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Wed Nov 28, 2012 11:57 am Post subject: |
|
|
Or, the 3rd way is to use store in an variable (list) the hosts you wish to be exempted from the clone scan, something similar to SpiKe's post but more to the point.
Now, to reply to your question.
If you have user1@blah.net, user2@blah.net and user3@blah.net added in an exempted list, no matter the method used (user exempt, a variable or whatever other way) and when another user joins the channel or whenever the bot runs the clone checking part, this is what will happen next:
Scenario 1: let's say unknown1@blah.net joins a channel where user1, user2 and user3 are already on. The bot checks the users of the entire channel and will see all 4 users that have @blah.net address but no penalty will be issued as user1, user2 and user3 are exempted, so basically the clone scan process will see just one user with @blah.net, the unknown1 user.
Scenario 2: let's say user1, user2, user3 and unknown1 are on a channel where unknown2 has just joined. Again the clone scan will see all 5 users with @blah.net but again no penalty will be issued as user1, user2 and user3 are exempted, so basically the clone scan process will see just two users with @blah.net, the unknown1 and unknown2 users.
Scenario 3: let's say user1, user2, user3, unknown1 and unknown2 are on a channel where unknown3 has just joined. The clone scan will see that user1, user2 and user3 are in the exempt list and will continue until it will see unknown1, unknown2 and unknown3, thus for him there are 3 clones from the same address thus will issue a penalty, in your case banning the entire @blah.net, so all 6 users will be kicked.
Depending on your settings the scenario #3 can be similar to #2 if you allow 4 clones from the same host, thus scenario #4 will be like #3 and #3 like #2.
Haven't checked the code if it has such an exempt that will ban only the unknown1, 2 and 3 and will leave the user1, 2 and 3 alone.
Hope I've answered your question.  _________________ Once the game is over, the king and the pawn go back in the same box. |
|
| Back to top |
|
 |
bryanwny Voice
Joined: 09 Sep 2012 Posts: 24
|
Posted: Wed Nov 28, 2012 5:21 pm Post subject: |
|
|
caesar, very well explained. Thanks again, much appreciated!  |
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Thu Nov 29, 2012 2:56 am Post subject: |
|
|
I can help you out with a piece of code to add in that will make the clone function not issue a penalty if the count of known and exempted users is equal with 2, 3 or whatever you wish, even if the count of clones (unknown users) is equal or exceeds the number of allowed in your settings. _________________ Once the game is over, the king and the pawn go back in the same box. |
|
| Back to top |
|
 |
bryanwny Voice
Joined: 09 Sep 2012 Posts: 24
|
Posted: Thu Nov 29, 2012 11:28 am Post subject: |
|
|
Well, I think I SHOULD be good with how it is now. I have 4 server admins that frequent the channel, and 2 of them are added to the bot as +v because they are 'regulars'. My clone kick is set @ 3 (so if there is a 'dead' connection, and the person rejoins on a 'live' connection, they don't get banned). I guess if a 5th admin tried to join (being the 3rd unknown user), there would be a problem
Mibbit seems to have changed to doing Nick!Mibbit@users.real.host.com now rather than everyone showing up as @mibbit.com, so they aren't an issue any longer. I can't think of any other providers/services that have been an issue other than Mibbit in the past.
I guess that's up to you. As of this moment, I haven't needed a piece of code like that, but future proofing wouldn't be a bad idea, and it might come in handy for others as well. If it's too much of a hassle to figure out though, I certainly understand and will make do with what has already been graciously provided  |
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Thu Nov 29, 2012 11:48 am Post subject: |
|
|
If you are satisfied with how it is right now, then leave it as is, cos in order to implement what I've said above requires a few changes and if Sir_Fz updates his code then we would need to keep up with his changes if what has been discussed so far hasn't been already implemented by him already. _________________ Once the game is over, the king and the pawn go back in the same box. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|