/etc/hosts file syntax. Is it possible to set one IP for a zone

dnshosts

I would like to set one IP for a zone (livejournal.com)

currently I am having to directly type the subdomains like:

11.11.11.11 sub1.livejournal.com
11.11.11.11 sub2.livejournal.com
11.11.11.11 sub3.livejournal.com

etc.

I tried

11.11.11.11 *.livejournal.com

and

11.11.11.11 .livejournal.com

didn't help.

So I want to have only one line and resolve missing subdomains to IP like: sub1000.livejournal.com without explicitly specifying it

Best Answer

This can be implemented with a DNS forwarder than acts like a very basic DNS server. The popular implementation is Dnsmaq, however this might be possible with services like OpenDNS that can perform DNS filtering for you.

Related Question