View Single Post

  #1 (permalink)  
Old 03-16-2008
David Brown
 
Posts: n/a
Default Using hostnames in iptables

If I write an iptables rule with a hostname, when is the hostname
resolved? For example:

iptables -A INPUT -p tcp --src remoteoffice.company.com --dport 25 -j ACCEPT


I believe that "remoteoffice.company.com" is resolved at the time the
"iptables" statement is executed, rather than being stored in the chain
as a hostname and resolved when packets are checked. Can anyone confirm
that?

If I wanted to have such a rule for a hostname whose address changed
(say, a dynamic ADSL address), is there any way to do it?

mvh.,

David
Reply With Quote