#!/bin/bash
SRC=./GeoIPCountryWhois.csv
for BANIP in `egrep "China" $SRC | cut -d, -f1,2 | sed -e 's/"//g' | sed -e 's/,/-/g'`
do
/sbin/iptables -A INPUT -p all -m iprange --src-range $BANIP -j DROP
done
'프로그램 > Linux' 카테고리의 다른 글
ubuntu memory cached clear (0) | 2016.01.28 |
---|---|
ubuntu에 eclipse설치 초간단 방법 (0) | 2015.12.16 |
ubuntu sublime text 3 (0) | 2015.09.05 |
centos chromium install (0) | 2014.12.23 |
centos root 자동 로그인 (0) | 2014.12.23 |