V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
httpbin - 协议调试工具
httpstatuses - 协议状态码查询
httpie - cURL-like tool for humans
Fiddler
wwjvtwoex
V2EX  ›  HTTP

百度的 https 正常吗?

  •  
  •   wwjvtwoex · 2017-10-09 16:51:55 +08:00 · 3396 次点击
    这是一个创建于 2388 天前的主题,其中的信息可能已经有所发展或是发生改变。

    使用 Python 的 urllib2.urlopen('https://www.baidu.com').read()

    取到的 html 字符串


    <html><head><script>

    location.replace(location.href.replace("https://","http://"));

    </script></head><body><noscript>

    <meta http-equiv="refresh" content="0;url=http://www.baidu.com/">

    </noscript></body></html>


    这是正常的 https 站点吗?

    3 条回复    2019-01-26 21:10:41 +08:00
    nazor
        1
    nazor  
       2017-10-09 16:54:31 +08:00   ❤️ 1
    ...你 user-agent 的问题
    wwjvtwoex
        2
    wwjvtwoex  
    OP
       2017-10-09 16:57:43 +08:00
    谢谢,回头学习一下
    dooonabe
        3
    dooonabe  
       2019-01-26 21:10:41 +08:00
    微信小程序访问 baidu 的接口时,android 端没有问题,ios 端也是会有上述这个问题,不太像 user-agent 的问题
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   4058 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 10:18 · PVG 18:18 · LAX 03:18 · JFK 06:18
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.