• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

DoH redirect to unbound resolver?

Scheduled Pinned Locked Moved DHCP and DNS
9 Posts 3 Posters 1.2k Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J
    JonathanLee
    last edited by JonathanLee Jul 6, 2023, 6:44 AM Jul 6, 2023, 6:42 AM

    Hello fellow Netgate community members,
    Can you please help?

    DoH and DoT accomplish the same thing right? Just use of TLS. DoH uses port 443 while DoT use 853. My question is if I want to let the unbound DNS resolver resolve both requests can I? I want to configure DoH over the unbound DNS resolver nust to learn how to it. Do I just add in the loop back to custom options @443 or other items for this? I have root SSL certificates installed. The reference said it needs the libnghttp2 library, is that already installed in PfSense? My goal here is to take my huge squidguard DoH list and redirect it over to the unbound resolver that way when the proxy gets hits on the DoH requests the DoH can run on the firewall It should work right just like Nat? I have a proxy running, all other traffic not resolving to DoH servers should just pass normally. I should see both DoH 443 and 853 DNS info on the Squid proxy and keep doing inspection of bad guy traffic that way. I have noticed no matter what I do for DNS nat and all browsers and even Apple software attempt their DoH to bypass the proxy. Goal here is to redirect requests for some DoH sites right back to unbounds DoH DNS resolver, while still running my 853 and 53 options.

    Any thoughts?

    DoH can be resolved by unbound resolver see below.

    Ref:
    Https://blog.nlnetlabs.nl/dns-over-https-in-unbound/

    Make sure to upvote

    K 1 Reply Last reply Jul 6, 2023, 11:03 AM Reply Quote 0
    • K
      keyser Rebel Alliance @JonathanLee
      last edited by Jul 6, 2023, 11:03 AM

      @JonathanLee said in DoH redirect to unbound resolver?:

      Hello fellow Netgate community members,
      Can you please help?

      DoH and DoT accomplish the same thing right? Just use of TLS. DoH uses port 443 while DoT use 853. My question is if I want to let the unbound DNS resolver resolve both requests can I? I want to configure DoH over the unbound DNS resolver nust to learn how to it. Do I just add in the loop back to custom options @443 or other items for this? I have root SSL certificates installed. The reference said it needs the libnghttp2 library, is that already installed in PfSense? My goal here is to take my huge squidguard DoH list and redirect it over to the unbound resolver that way when the proxy gets hits on the DoH requests the DoH can run on the firewall It should work right just like Nat? I have a proxy running, all other traffic not resolving to DoH servers should just pass normally. I should see both DoH 443 and 853 DNS info on the Squid proxy and keep doing inspection of bad guy traffic that way. I have noticed no matter what I do for DNS nat and all browsers and even Apple software attempt their DoH to bypass the proxy. Goal here is to redirect requests for some DoH sites right back to unbounds DoH DNS resolver, while still running my 853 and 53 options.

      Any thoughts?

      DoH can be resolved by unbound resolver see below.

      Ref:
      Https://blog.nlnetlabs.nl/dns-over-https-in-unbound/

      No, not without some serious complications. DoH and DoT uses sertificate infrastructure to validate you are talking to whom you want to be talking to. So if you do a proxy redirect (or NAT redirect), the clients will no longer see the hostname and public certificate they expect when "calling" upon the DoH/DoT DNS servers.
      The only way it perhaps will work is if you have control over the clients and can install your own root CA certificate on them, and then have your proxy do MITM (man in the Middle) and issue a fake certificates based on your own Root CA for the intended DoT/DoH servers. I'm not even sure that will work as Google, Apple and MS might have built in which SPECIFIC CA in their own browser should answer the DoT/DoH sessions - regardless of what you do.

      Love the no fuss of using the official appliances :-)

      J 1 Reply Last reply Jul 6, 2023, 12:50 PM Reply Quote 0
      • J
        JonathanLee @keyser
        last edited by JonathanLee Jul 6, 2023, 1:06 PM Jul 6, 2023, 12:50 PM

        @keyser sorry I forgot to mention, I have root CA installed on all of them. They are all my hardware. SSL intercept is enabled and in use for the proxy. Not "fake" certificates, it's approved certificates, the public ones end at the firewall, and private certificates are issued use after. That link does it with root CA certificates. I am starting to wonder what other privacy violation fines will be issued once someone figures this out. Last month Google was hit with a 23 million dollar fine for privacy violation with users data, maybe they are back at it with new ways to play hide and seek. It seems like some browsers all the sudden want to avoid the DNS they are set to use with private ca root certificates installed set to trust. Now all the sudden they keep asking for DoH to flat bypass the firewalls security. So DoH SSL intercept may be the next tool for cyber security. It's not fake certificates they are approved certificates don't get me wrong.

        The Unbound DoH directions use SSL intercept, I just wonder do I add in the ones I am using already.

        Make sure to upvote

        K 2 Replies Last reply Jul 6, 2023, 3:52 PM Reply Quote 0
        • K
          keyser Rebel Alliance @JonathanLee
          last edited by Jul 6, 2023, 3:52 PM

          @JonathanLee Yeah I know fake might be the wrong word - lets call them replacement certificates instead.

          But otherwise you are correct. It’s a slippery slide we on to be completely owned by the 5 big IT corps in the world - they have no limits or morale other than $$$.

          I would be interested in knowing if you can get it to work. I haven’t tried it myself.

          Love the no fuss of using the official appliances :-)

          1 Reply Last reply Reply Quote 1
          • K
            keyser Rebel Alliance @JonathanLee
            last edited by Jul 6, 2023, 3:56 PM

            @JonathanLee We will know when they are really going all in. That’s when their DoH/DoT servers gets relocated to their primary customer URL (fx. Google.com/gmail.com and microsoft.com/office.com).
            That way it gets REALLY hard to filter them out because simple SNI URL bloking or IP address blocking will no longer cut it.

            Love the no fuss of using the official appliances :-)

            J 1 Reply Last reply Jul 6, 2023, 7:08 PM Reply Quote 0
            • J
              JonathanLee @keyser
              last edited by Jul 6, 2023, 7:08 PM

              @keyser Have you seen dns.google yet? I have been seeing all the time as of a couple months ago. I went to Edge because of it. They got to have options for security requirements in Chrome. Firefox you can add all sorts of setting to it. Edge just uses the root CA and works.

              Screenshot 2023-07-06 at 7.41.02 AM.png

              dns.google ?? why not use my DNS I have configured on the OS with my root ca?

              Make sure to upvote

              J 1 Reply Last reply Jul 6, 2023, 8:58 PM Reply Quote 0
              • J
                johnpoz LAYER 8 Global Moderator @JonathanLee
                last edited by Jul 6, 2023, 8:58 PM

                @JonathanLee said in DoH redirect to unbound resolver?:

                why not use my DNS I have configured on the OS

                Because they know better than you ;) and you should be using their dns - you know to protect your privary <rolleyes>

                Many browsers love to default to doh - and you have to jump through hoops to turn it off quite often. I don't have a problem with a browser offering to do doh, but it should be a very explicit opt in, not opt out..

                The user should have to on purpose click to use it.. Which is why I block the shit out of it..

                An intelligent man is sometimes forced to be drunk to spend time with his fools
                If you get confused: Listen to the Music Play
                Please don't Chat/PM me for help, unless mod related
                SG-4860 24.11 | Lab VMs 2.8, 24.11

                J 1 Reply Last reply Jul 7, 2023, 3:05 AM Reply Quote 2
                • J
                  JonathanLee @johnpoz
                  last edited by Jul 7, 2023, 3:05 AM

                  @johnpoz I also block it I have a huge list in Squidguard as well as a Blacklist provided list. Check it out,
                  Screenshot 2023-07-06 at 8.01.45 PM.png
                  (DoH block list for Squidguard)

                  Screenshot 2023-07-06 at 8.04.43 PM.png
                  (Using the interface add for DoH for research)

                  Screenshot 2023-07-06 at 7.50.16 PM.png
                  (Unbound to 127.0.0.1 at 443 working)

                  Screenshot 2023-07-06 at 7.51.38 PM.png
                  (Fastest resolver now is 127.0.0.1 it seems )

                  Again I wanted to share this too as I am a bit confused here.
                  Screenshot 2023-07-06 at 7.59.19 PM.png
                  ( I think I should have some entries as I used dnsfail urls to test yesterday)

                  Make sure to upvote

                  J 1 Reply Last reply Jul 7, 2023, 9:20 AM Reply Quote 0
                  • J
                    johnpoz LAYER 8 Global Moderator @JonathanLee
                    last edited by Jul 7, 2023, 9:20 AM

                    @JonathanLee when your forwarding? Why would stuff be lame? Lame has to do with delegation and is used when you resolve.

                    You normally even when resolving shouldn't have stuff there.. Other than maybe edns lame..

                    An intelligent man is sometimes forced to be drunk to spend time with his fools
                    If you get confused: Listen to the Music Play
                    Please don't Chat/PM me for help, unless mod related
                    SG-4860 24.11 | Lab VMs 2.8, 24.11

                    1 Reply Last reply Reply Quote 1
                    9 out of 9
                    • First post
                      9/9
                      Last post
                    Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
                      This community forum collects and processes your personal information.
                      consent.not_received