Update your openssl version on Mac OS X using Brew

Just thought of putting something across for future use. How do you update your openssl version on mac.

By default the openssl version is 0.9.8 and we know that ain’t the current standard.

So first step.go to brew.sh and find this particular link. Click and paste on your terminal
ruby -e “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)”

Next, do a update check.
brew install wget

In particular, you can use this script; brew install openssl

To check if the version was updated, you then use openssl version -a

I am not sure about this line, but you can try if this line works to enforce the openssl upgrade.
brew link –force openssl

If its not updated, then you will probably have to manually enforce it, then what you do is scroll up the page and check where the latest openssl is installed. For me it was in the /usr/local/bin/openssl
Next thing to do is to create a local backup, you can use the mv /usr/local/bin/openssl /usr/local/bin/openssl_OLD

Once that is done, you can now create a symlink using the ln -s command. The new openssl is probably located in /usr/local/Cellar/opensslx. figures brew and cellar (smile)

You then, place this command on your cli.
ln -s /usr/local/Cellar/openssl/1.0.2e_1/bin/openssl /usr/local/bin/openssl

In some cases the openssl might be in the /usr/bin/openssl instead. so be careful.

Next thing you do, you turn off the terminal and get back on it, type openssl version -a   It should be there now.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s