SSL在CherryPy中不起作用 [英] SSL not working in CherryPy

查看:35
本文介绍了SSL在CherryPy中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我似乎已经按照文档完成了所有操作,但SSL不能正常工作.
这是我的CherryPy settings.conf :

I've seemingly done everything according to docs but SSL just does not work.
Here's my CherryPy settings.conf:

[global]
request.show_tracebacks = False
server.socket_port = 443
server.thread_pool = 10
log.screen = True
log.error_file = '/root/website/Web.log'
log.access_file = '/root/website/Access.log'
cherrypy.server.ssl_module = 'pyopenssl'
cherrypy.server.ssl_certificate = "/etc/ssl/website/AddTrustExternalCARoot.crt"
cherrypy.server.ssl_private_key = "/etc/ssl/website/btcontract_com.key"
cherrypy.server.ssl_certificate_chain = "/etc/ssl/website/chain.crt"  

如果我尝试在浏览器中加载 site.com:443 ,则无需使用证书即可正常运行.
如果我尝试 https://site.com ,浏览器将显示SSL连接错误.

If I try to load site.com:443 in browser it works without using a certificate.
If I try https://site.com the browser says there's an SSL connect error.

CherryPy 错误和连接日志完全不包含任何内容,就好像没有收到这些 https 请求一样.我不确定我的python是否内置了SSL支持,所以我确实安装了 pyOpenSSL .发生了什么事,我该如何解决?

CherryPy error and connection logs contain nothing at all as if it does not even getting these https requests. I'm not sure if my python has built in SSL support so I did installed pyOpenSSL. What's going on and how can I fix this?

推荐答案

3.2.5版中的一项更改破坏了对SSL的支持.尚未修复(从3.6.0版开始),但是问题1298 (如果您需要使用以下版本之一).

There was a change in version 3.2.5 that broke SSL support. This hasn't been fixed yet (as of version 3.6.0), but there is a patch suggested in issue 1298 if you need to use one of these versions.

这篇关于SSL在CherryPy中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆