LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-25-2017, 06:05 PM   #1
Timbo66
LQ Newbie
 
Registered: Jan 2017
Posts: 3

Rep: Reputation: Disabled
Forwarding DNS queries based on the source IP and/or MAC of the requesting client


How would one configure BIND on a Linux system to forward DNS queries to a different upstream forwarder, based upon the source IP and/or MAC of the requesting host?

For example, I might want to send DNS queries from certain hosts on my network to OpenDNS, others to Google, and all others to my ISP.
 
Old 01-25-2017, 07:40 PM   #2
tshikose
Member
 
Registered: Apr 2010
Location: Kinshasa, Democratic Republic of Congo
Distribution: RHEL, Fedora, CentOS
Posts: 525

Rep: Reputation: 95
Hi,

You can do different treatments according to source IP using views in bind configuration.
 
1 members found this post helpful.
Old 01-25-2017, 07:41 PM   #3
tshikose
Member
 
Registered: Apr 2010
Location: Kinshasa, Democratic Republic of Congo
Distribution: RHEL, Fedora, CentOS
Posts: 525

Rep: Reputation: 95
For the MAC? I've never seen neither heard of, and I doubt it exists in bind.
 
Old 01-26-2017, 02:32 PM   #4
Timbo66
LQ Newbie
 
Registered: Jan 2017
Posts: 3

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by tshikose View Post
For the MAC? I've never seen neither heard of, and I doubt it exists in bind.
Sorry, I should have been more clear. I didn't mean for the "Mac", I meant the MAC which is the hardware address of the network card
 
Old 01-26-2017, 02:50 PM   #5
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,985

Rep: Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626
Wonder if using a static arp entry and then use the IP you set to that mac address would work?
 
Old 01-26-2017, 02:54 PM   #6
Timbo66
LQ Newbie
 
Registered: Jan 2017
Posts: 3

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by tshikose View Post
Hi,

You can do different treatments according to source IP using views in bind configuration.
Many thanks, BIND "views" are exactly what I needed

https://kb.isc.org/article/AA-00851/...y-example.html
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Reverse query on forwarding DNS queries sandeep_hello Linux - Server 8 12-27-2012 10:02 AM
[SOLVED] Source based DNS reply? szboardstretcher Linux - Networking 1 01-11-2011 11:32 AM
MAC address based client restrictions aliasgherman Linux - Networking 1 04-10-2007 04:53 PM
How does a client resolve dns queries with transparent proxy ? amitsharma_26 Linux - Security 5 09-17-2006 11:49 AM
Port Forwarding Based on the Source linuxboy69 Linux - Networking 2 01-06-2004 04:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration