2016-05-30 14:32:42 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
iptables -A INPUT -p tcp --destination-port 135 -m iprange --src-range 192.168.0.0-192.168.10.255 -j ACCEPT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 139 -m iprange --src-range 192.168.0.0-192.168.10.255 -j ACCEPT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 445 -m iprange --src-range 192.168.0.0-192.168.10.255 -j ACCEPT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 137 -m iprange --src-range 192.168.0.0-192.168.10.255 -j ACCEPT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 138 -m iprange --src-range 192.168.0.0-192.168.10.255 -j ACCEPT
|
|
|
|
|
|
|
|
|
|
|
|
iptables -A INPUT -p tcp --destination-port 135 -j REJECT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 139 -j REJECT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 445 -j REJECT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 137 -j REJECT
|
|
|
|
iptables -A INPUT -p tcp --destination-port 138 -j REJECT
|
|
|
|
|
2016-06-28 18:18:55 +02:00
|
|
|
ip6tables -A INPUT -p tcp --destination-port 135 -j REJECT
|
|
|
|
ip6tables -A INPUT -p tcp --destination-port 139 -j REJECT
|
|
|
|
ip6tables -A INPUT -p tcp --destination-port 445 -j REJECT
|
|
|
|
ip6tables -A INPUT -p tcp --destination-port 137 -j REJECT
|
|
|
|
ip6tables -A INPUT -p tcp --destination-port 138 -j REJECT
|
|
|
|
|