0

I just followed the tutorial here for creating a bridged wireless access point with my Raspberry Pi 4. Now what I'm trying to do is ensure that any device connected to the Pi's network gets specific DNS records. For example, example.com could re-route to the Pi's local IP address 192.168.1.2 (sort of like a captive portal, but for specific websites).

What I already tried:

I've already installed Dnsmasq on the Pi, so when I use dig example.com it returns 192.168.1.2. However, this only works from the Pi's perspective, and if I connect to its network from another device and run dig example.com, it returns the real IP address.

How can I make DNS queries from devices connected to the Pi's network follow its DNS records? I'd prefer not to configure the WiFi network settings to specifically point to the Pi as a DNS server, but when I tried, even that didn't work.

2
  • If you want to intercept traffic DON'T create a bridge. Commented Sep 7, 2023 at 1:44
  • Configure the DHCP server to point the WiFi devices to your Pi as DNS server. Commented Sep 7, 2023 at 9:16

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.