[root@localhost ~]# more network_ten.sh
#!/bin/bash
IPT='/sbin/iptables'
$IPT -I INPUT 1 -m limit --limit 3/sec -s 192.168.1.3 -j ACCEPT
$IPT -I INPUT 2 -s 192.168.1.3 -j DROP
$IPT -I OUTPUT 1 -m limit --limit 3/sec -d 192.168.1.3 -j ACCEPT
$IPT -I OUTPUT 2 -d 192.168.1.3 -j DROP
$IPT -I FORWARD 1 -m limit --limit 3/sec -s 192.168.1.3 -j ACCEPT
$IPT -I FORWARD 2 -s 192.168.1.3 -j DROP
$IPT -I FORWARD 1 -m limit --limit 3/sec -d 192.168.1.3 -j ACCEPT
$IPT -I FORWARD 2 -d 192.168.1.3 -j DROP
[root@localhost ~]#
阅读(1407) | 评论(0) | 转发(0) |