CentOS7编译安装openssl-1.1.1d

CentOS7编译安装openssl-1.1.1d

openssl官网

centos7默认提供的openssl版本是1.0.2的,想要升级openssl版本则需要手动进行编译

1、下载openssl

cd /usr/local/src/
wget https://www.openssl.org/source/openssl-1.1.1d.tar.gz
tar xf openssl-1.1.1d.tar.gz

2、编译openssl

cd openssl-1.1.1d
./config
make && make install

3、配置

注意:默认编译后,查看当前openssl版本号时,你会发现还是1.0.2,所以这里需要做一些额外的配置工作

openssl version
openssl: error while loading shared libraries: libssl.so.1.1: cannot open shared object file: No such file or directory
echo "/usr/local/lib64/" >> /etc/ld.so.conf
ldconfig
mv /usr/bin/openssl /usr/bin/openssl.old
ln -sv /usr/local/bin/openssl /usr/bin/openssl

4、验证

openssl version
OpenSSL 1.1.1d  10 Sep 2019
posted @ 2020-10-08 13:46  aitansi  阅读(847)  评论(0编辑  收藏  举报