OpenSSL provides support for the TLS and SSL protocols, and also includes various tools used in cryptography. Note that OpenSSL is officially available only as source, so you must manually compile and install the software on your Mac.
I have used brew install openssl
to download and install openssl v1.0.2f, however, it comes back saying:
And when I do openssl version -a
it always gives me:
How can I replace the old version with the new one? I've searched a lot on how to do this, but the solutions online don't seem to work for me...
TometoyouTometoyou7 Answers
Mac Openssl Library
Execute following commands:
You will have the latest version of openssl installed and accessible from cli (command line/terminal). Since the third command will add export path to .bash_profile
, the newly installed version of openssl will be accessible across system restarts.
Try creating a symlink, make sure you have openssl installed in /usr/local/include
first.
More info at Openssl with El Capitan.
zlwaterfieldzlwaterfieldI reached this page when I searched for information about openssl being keg-only. I believe I have understood the reason why Homebrew is taking this action now. My solution may work for you:
Use the following command to make the new openssl command available (assuming you have adjusted PATH to put /usr/local/bin before /usr/bin):
ln -s /usr/local/opt/openssl/bin/openssl /usr/local/bin/
When compiling with openssl, follow Homebrew's advice and use
-I/usr/local/opt/openssl/include -L/usr/local/opt/openssl/lib
Alternatively, you can make these settings permanent by putting the following lines in your .bash_profile or .bashrc:
export CPATH=/usr/local/opt/openssl/includeexport LIBRARY_PATH=/usr/local/opt/openssl/lib
I can't reproduce your issue running El Cap + Homebrew 1.0.x
Upgrade to Homebrew 1.0.x, which was released late in September. Specific changes were made in the way openssl is linked. The project is on a more robust release schedule now that it's hit 1.0.
You should fix any issues raised by brew doctor
before proceeding.
Note:Upgrading homebrew will update all your installed packages to their latest versions.
JakeGouldYou can run brew link openssl
to link it into /usr/local
, if you don't mind the potential problem highlighted in the warning message. Otherwise, you can add the openssl bin directory to your path:
Mac Upgrade Openssl
To replace the old version with the new one, you need to change the link for it. Type that command to terminal.
Check the version of openssl again. It should be changed.
Not the answer you're looking for? Browse other questions tagged macosopensslhomebrew or ask your own question.
I tried to install openSSL to my MAC but I did not. I watched the steps below, but I could not understand exactly what you should do. I am a new mac user. Please tell us about what to do as a simple
Step 1) Download OpenSSL 0.9.6c here: http://www.openssl.org/source/openssl-0.9.6c.tar.gz
Step 2) Uncompress the archive and rename the resulting folder 'openssl'
step 3) Open up the terminal and type cd /users/YOURUSERNAME/desktop/
step 4) type sudo mv openssh /usr/local/
step 5) type sudo cd /usr/local/openssl
step 6) type ./config
step 7) type make
step 8) type make install
jwwOpenssl Software For Mac
1 Answer
Download OpenSSL 0.9.6c here
Man, 0.9.6 is old. Are you sure you want/need it?
Here's the recipe using OpenSSL 1.0.1f:
If you are on an old 32-bit Mac, then use ./Configure darwin-i386-cc
.
There's no need to build in /usr/local
using sudo
. In fact, its preferred to compile under an unprivileged account and only elevate during install.
OpenSSL comes with 0.9.8. To ensure you use the copy of OpenSSL you just downloaded, built and installed:
The trick is that OpenSSL installs into /usr/local/ssl
. So you find headers in /usr/local/ssl/include
and libraries in /usr/local/ssl/lib
.