华为手机弹认证

2019-06-04  本文已影响0人  古佛青灯度流年

华为P20手机不弹PORTAL问题

环境

portal原理

手机wifi质量检测

跳转测试

    GET /generate_204 HTTP/1.1
    User-Agent: Dalvik/2.1.0 (Linux; U; Android 8.1.0; EML-TL00 Build/HUAWEIEML-TL00)
    Host: connectivitycheck.platform.hicloud.com
    Connection: Keep-Alive
    Accept-Encoding: gzip

    HTTP/1.1 302 Found
    Location: http://192.168.0.1
    Content-Type: text/html; charset=utf-8
    Content-length: 0
    Cache-control: no-cache
    Connection: close

结论:使用302跳转时,手机不会自动弹出PORTAL(无法自动打开http://192.168.0.1)

    GET /generate_204 HTTP/1.1
    User-Agent: Dalvik/2.1.0 (Linux; U; Android 8.1.0; EML-TL00 Build/HUAWEIEML-TL00)
    Host: connectivitycheck.platform.hicloud.com
    Connection: Keep-Alive
    Accept-Encoding: gzip

    HTTP/1.1 200 OK
    Content-Type: text/html
    Content-length: 79
    Connection: keep-alive

    <!DOCTYPE html>
    <script>top.self.location.href=http://192.168.0.1</script>

结论:使用200跳转时,手机会自动弹出PORTAL(自动打开http://192.168.0.1页面)

转自

上一篇 下一篇

猜你喜欢

热点阅读