How to enable a disabled cipher by default in openssl 1.1.0g for my python client

自作多情 提交于 2019-12-25 00:58:54

问题


I am using python ssl library which is built on openssl. I use Ubuntu which has OpenSSL 1.1.0g.

In OpenSSL 1.1.0g the following cipher DES-CBC3-SHA is disabled by default. I need to configure my client with this cipher enabled. I need it for testing. In SSL context, I found some ways that allow enabling some disabled options by default. For example, in this documentation the following negate SSL 3.0 which is disabled by default:

ctx = ssl.create_default_context(Purpose.CLIENT_AUTH)
ctx.options &= ~ssl.OP_NO_SSLv3

How can I enable the cipher I need? I used:

ctx.set_cipher(myciphers)

Where myciphers contains list of ciphers. But this did not help. Because the cipher is disabled by OpenSSL.

How to enable disabled ciphersuites in OpenSSL?

EDIT: Additionally, the python ssl module documentation state 3DES is not enabled by default since version 3.4, and I amusing 3.6:

3DES was dropped from the default cipher string.

I need to enable a 3DES cipher for my client purpose. How to do this? is there any way to do this using the ssl context options?

来源:https://stackoverflow.com/questions/51684190/how-to-enable-a-disabled-cipher-by-default-in-openssl-1-1-0g-for-my-python-clien

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!