четвъртък, 18 декември 2014 г.

Dropping TOR servers access to you

This is very fast script wrriten for few minutes to drop TOR connections to your network. Only replace YOUR_IP_HERE with your real IP. Of course fix path of iptables.

#!/bin/bash
{
wget https://check.torproject.org/cgi-bin/TorBulkExitList.py?ip=YOUR_IP_HERE -O /etc/rc.d/torrs
}
BLOCKADDRESSES()
{
/usr/sbin/iptables -N TORBLOCK
/usr/sbin/iptables -F TORBLOCK
/usr/sbin/iptables -I TORBLOCK -j RETURN

for node in `/bin/grep -v -e ^# /etc/rc.d/torrs`
do
/usr/sbin/iptables -I TORBLOCK -s $node -j DROP
done

}.
BLOCKADDRESSES

Няма коментари: