22

How can I make iptables show me port numbers instead of aliases for well known port numbers (eg. http for 80, https for 443 etc.). Is there a way to make it show just port numbers at all times?

Lukasz
  • 409
  • 2
  • 6
  • 9

1 Answers1

28

Use the -n option.

$ iptables --help
[...]
  --numeric     -n              numeric output of addresses and ports
u1686_grawity
  • 426,297
  • 64
  • 894
  • 966
  • What about the CentOS/Linux Setup Utility - I use that configure the firewall most of the time - any way to disable the aliases in there? – Lukasz Aug 29 '11 at 23:30
  • It works in CentOS too. To list the rules, try: iptables -L -n – northben Apr 04 '17 at 00:17