Proxycheck check. (Check through 12 BL zones!)

Platform:  mIRC
Published  Jul 25, 2011
Updated  Aug 02, 2011


With this script you can check which ip is in the blacklists and which not.

What do the colors mean?
Green = Clear
Red = Found

How do it works?
/Proxycheck <ip>
/Proxycheck localhost To check your own ip

Example

* The IP 127.0.0.1 has not been found in BL zone dnsbl.dronebl.org
* The IP 127.0.0.1 has not been found in BL zone dnsbl.proxybl.org
* The IP 127.0.0.1 has not been found in BL zone tor.dnsbl.sectoor
* The IP 127.0.0.1 has not been found in BL zone tor.dan.me.uk
* The IP 127.0.0.1 has not been found in BL zone dnsbl.njabl.org
* The IP 127.0.0.1 has not been found in BL zone rbl.efnet.org
* The IP 127.0.0.1 has not been found in BL zone virbl.dnsbl.bit.nl
* The IP 127.0.0.1 has not been found in BL zone dnsbl.ahbl.org
* The IP 127.0.0.1 has not been found in BL zone rbl.faynticrbl.org
* The IP 127.0.0.1 has not been found in BL zone dnsbl.ipocalypse.net
* The IP 127.0.0.1 has not been found in BL zone dnsbl.rizon.net
* The IP 127.0.0.1 has not been found in BL zone dnsbl.swiftbl.org


BL zones included in the script
dnsbl.dronebl.org
dnsbl.proxybl.org
tor.dnsbl.sectoor
tor.dan.me.uk
rbl.efnet.org
virbl.dnsbl.bit.nl
dnsbl.ahbl.org
rbl.faynticrbl.org
dnsbl.ipocalypse.net
dnsbl.rizon.net
dnsbl.swiftbl.org

Thanks to patje from SwiftIRC for the RevIP alias. ;- Proxy check
;- Written by Aha2Y
;- /proxycheck <ip>

alias proxycheck {
if ($1 == $null) { echo 3* Missing parameters: /proxycheck <ip> or to check your own ip /proxycheck localhost }
else {
if ($1 == localhost) {
set %dnscheckproxy 1
echo -a 3* Checking your ip address, Please wait...
set %checkip $ip
/proxycheck.progress
halt
}
else {
set %dnscheckproxy 1
echo -a 3* Checking ip address, Please wait...
set %checkip $1
/proxycheck.progress
}
}
}

alias -l proxycheck.progress {
.timer 1 1 dronebl
.timer 1 3 proxybl
.timer 1 4 tor.dnsbl.sectoor
.timer 1 5 tor.dan.me.uk
.timer 1 6 dnsbl.njabl.org
.timer 1 7 rbl.efnet.org
.timer 1 8 virbl.dnsbl.bit.nl
.timer 1 9 dnsbl.ahbl.org
.timer 1 10 rbl.faynticrbl.org
.timer 1 11 dnsbl.ipocalypse.net
.timer 1 12 dnsbl.rizon.net
.timer 1 13 dnsbl.swiftbl.org
}


alias -l dronebl {
set %dbl dnsbl.dronebl.org
dns $revip(%checkip) $+ .dnsbl.dronebl.org
}
alias -l proxybl {
set %dbl dnsbl.proxybl.org
dns $revip(%checkip) $+ .dnsbl.proxybl.org
}
alias -l tor.dnsbl.sectoor {
set %dbl tor.dnsbl.sectoor
dns $revip(%checkip) $+ .tor.dnsbl.sectoor.de
}
alias -l tor.dan.me.uk {
set %dbl tor.dan.me.uk
dns $revip(%checkip) $+ .tor.dan.me.uk
}
alias -l dnsbl.njabl.org {
set %dbl dnsbl.njabl.org
dns $revip(%checkip) $+ .dnsbl.njabl.org
}
alias -l rbl.efnet.org {
set %dbl rbl.efnet.org
dns $revip(%checkip) $+ .rbl.efnet.org
}
alias -l virbl.dnsbl.bit.nl {
set %dbl virbl.dnsbl.bit.nl
dns $revip(%checkip) $+ .virbl.dnsbl.bit.nl
}
alias -l dnsbl.ahbl.org {
set %dbl dnsbl.ahbl.org
dns $revip(%checkip) $+ .dnsbl.ahbl.org
}
alias -l rbl.faynticrbl.org {
set %dbl rbl.faynticrbl.org
dns $revip(%checkip) $+ .rbl.faynticrbl.org
}
alias -l rbl.faynticrbl.org {
set %dbl rbl.faynticrbl.org
dns $revip(%checkip) $+ .rbl.faynticrbl.org
}
alias -l dnsbl.ipocalypse.net {
set %dbl dnsbl.ipocalypse.net
dns $revip(%checkip) $+ .dnsbl.ipocalypse.net
}
alias -l dnsbl.rizon.net {
set %dbl dnsbl.rizon.net
dns $revip(%checkip) $+ .dnsbl.rizon.net
}
alias -l dnsbl.swiftbl.org {
set %dbl dnsbl.swiftbl.org
dns $revip(%checkip) $+ .dnsbl.swiftbl.org
}

on *:DNS:{
if (%dnscheckproxy == 1) {
if (%dbl == dnsbl.dronebl.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == dnsbl.proxybl.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == tor.dnsbl.sectoor) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == tor.dan.me.uk) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == dnsbl.njabl.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == rbl.efnet.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == virbl.dnsbl.bit.nl) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == dnsbl.ahbl.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == rbl.faynticrbl.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == dnsbl.ipocalypse.net) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == dnsbl.rizon.net) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
if (%dbl == dnsbl.swiftbl.org) {
if ($iaddress != $null) {
echo -a 4* The IP %checkip has been found in BL zone %dbl }
else {
echo -a 3* The IP %checkip has not been found in BL zone %dbl }
}
unset %dbl
unset %dnsproxycheck
}
}


;-RevIP script by Patje from SwiftIRC.
alias revip { tokenize 46 $1 | return $+($4, ., $3, ., $2, ., $1) }

Comments

Sign in to comment.
Aha2Y   -  Apr 17, 2012
Well, If you own the bot X, Yes, else No!
 Respond  
SoLoMaNXX   -  Apr 17, 2012
Can This Snippet Work On Undernet ? Banning Through X ? Or By mode
Thanks
 Respond  
SnoooP   -  Nov 28, 2011
also

@Blessful-Hell - Why not use a BOPM? http://irc-wiki.org/BOPM it does what you asked, scans the client upon connection then acts appropriately.
 Respond  
SnoooP   -  Nov 28, 2011
I was also thinking, different IRCD's sometimes have different syntax for glines, zlines, and sometimes commands don't exist on other ircds. Perhaps you should do something so it checks the IRCd version then uses the appropriate commands.
 Respond  
Blessful-Hell   -  Sep 22, 2011
can't anyone give a code that, if anyone joins in the server it will autometically whois and look for DNSBL database. if its a proxy it will gzline the ip..... please if anyone can make like that i will be greatful... i searched here like this proxy killer but didn't find any. If anyone can make that for me. Thank You
 Respond  
SReject   -  Aug 18, 2011
@CrAnK: I edited/fixed my previous version and bug tested it the best I could. Please try it :)
 Respond  
CrAnK   -  Aug 15, 2011
SReject your code doesnt work to me

Code

 


Code

 


its doesnt gline the user or IP
 Respond  
Aha2Y   -  Aug 03, 2011
@PyThon

Nope, it Glines the user who uses proxy (the ip address)
 Respond  
PyThOn   -  Aug 02, 2011
Does it k line them when it picks up a proxy?
 Respond  
SnoooP   -  Aug 02, 2011
Perhaps have an option to set how you deal with proxies, eg: gline, kline, zline (gzline), kill
 Respond  
Aha2Y   -  Aug 02, 2011
@SReject, I like that idea.
Keep up the good work ;)
 Respond  
SReject   -  Aug 02, 2011
Am thinking of posting this as my own snippet[Aha2Y will get the due credit] with some added features Such as Oper check for the user[so you aren't trying to gline people when you aren't an oper], an easy way to edit the dnsBL's used. A different sort of queue. If yall want suggest some ideas and I'll consider them :)
 Respond  
SReject   -  Aug 02, 2011
Ok, I THINK I have it to handle hosts aswell as IP addresses. I have NOT thoughly tested it, so there maybe more bugs

Code

 


Updates:
Aug 18th:
-Fixed bug inwhich I had "$PNext" instead of "$PAddr
-Fixed bug inwhich was using 32 instead of 46 as token delimiter
-Fixed bug inwhich an extra "." was being added to BList dns addresses
-Fixed bug inwhich /gline format was incorrect
-Made code a little more readable
-Added a commented version to the script so if the code changes people can keep it up to date.

Aug 2nd:
- Cleaned up code.
- /glines Host aswell as IP address
 Respond  
Aha2Y   -  Aug 02, 2011
@SReject
That's true, and i told it was untested

@illhawkthat
lol!
 Respond  
SReject   -  Aug 02, 2011
@PyThOn: I'm working on that now :)
 Respond  
illhawkthat   -  Aug 02, 2011
@Aha2y: well i thought it was hilarious, anyways, 10/10 for me.
 Respond  
PyThOn   -  Aug 02, 2011
o.O @ SReject

How would he make it then?
 Respond  
SReject   -  Aug 02, 2011
@Aha2Y: Your gline script won't work due to when clients connect, their IP is only given if it can't be reverse-resolved to a host. You have to resolve their host to an IP, then proxy check their IP.
 Respond  
Aha2Y   -  Aug 02, 2011
@illhawkthat
That just sucks, rating because there is a typo in the title.
Well not everyone is that good at English you know?
 Respond  
illhawkthat   -  Aug 02, 2011
I rated it a 1/10 because of the spelling mistake in the title. I will change it to a ten once u lrn 2 spalt.
 Respond  
PyThOn   -  Aug 02, 2011
ooo Ok So where does it send the msg's?
 Respond  
Aha2Y   -  Aug 02, 2011
It triggers when someone connects, (if it works)
 Respond  
PyThOn   -  Aug 02, 2011
Would be cool if i knew how to activate it, Also can someone else add a spy script 2 it?
 Respond  
PyThOn   -  Aug 02, 2011
Thanks I will test this.
 Respond  
Aha2Y   -  Aug 02, 2011
Here it is.
Its untested because i don't own a IRC server.
If someone is missing/broke please post it.

Code

 
 Respond  
SnoooP   -  Aug 01, 2011
PyThOn why don't you use a BOPM. http://irc-wiki.org/BOPM
 Respond  
PyThOn   -  Aug 01, 2011
How long do you think it will take Aha2Y
 Respond  
SReject   -  Aug 01, 2011
My Versoin:

Code

 
 Respond  
Aha2Y   -  Aug 01, 2011
yep thanks.
 Respond  
PyThOn   -  Aug 01, 2011
There you go thats what u mean right?
 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.