Skip to content

Instantly share code, notes, and snippets.

@raj-sharma-git
Forked from sharunkumar/adb-dns.bat
Created August 26, 2023 07:23
Show Gist options
  • Save raj-sharma-git/5ca1985687a2a6f0902a07eea1fb5d07 to your computer and use it in GitHub Desktop.
Save raj-sharma-git/5ca1985687a2a6f0902a07eea1fb5d07 to your computer and use it in GitHub Desktop.
Enabling / Disabling private DNS in android via ADB
rem to disable private dns
adb shell settings put global private_dns_mode off
rem to enable private dns with hostname (example with dns.adguard.com)
adb shell settings put global private_dns_mode hostname
adb shell settings put global private_dns_specifier dns.adguard.com
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment