0

I want to create a rule using firewalld on Linux (RHEL 7) to allow ssh from a host name. I think I've got figured out how to do it using an IP address but I need to use a host name. Here is the rule I've got so far.

firewall-cmd --permanent --zone=public --add-rich-rule=' rule family="ipv4" source address="1.2.3.4" port protocol="tcp" port="22" accept'

I need something like:

firewall-cmd --permanent --zone=public --add-rich-rule=' rule family="ipv4" source address="host.domainname.com" port protocol="tcp" port="22" accept'

Does anyone know how this can be done?

Thank you, Mike

Mike
  • 41
  • 2
  • 8
  • Well, no sooner than I post my question, I find, what I believe to be, the answer. Here is a link to what I found: https://serverfault.com/questions/936415/reject-hostnot-ip-using-firewalld-firewalld-richlanguage – Mike Nov 15 '18 at 22:24

0 Answers0