V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
yepinf
V2EX  ›  Python

https 登录的网站(非全站 https)如何模拟登录?

  •  
  •   yepinf · 2015-02-18 11:28:47 +08:00 · 5418 次点击
    这是一个创建于 3368 天前的主题,其中的信息可能已经有所发展或是发生改变。
    https登录的网站(非全站https)如何模拟登录?
    比如豆瓣这种
    大家有木有比较完美的方案 :D
    6 条回复    2015-03-02 09:57:25 +08:00
    arkilis
        1
    arkilis  
       2015-02-18 11:45:35 +08:00
    Grap the certificate and use curl:
    i.e.
    curl --cacert /path/to/your/CA/file.crt https://...
    ljcarsenal
        2
    ljcarsenal  
       2015-02-18 12:06:35 +08:00
    先登录,抓cookie。
    denghongcai
        3
    denghongcai  
       2015-02-18 13:17:06 +08:00
    和 http 的没区别,一样来就行了
    wdlth
        4
    wdlth  
       2015-02-18 21:32:46 +08:00
    除非是验证证书的,不然https和http的方法可以看作是一样的,只不过https采用加密的传输协议,防止数据被中间人嗅探、修改等。
    killerv
        5
    killerv  
       2015-02-20 20:00:38 +08:00
    应该没区别吧,使用cookielib就可以了,话说豆瓣是HTTPS吗?
    tolerious
        6
    tolerious  
       2015-03-02 09:57:25 +08:00 via iPhone
    搜下怎么进行CA的认证登陆
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   1230 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 521ms · UTC 18:19 · PVG 02:19 · LAX 11:19 · JFK 14:19
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.