Page 1 of 1

Feature Request: Specify Source Address in DNS Server

Posted: Tue Jun 24, 2014 4:11 pm
by rmmccann
I think a nice feature would be to specify the source address to use for DNS queries made by the Mikrotik DNS Server.

I use DNS based content filtering for several of my clients - many of these clients have multiple IP addresses with different policies for each IP (hotspot network, corporate network, etc). I cannot use the MT for DNS in a lot of these scenarios because it doesn't allow me to specify which IP should make the request. This affects which policy is being applied to the DNS request and either blocks or allows content which shouldn't be.

Re: Feature Request: Specify Source Address in DNS Server

Posted: Tue Jun 24, 2014 6:51 pm
by rickfrey
Being able to specify the source address would be extremely helpful! +1

Re: Feature Request: Specify Source Address in DNS Server

Posted: Tue Jun 24, 2014 7:15 pm
by dohmniq
Possible work-around could be to add a route and specify the pref-src option:

/ip route add dst-address=remote.dns gateway=some-gateway.lan pref-src=dns.ip.src.address

If you don't want to hard-code the gateway field then you might be able to get away with using another IP on the MT box so it routes to itself and then on to final destination.

Re: Feature Request: Specify Source Address in DNS Server

Posted: Thu Jun 26, 2014 6:03 pm
by rmmccann
Possible work-around could be to add a route and specify the pref-src option:

/ip route add dst-address=remote.dns gateway=some-gateway.lan pref-src=dns.ip.src.address

If you don't want to hard-code the gateway field then you might be able to get away with using another IP on the MT box so it routes to itself and then on to final destination.
Would this not redirect ALL traffic destined to that DNS server with the preferred source IP specified? If so, this wouldn't work for my application - need to allow certain requests (say from inside LAN AD server) to come from one source IP and other requests using the MT as DNS server to come from another.

Honestly, it would be nice to be able to specify source IP for any service where the router is making a query or request - including NTP client and others.

Re: Feature Request: Specify Source Address in DNS Server

Posted: Sat Jun 28, 2014 7:55 pm
by HaPe
Great idea. It should be possible to change source ip for services, for ipv4 and ipv6 separately.