iptables => -A INPUT: with or without "-m tcp"
-
Hello Sorry for this rather simple question but I couldn't find the answer in the MAN pages of IPTABLES.
I used the "Set Up The Ultimate VPS" and there was part about iptables.
There you have the following (standard?) inclusion:
-A INPUT -p tcp --dport 80 -j ACCEPT -A INPUT -p tcp --dport 443 -j ACCEPTAnd right beneath that the following inclusion (for SSH):
-A INPUT -p tcp -m state --state NEW --dport 30000 -j ACCEPTI wanted to add another rule to allow FTP connections, I used
(do not mind the portnumber, I used a valid one)(1)
-A INPUT -p tcp -m tcp --dport 99999 -j ACCEPTMy question is, is the above correct?
Or should I use:(2)
-A INPUT -p tcp --dport 99999 -j ACCEPTWhen I use the rule stated under (1) it works, but maybe it's better (best practice?) to use the one stated under (2)? Which is the preferred method?
Posted 6 months ago #
Reply
You must log in to post.
Want HTML?
a blockquote code em strong ul ol liPlace code between backticks `codeHere`
You've got it.
