For anyone looking to automatically set DNS servers and enable DoH for every relevant network interface, I wrote the following batch script:
@echo off
rem Set the DNS servers to be applied to each interface.
set IPv4PrimaryDNS=1.1.1.1
set IPv4SecondaryDNS=1.0.0.1
set...
Appreciate the help. I was able to write a batch script that automatically sets given DNS servers and enables DoH on every relevant network interface for both IPv4 and IPv6. We can get the interface IDs and indexes from wmic nic and use that to set DNS with netsh. For my use case, I just want to...
Unfortunately that doesn't actually enable DoH. It sets the primary/secondary DNS as expected, but I still have to go into settings and manually toggle on DoH.
Is there a way to set DNS over HTTPS via netsh or wmic? I know you can add additional DoH templates via netsh, and I know you can set DNS, but I can't figure out if there's a way to actually set DNS + activate DoH without going into settings.
In other words, I'd like to do this via command...