Forwarding all *.example.com requests to a local webpage
Sorry if I don't use the correct terminology for what I'm trying to do, I don't have a ton of experience with networking.
Essentially, what I want all devices on my local network to be forwarded to a local host (let's say the ip is 192.168.1.2) when a request is made to *.example.com.
Apologies again if this was already answered on this sub.
EDIT: I should have probably mentioned this before, but I have a device that won't connect to my router without going to an address and getting a 200 OK, but I don't have an internet connection on my router so I'm simply looking for a way to send that 200 OK to the device from within my isolated network.
Posted Mar 27, 2019, 4:21 PM UTC · edited
You're wanting to modify DNS. The cheap/free way would be to edit each machine's host file.
Slightly fancier is if you have a router with OpenWRT (or similar) you could create a record on the router assuming all the clients on the network are configured to use it as the DNS server. See here
Or if you have a Pi-Hole you can do the same see here
This is all assuming you don't have a domain with AD DNS or another DNS system already in place.
OpenWRT seems like it would be helpful, thank you for pointing that out to me.
You don't necessarily explicitly need OpenWRT - just a configuration that allows you to modify DNS entries.
The PiHole route might be the best one for you. It lets you use your existing router (which you will configure to redirect DNS requests to the pihole) and you get all the great added functionality that a pihole brings.