为什么不d httpx ssl上下文设置密码
ctx = httpx.create_ssl_context()
ctx.set_ciphers("TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256:TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256:TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384:TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384:TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256:TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256:TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA:TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA:TLS_RSA_WITH_AES_128_GCM_SHA256:TLS_RSA_WITH_AES_256_GCM_SHA384:TLS_RSA_WITH_AES_128_CBC_SHA:TLS_RSA_WITH_AES_256_CBC_SHA")
那是我从HTTP调试器那里得到的密码套件,但是在运行此操作后,
ssl.SSLError: ('No cipher can be selected.',)
我什至没有提出请求,所以我认为它没有支持?
提前致谢
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要确保那里的每个密码名称都使用OpenSSL为密码命名。
您使用的一个或多个密码可能是“公开”名称,但是OpenSSL为这些密码有自己的名字。
看看映射:
You need to ensure that every single cipher name there use OpenSSL's naming for the ciphers.
There's a possibility one or more of the ciphers you used there are the "public" names, but OpenSSL has their own names for those ciphers.
Take a look at this for the mapping:
https://www.openssl.org/docs/man1.1.1/man1/ciphers.html