iptables rule addition yields unknown option error

Solution In Progress - Updated -

Issue

  • Trying to use iptables commands it is not properly recognizing the option
  • Trying to add iptables rule and running into an issue
[root@localhost ~]# iptables -A INPUT -–s 10.0.0.0/8 -j DROP
iptables v1.4.21: unknown option "INPUT"
Try `iptables -h' or 'iptables --help' for more information.
[root@localhost ~]# iptables -A INPUT -p tcp -m tcp -–dport 80 -j ACCEPT
iptables v1.4.21: unknown option "-m"
Try `iptables -h' or 'iptables --help' for more information.

Environment

  • Red Hat Enterprise Linux (RHEL) 6
  • Red Hat Enterprise Linux (RHEL) 7

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In