Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Upstream DNS servers] wrong upstreams specification even when test passes #4074

Closed
3 tasks done
jacktheripper19 opened this issue Jan 3, 2022 · 6 comments
Closed
3 tasks done
Assignees
Milestone

Comments

@jacktheripper19
Copy link

Prerequisites

Please answer the following questions for yourself before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.

  • I am running the latest version
  • I checked the documentation and found no answer
  • I checked to make sure that this issue has not already been filed

Issue Details

  • Version of AdGuard Home server:
    • v0.107.2
  • How did you install AdGuard Home:
    • Docker
  • How did you setup DNS configuration:
    • System
  • CPU architecture:
    • AMD64
  • Operating system and version:
    • Ubuntu 20.04.1

Expected Behavior

Setting up the upstream dns server using the hostname of the resolver should work

Actual Behavior

the test passes but the specification control returns an error HOSTNAME is not a valid IP

Additional Information

I have a setup where the upstream dns resolver unbound can change ip occasionally but it is on the same network as ADH, which means that it can be found using its hostname.
In the DNS settings, Upstream DNS servers, using [/local/]unbound:53 as an upstream server passes the test "Specified DNS servers are working correctly" but when applying the changes I get Error: control/dns_config | wrong upstreams specification: unbound is not a valid IP | 400

@ainar-g
Copy link
Contributor

ainar-g commented Jan 4, 2022

Hello and thank you for your report!

It seems like there are two issues here:

  1. Using hostnames for plain DNS is currently not supported.

    @ameshkov, considering that we have bootstrap IP addresses, perhaps we could add a udp:// scheme support with hostnames?

  2. The upstream test API should indeed validate the domain-specific upstreams as well. That looks like a bug.

@jacktheripper19
Copy link
Author

Ok I see. In that case, do you have an idea of a good way to handle this kind of setup where upstream dns changes ip regularly ?

@ameshkov
Copy link
Member

@jacktheripper19 would it be possible to use TLS on the unbound side? AGH currently will only resolve domain names for encrypted upstreams.

@ameshkov
Copy link
Member

@ainar-g

@ameshkov, considering that we have bootstrap IP addresses, perhaps we could add a udp:// scheme support with hostnames?

Makes sense to me.

adguard pushed a commit that referenced this issue Jan 13, 2022
Merge in DNS/adguard-home from 4074-upstream-test to master

Updates #4074.

Squashed commit of the following:

commit 0de155b
Author: Eugene Burkov <E.Burkov@AdGuard.COM>
Date:   Wed Jan 12 19:20:01 2022 +0500

    dnsforward: fix upstream test
@EugeneOne1
Copy link
Member

@jacktheripper19, we've just pushed the latest build to the edge channel. For the moment it should only invalidate upstream servers like the one in the issue. Could you please check if it properly reports the error and doesn't break testing of other upstream servers you have?

We'll also fill the separate feature request on support the udp:// schema since it needs modifying external libraries.

@EugeneOne1
Copy link
Member

@jacktheripper19, I'll close the issue for now if you don't mind. See #4166 for the status of plain DNS hostnames support.

adguard pushed a commit that referenced this issue Jan 21, 2022
Merge in DNS/adguard-home from 4074-upstream-test to master

Updates #4074.

Squashed commit of the following:

commit 0de155b
Author: Eugene Burkov <E.Burkov@AdGuard.COM>
Date:   Wed Jan 12 19:20:01 2022 +0500

    dnsforward: fix upstream test
heyxkhoa pushed a commit to heyxkhoa/AdGuardHome that referenced this issue Mar 20, 2023
Merge in DNS/adguard-home from 4074-upstream-test to master

Updates AdguardTeam#4074.

Squashed commit of the following:

commit 0de155b
Author: Eugene Burkov <E.Burkov@AdGuard.COM>
Date:   Wed Jan 12 19:20:01 2022 +0500

    dnsforward: fix upstream test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants