isaac
asked Aug 29 2017
Answer
I am also very interested in this question.
douglasking
asked Feb 14 2023
edited Aug 18 2023
Hai, First add the iptables rule for trusted ip's like bellow
# iptables -A INPUT -p tcp -s ipaddress --dport 22 -j ACCEPT
Next add the rule for block other ip's
# iptables -A INPUT -p tcp --dport 22 -j DROP
and save new iptables rules.
# iptables -save
piraisudanrajendran
asked Aug 29 2017
edited Oct 05 2018
How to block ssh port in iptables
Hai.....
I am new for Iptables, i don' t know to block ssh port in iptables....!!!! please guide me block ssh port in iptables.