• Welcome to Valhalla Legends Archive.
 

Wildcards and Ip bans

Started by Gangz, October 15, 2003, 02:30 AM

Previous topic - Next topic

Gangz

 :'( I have spent litterally hours triing to do ip bans and wildcards in vb if anyone can help me please reply or whisper me at Gangz@uswest. thnx much

Gangz

I spent like 2 hours surfing through the Previous posts to see what i can find....As of ip bans i can make it ignore right before it bans, but I Do not understand how to make it check the flags when users join to ban it..


..as of wildcards i found the script

If Lcase(username) Like "a" Then
CleanSlateBot1.Send "/ban " & Username

I was wondering if this would work if i added it to the bans and kicks...or does "a" need to be substituted with something else...

I know im not to far from learning these commands..All help is much appreciated

WiLD

Ok this is for CSB, i used it when i made a quick bot 2 hold ops and ban every1 that entered i change i took over =P

If Form1.chkIPBan = vbChecked And Flags = &H20 Then
CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If

if you want it to ALWAYS be on just remove the "Form1.chkIPBan = vbChecked And" so it looks like this;

If Flags = &H20 Then
CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If

Quiet easy, but we all have to start somewhere.
=_=  &&  g0dFraY  &&  -=Templar=-  @USWest

Gangz


Banana fanna fo fanna

You have to squelch them first.

Kp

Quote from: WiLD on October 15, 2003, 04:18 AMOk this is for CSB, i used it when i made a quick bot 2 hold ops and ban every1 that entered i change i took over =P

If Form1.chkIPBan = vbChecked And Flags = &H20 Then
CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If

if you want it to ALWAYS be on just remove the "Form1.chkIPBan = vbChecked And" so it looks like this;

If Flags = &H20 Then
CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If
I can avoid your "IP ban" very easily simply by not sending 0x14 at logon, thus getting myself the plug.  Then my flags would be 0x30 (after you squelch me).  Thus, your test would fail to recognize me as IP banned.  The correct way to test for squelch (as well as test for any other properties a user's flags indicate) is to use bitwise and, not to test for equality, as you are doing.
[19:20:23] (BotNet) <[vL]Kp> Any idiot can make a bot with CSB, and many do!

Gangz

Interesting KP..So are you saying that anyone with a botplug on would slip through the ip ban that Wild has produced?

iago

No, he said that that code is checking flags incorrectly, since if he has a plug, his flags will be:
0x10 (Plug) | 0x20 (squelched), which is 0x30 (Plug | squelched)
This'll make an interesting test for broken AV:
QuoteX5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*


Gangz

See this is where the problem is...I dont understand how to make it identify the proper flags...Sorry im kinda new to this...

Soul Taker


Gangz

If (BattleNetFlag And FlagValue) = 0x30 Then
    CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If
would that be correct?

SNiFFeR


If Flags = &H20 And Flags = &H30 Then ' Flags is already declared when you are using CleanSlatebot2.
CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If


I suppose that'd work, It depends how you setup your flags though. The flags could be 48 and 32.

iago

Quote from: Gangz on October 15, 2003, 04:43 PM
If (BattleNetFlag And FlagValue) = 0x30 Then
    CleanSlateBot2.Send "/ban " & Username & " IP Banned"
End If
would that be correct?

Nope.

First, you can't use 0x in VB
Second, just say:
if(UserFlag and 0x20) then
...

This'll make an interesting test for broken AV:
QuoteX5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*


Gangz

thanks iago ill give it a try..If anyone can help with cards please post..thanks

Gangz

hrm..Thanks sniff i think that might work and be a little bit easier  :P