成功解决RuntimeError: OpenSSL 3.0‘s legacy provider failed to load

报错

RuntimeError: OpenSSL 3.0's legacy provider failed to load. This is a fatal error by default, but cryptography supports running without legacy algorithms by setting the environment variable CRYPTOGRAPHY_OPENSSL_NO_LEGACY. If you did not expect this error, you have likely made a mistake with your OpenSSL configuration.

解决办法

OpenSSL 3.0加载失败: 此错误表明 cryptography 库试图加载OpenSSL 3.0的遗留提供程序,但失败了。错误建议通过设置环境变量 CRYPTOGRAPHY_OPENSSL_NO_LEGACY 来禁用遗留算法。如果你不需要使用遗留算法,可以通过以下方式在运行脚本之前设置环境变量:

python 复制代码
export CRYPTOGRAPHY_OPENSSL_NO_LEGACY=1

或者,如果你确实需要遗留算法,这可能表明你的OpenSSL配置有误。

相关推荐
i_am_a_div_日积月累_15 分钟前
jenkins打包报错
运维·rust·jenkins·jenkins打包报错
一个处女座的暖男程序猿17 分钟前
2G2核服务器安装ES
服务器·elasticsearch·jenkins
GIOTTO情21 分钟前
舆情处置的自动化实践:基于Infoseek舆情系统的技术解析与落地指南
运维·自动化·linq
Thexhy26 分钟前
在 CentOS 7 的 Linux 系统中配置 NFS
linux·运维·学习·centos
咯哦哦哦哦37 分钟前
linux vscode+cmake+clangd
linux·ide·vscode
曹天骄1 小时前
Let’s Encrypt 证书申请与多服务器 HTTPS 配置指南
运维·服务器·https
lang201509281 小时前
如何在 Linux 中获取更多信息
linux·运维·服务器
DeBuggggggg1 小时前
linux 安装Python3.9 且支持SSL
linux·运维·ssl
我是标同学1 小时前
vmware17安装ubuntu2204版本qemu运行armv8处理器uboot运行调试(包括windows)的一些工作
linux·运维·服务器
杨云龙UP1 小时前
【MySQL迁移】MySQL数据库迁移实战(利用mysqldump从Windows 5.7迁至Linux 8.0)
linux·运维·数据库·mysql·mssql