Skip to content

Instantly share code, notes, and snippets.

@tonyseek
Last active November 16, 2024 13:12
Show Gist options
  • Save tonyseek/bc5b72197ddb15418c61406061720186 to your computer and use it in GitHub Desktop.
Save tonyseek/bc5b72197ddb15418c61406061720186 to your computer and use it in GitHub Desktop.
Overrides the captive portal settings of Android in the People's Republic China mainland
#!/usr/bin/env sh
## I don't have any devices running Android OS now. These settings may have been outdated but I cannot verify it.
adb shell settings put global captive_portal_fallback_url http://g.cn/generate_204
adb shell settings put global captive_portal_http_url http://www.google.cn/generate_204
adb shell settings put global captive_portal_https_url https://www.google.cn/generate_204
adb shell settings put global captive_portal_other_fallback_urls http://www.qualcomm.cn/generate_204
@yanfeng42
Copy link

Thanks , Bro. From 2023/12/15, With pixel 7 & Android 14, my config:

adb shell
lynx:/ $ settings put global captive_portal_http_url http://connect.rom.miui.com/generate_204
lynx:/ $ settings put global captive_portal_https_url http://connect.rom.miui.com/generate_204

@jacoblyw
Copy link

jacoblyw commented Jan 26, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment