是否可以通过在 Android 应用程序中检查浏览器密码来检查 wifi 网络是否受到保护?
最佳答案
来自 HttpURLConnection
的文档:
Some Wi-Fi networks block Internet access until the user clicks through a sign-on page. Such sign-on pages are typically presented by using HTTP redirects. You can use getURL() to test if your connection has been unexpectedly redirected. This check is not valid until after the response headers have been received, which you can trigger by calling getHeaderFields() or getInputStream().
关于android - 如何检查 wifi 网络是否受到 Android 应用程序中浏览器密码检查的保护?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8487764/