34

Ubuntu Update OpenSSL

 5 years ago
source link: https://www.linuxprobe.com/ubuntu-update-openssl.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

适用 Ubuntu14.04/16.04

卸载原有 openssl 版本
# sudo apt-get remove openssl
下载最新源码
# sudo wget https://www.openssl.org/source/openssl-1.1.0f.tar.gz
解压下载的源码
# sudo tar -zxvf openssl-1.1.0f.tar.gz
进入源码目录
# sudo cd openssl-1.1.0f/
配置
# sudo ./config shared --prefix=/usr/local/openssl --openssldir=/usr/lib/openssl
编译并按照
# sudo make && make install
设置环境变量
# sudo vim ~/.bashrc
在最后一行添加export PATH=$PATH:/usr/local/openssl/bin 保存退出
使上面的设置生效
# sudo source ~/.bashrc
创建软连接
# sudo ln -s /usr/local/openssl/lib/libssl.so.1.1 /usr/lib/libssl.so.1.1

# sudo ln -s /usr/local/openssl/lib/libcrypto.so.1.1 /usr/lib/libcrypto.so.1.1 
最后使用 openssl version 校验版本
# openssl version

OpenSSL 1.1.0f  25 May 2017

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK