Skip to content

Instantly share code, notes, and snippets.

@cenrak
Created September 1, 2013 18:17
Show Gist options
  • Save cenrak/6406247 to your computer and use it in GitHub Desktop.
Save cenrak/6406247 to your computer and use it in GitHub Desktop.
#/bin/bash
iptables --flush
service iptables save
service iptables stop
service iptables start
BIPS=`cat /tmp/blocked_ips.list`
for ip in $BIPS
do
/sbin/iptables -I INPUT -s $ip -j DROP
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment