OPNsense Forum

English Forums => General Discussion => Topic started by: ComputerKid on December 11, 2024, 04:21:46 PM

Title: How to handle subdomain not to be resolved externally?
Post by: ComputerKid on December 11, 2024, 04:21:46 PM
Hi,
I'm using internally a subdomain of my tld, let's call it sub.tld.com.
I'm fighting the issue that for example when I ping pc1.sub.tld.com i get the local IP 192.168.1, but if i ping pc99.sub.tld.com (which does not exist) I get the ip of my tld. What I have to do that unbound will answer that this host is not reachable?

Regards.
Martin
Title: Re: How to handle subdomain not to be resolved externally?
Post by: dseven on December 12, 2024, 09:44:36 AM
By "using internally", do you mean that you have set System -> Settings -> General -> Domain to "sub.tld.com"?

Does public DNS for "tld.com" have a wildcard?

You could try chaning Services -> Unbound DNS -> General -> Local Zone Type to "static" instead of "transparent"
Title: Re: How to handle subdomain not to be resolved externally?
Post by: ComputerKid on December 12, 2024, 11:55:06 AM
Ok, seems that my hosting partner has a wildcard entry...i removed it and hopefully this help, have to wait up to 48 hours. On the other side would it be nice if there is a possibility to exclude specific domains to be resolved externally...if someone has an idea?
Title: Re: How to handle subdomain not to be resolved externally?
Post by: Patrick M. Hausen on December 12, 2024, 12:00:03 PM
Quote from: ComputerKid on December 12, 2024, 11:55:06 AM
On the other side would it be nice if there is a possibility to exclude specific domains to be resolved externally...if someone has an idea?

Quote from: dseven on December 12, 2024, 09:44:36 AM
You could try chaning Services -> Unbound DNS -> General -> Local Zone Type to "static" instead of "transparent"
Title: Re: How to handle subdomain not to be resolved externally?
Post by: ComputerKid on December 12, 2024, 03:01:39 PM
Sorry I have overseen this post I'll try with static zone.