Ban Spammers

From Code-cat Knowledge Base

“... and I have extensive experience writing *computer code*, including, but not limited to: OIC, BTW, BRB, IMHO, LMAO, ROFL, TTYL...”

- Code-cat

Jump to: navigation, search

Parent

Script

#!/bin/bash
( cat wiki.code-cat.com.access.log ; cat wiki.code-cat.com.access.log.1 ; zcat wiki.code-cat.com.access.log.*gz ) | grep signup | awk '{print $1}' | sort | uniq -c | sort -n | awk '{if ($1 > 10) print $2; }' > spamips.txt
ip_array=(`cat spamips.txt`)
for i in "${ip_array[@]}"
do
/sbin/iptables -I INPUT -s $i -j DROP
done

Banned IPs

173.232.104.233
198.50.136.120
89.79.95.48
108.178.25.198
114.141.162.60
176.31.37.238
184.154.105.93
184.154.174.130
184.154.202.26
192.119.154.218
192.95.20.67
192.95.55.0
199.229.235.167
202.69.8.131
37.72.190.144
37.72.190.147
37.72.190.177
50.31.10.112
5.135.240.36
66.248.193.123
66.248.194.229
69.175.104.62
89.47.28.121
96.127.139.92
96.127.149.211
96.127.164.115
142.0.34.142
5.135.113.133
178.33.40.167
192.210.140.42
199.231.93.102
5.135.11.116
5.135.240.48
92.29.12.4
94.242.254.38
109.156.183.181
37.215.185.75
79.182.180.128
80.47.200.194
178.201.14.185
24.84.17.245
89.243.252.200
92.24.224.192
37.112.94.72
89.77.81.57
66.248.193.187
109.207.200.21
178.238.224.189
79.191.90.162
91.236.75.67
64.120.242.19
184.154.146.45
92.24.224.15
176.31.45.175
81.129.211.147
178.201.16.56
92.24.225.28
92.24.224.78
178.203.161.89
91.228.199.246
199.19.109.185
173.242.124.205
80.47.202.30
5.9.215.74
92.24.227.24
5.9.238.82
176.9.198.237
176.9.185.52
Personal tools