0

I have a embedded Linux box as a router which has two interfaces.

One interface is connected to public network by dialing into ISP.

Another interface (its IP is 192.168.1.1) is connected to LAN clients by a simple hub.

If a client send a DNS query to a DNS ex:5.6.7.8, I want capture this query and forward/relay to another DNS ex: 1.2.3.4.

I want to know if utility like Dnsmasq or DNRD can do this?

I know Dnsmasq and DNRD can forward DNS query that just ask to Linux box (LAN client set DNS as 192.168.1.1). But I don't know if they can handle ALL DNS query pass Linux box?

Please Help~ I have bothered by this some days.. Thanks every responders.

1
  • this is off topic here, it's not programming related.
    – Alnitak
    Jun 19, 2013 at 16:12

1 Answer 1

0

dnsmasq can't do it by itself, but you could in theory configure an outbound iptables rule in the O/S itself that will intercept all outbound DNS queries and redirect them on somewhere else.

I wouldn't recommend it, though. It rather depends on what problem you're trying to solve. Messing with DNS queries is likely to cause pain in the long run.

1
  • Because I would like to redirect all DNS packets that pass my embedded Linux box (actually a home AP router) to a Symantec's Norton ConnectSafe DNS. Norton ConnectSafe DNS will respond only the DNS query that asks what is not adult/malicious/non-family friendly URL. Jun 24, 2013 at 2:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .