SmartDNS with Wireguard and PBR

Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking
Author Message
newbcentral
DD-WRT Novice


Joined: 27 May 2023
Posts: 2

PostPosted: Sat Jun 10, 2023 10:40    Post subject: SmartDNS with Wireguard and PBR Reply with quote
I am using a wireguard tunnel for the home Network. I have set up the PBR so that only certain clients use the wireguard tunnel, based on the source IP.

I also use SmartDNS. SmartDNS doesn‘t use the wireguard tunnel because the router IP is not defined as a source IP to use the tunnel. Thats why I had DNS leaks.

I have now added a destination based policy to the wireguard configuration that routes all queries to the DNS server IPs through the tunnel. This works, but it seems like a bandaid solution. Now the DNS requests of all clients are routed through the wireguard tunnel, and not just those specified as a source in the PBR configuration.

Is there an easy and elegant way to only resolve DNS requests from PBR-source IPs through the tunnel and all others not?
Sponsor
dale_gribble39
DD-WRT Guru


Joined: 11 Jun 2022
Posts: 1935

PostPosted: Sat Jun 10, 2023 14:30    Post subject: Reply with quote
Did you read the guides?

Sticky: WireGuard guides and documentation

_________________
"The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep." - Robert Frost

"I am one of the noticeable ones - notice me" - Dale Frances McKenzie Bozzio

<fact>code knows no gender</fact>

This is me, knowing I've ruffled your feathers, and not giving a ****
Some people are still hard-headed.

--------------------------------------
Mac Pro (Mid 2012) - Two 2.4GHz 6-Core Intel Xeon E5645 processors 64GB 1333MHz DDR3 ECC SDRAM OpenSUSE Leap 15.5
newbcentral
DD-WRT Novice


Joined: 27 May 2023
Posts: 2

PostPosted: Sat Jun 10, 2023 14:53    Post subject: Reply with quote
I did, just now. Wink

Unfortunately it doesn’t discuss smartdns. And the suggested split DNS option makes the VPN clients use the VPN DNS servers, which is not what I want.

Assigning different DNS servers depending on client IP would make the client resolve the DNS requests themselves. I want dd-wrt to do it, because I don’t trust all my devices to use DoH/DoT.

Unless I have missed something, there doesn’t seem to be a solution for my problem.
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum