Changes between Version 2 and Version 3 of Iptables
- Timestamp:
- 02/01/22 23:05:53 (3 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Iptables
v2 v3 25 25 iptables -D OUTPUT -d 203.151.31.76 -j DROP 26 26 }}} 27 28 To block specific port number such tcp port # 5050, enter: 29 {{{ 30 #!sh 31 iptables -A OUTPUT -p tcp --dport 5050 -j DROP 32 }}} 33 To block tcp port # 5050 for an IP address 192.168.1.2 only, enter: 34 {{{ 35 #!sh 36 iptables -A OUTPUT -p tcp -d 192.168.1.2 --dport 5050 -j DROP 37 }}} 38 For unblock just change -A to -D on the above command