7.1.2
谷歌又玩我23333
自7.1.2(开始?),”captive_portal_detection_enabled”设置已被废弃,现在改为了”captive_portal_mode”选项,该选项可设置为以下3种值:
0:彻底禁用检测(Don’t attempt to detect captive portals.)
1:检测到需要登录则弹窗提醒(默认值)(When detecting a captive portal, display a notification that prompts the user to sign in.)
2:检测到需要登录则自动断开此热点并不再自动连接(When detecting a captive portal, immediately disconnect from the network and do not reconnect to that network in the future.)
叹号杀手已经更新以支持该版本。
但愿以后谷歌不要再乱改了233333
感谢 jingyu9575 的帮助 https://github.com/Noisyfox/NoExclamation/issues/2
7.1.1
从7.1.1开始,检测用的服务器地址储存格式发生了变化,改为了:
1 | private static String getCaptivePortalServerHttpsUrl(Context context) { |
以及
1 | public static String getCaptivePortalServerHttpUrl(Context context) { |
可以看到,系统不会自动加入”generate_204″的后缀了,这意味着url可以设计的更加灵活,同时也意味着在设置的时候需要填入完整的url:
1 | adb shell "settings put global captive_portal_https_url https://www.noisyfox.cn/generate_204" |
当然如果只有http的话,可以执行:
1 | adb shell "settings put global captive_portal_use_https 0" |