查看openssl.cnf位置
(资料图片)
find /etc/ -name openssl.cnf -printf "%h\n"
/etc/pki/tls
编译安装openssl-1.1.1n
curl -O http://artfiles.org/openssl.org/source/openssl-1.1.1n.tar.gz
tar zxf openssl-1.1.1n.tar.gz
cd openssl-1.1.1n
./config --prefix=/usr/local/openssl --libdir=lib --openssldir=/etc/pki/tls
make -j1 depend
make -j8
make install_sw
备份原配置
mv /usr/bin/openssl /usr/bin/openssl.bak
mv /usr/include/openssl /usr/include/openssl.bak
链接配置
#将安装好的openssl 的openssl命令软连到/usr/bin/openssl
ln -s /usr/local/openssl/bin/openssl /usr/bin/openssl
ln -s /usr/local/openssl/include/openssl /usr/include/openssl
修改系统配置
echo "/usr/local/openssl/lib/" >> /etc/ld.so.conf
ldconfig -v
查看openssl版本
openssl version
OpenSSL 1.1.1n 15 Mar 2022
标签: 系统配置