[dnsdist] DoH: 302 redirecting / to a help page

Andrew skeffling at gmail.com
Mon Sep 16 09:03:05 UTC 2019


Hi everyone,

I'm using dnsdist 1.4.0-rc2 and will be running it as a DoH proxy for my
users.

I have the url as /dns-query in my addDOHLocal config, and in the case that
users put the domain name in to their browser address bar I'm wanting to
redirect request to / to my help page.

ie:
  https://doh.mydomain.com/dns-query - for DoH lookups
  https://doh.mydomain.com/ - redirect to another URL

I'm thinking I need to use newDOHResponseMapEntry for  this, but I'm unsure
how to add this to my config.

This is what I'm trying (and failing with):

 supportpage = newDOHResponseMapEntry("/", 302, "https://support.mydoman.com
")
 setResponsesMap(supportpage)

Any help appreciated.

Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.powerdns.com/pipermail/dnsdist/attachments/20190916/ff63d35e/attachment.htm>


More information about the dnsdist mailing list