Iptables "Firewall"

Status
Not open for further replies.
Aug 10, 2017
37
0
6
56
I am trying to add this line to my iptables and I get errors how to fix it. I am running iptables v1.4.21

iptables -I INPUT -j DROP -p tcp --dport 5060 -m string --string "friendly-scanner" --algo bm
iptables: No chain/target/match by that name.
 
Aug 10, 2017
37
0
6
56
Did some test I am getting the same error

# iptables -A INPUT -j DROP -p udp --dport 5060:5090 -m string --string "friendly-scanner" --algo bm
iptables: No chain/target/match by that name.
 

DigitalDaz

Administrator
Staff member
Sep 29, 2016
3,055
574
113
That implies you have no input chain, what does iptables -L give?
 
Aug 10, 2017
37
0
6
56
# iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere tcp dpt:http
ACCEPT tcp -- anywhere anywhere tcp dpt:https
ACCEPT tcp -- anywhere anywhere tcp dpts:sip:5069
ACCEPT udp -- anywhere anywhere udp dpts:sip:5069
ACCEPT tcp -- anywhere anywhere tcp dpt:5080
ACCEPT udp -- anywhere anywhere udp dpt:5080
ACCEPT udp -- anywhere anywhere udp dpts:16384:32768
ACCEPT icmp -- anywhere anywhere icmp echo-request
ACCEPT udp -- anywhere anywhere udp dpt: openvpn
ACCEPT icmp -- anywhere anywhere icmp echo-request

Chain FORWARD (policy DROP)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

Chain SIPDDOS (0 references)
target prot opt source destination
LOG all -- anywhere anywhere LOG level info prefix "firewall-sipddos: "
DROP all -- anywhere anywhere


I have use these settings from http://fusionpbx-docs.readthedocs.io/en/latest/firewall/iptables.html#basic-rules
 
Status
Not open for further replies.