I've tried to install a new version of OpenSSL via Homebrew but it doesn't work. My actual OpenSSL version is 0.9.8 and I don't know what to do.
When I type on MacOS 10.8.4 brew install openssl the system brings to me the following error:
Error: openssl-1.0.1e already installed
So when I type openssl version I see this:
OpenSSL 0.9.8x 10 May 2012
How can I turn the actual version to the new version installed via Homebrew? Any tips?
My guess is that OS X has an older version of openssl in /usr/bin, and Homebrew places it's version in /usr/local/bin
Try
/usr/local/bin/openssl version
Edit: Before you try the above command, run:
brew link --force openssl
Related
I have ruby version 2.1.5 installed on my system.
On running bundle install, I am getting
"Could not load OpenSSL.
You must recompile Ruby with OpenSSL support or change the sources in your Gemfile from 'https' to 'http'. Instructions for compiling with OpenSSL using RVM are available at
http://rvm.io/packages/openssl."
My Gemfile has soures with http only.
On executing "rvm pkg install openssl" :
==> Formulae
curl-openssl glib-openssl openssl#1.1 ✔ homebrew/portable-ruby/portable-openssl
There is no openssl#1.0 and openssl
How to degrade to openssl#1.0 from 1.0.
Already tried rvm reinstall 2.1.5 --with-openssl-dir=brew --prefix openssl#1.0
But it is of no use for me.
The previous solution doesn't work any more, I have succeeded with the following steps:
brew install rbenv/tap/openssl#1.0
ln -sfn /usr/local/Cellar/openssl#1.0/1.0.2t /usr/local/opt/openssl
I've seen this issue on rvm project where you can find more detail about this.
This step works for me, we have to wait for some official fix.
Install openssl via rvm pkg install openssl
Remove and reinstall rubies with rvm reinstall 2.1.5
--with-openssl-dir=$HOME/.rvm/usr
I have tried the solution on Mac OS X Catalina and it works.
Download the file: https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb
Run brew with the file downloaded: brew install openssl.rb
I need your help :)
I have mac os x 10.11.2,
And I have updated openssl library:
brew update
brew install openssl
brew link --force openssl.
After command "openssl version" I saw: OpenSSL 1.0.2h 3 May 2016
But after command "php -i | grep -i ssl" I saw:
OpenSSL Library Version => OpenSSL 0.9.8zg 14 July 2015
OpenSSL Header Version => OpenSSL 0.9.8zc 19 Mar 2015
And I can't install composer, get error: The OpenSSL library (0.9.8zc) used by PHP does not support TLSv1.2 or TLSv1.1.
How can I resolve it? It really strange...
PHP and OpenSSL are also present in the Mac OS X system.
The fact that you have installed a second version via Homebrew does not mean it will automaically be used. you will need to make sure that composer finds the version provided by Homebrew (installed in /usr/local/).
I'm working on OS X 10.11.4. I'm trying to get started with Zend Framework2 and am using the official manual so have installed composer. When installing composer I got this warning:
The OpenSSL library (0.9.8zc) used by PHP does not support TLSv1.2 or
TLSv1.1. If possible you should upgrade OpenSSL to version 1.0.1 or
above.
So I opened Terminal and used the following to check my openssl version:
$ openssl version
OpenSSL 0.9.8zh 14 Jan 2016
So I looked into updating and came across How to upgrade OpenSSL in OS X on the Apple Stack Exchange. I then used the following to update HomeBrew and install the latest version of OpenSSL
$ brew update
$ brew install openssl
But got this warning:
Warning: openssl-1.0.2g already installed
So then I followed this advice (Update OpenSSL on OS X with Homebrew - top answer)
$ brew unlink openssl && brew link openssl --force
Unlinking /usr/local/Cellar/openssl/1.0.2g... 1591 symlinks removed
Linking /usr/local/Cellar/openssl/1.0.2g... 1588 symlinks created
$ which openssl
/usr/local/bin/openssl
$ openssl version
OpenSSL 0.9.8zh 14 Jan 2016
So it seems I have the updated version on my machine but it isn't being used by default?
Sorry for my naivety but I'm a complete beginner.
Can any one tell me what I'm doing wrong?
Thanks in advance
When I run: rvmsudo passenger-install-nginx-module on my Mac to install nginx, the terminal prints:
Checking for OpenSSL development headers...
Found: no
But I am certain I have openssl installed. which openssl returns /usr/local/openssl/bin/openssl and /usr/local/openssl/bin: is the first entry in my $PATH. My questions are:
Are the OpenSSL development headers included with the regular openssl install through homebrew?
If they aren't, where should I download them from?
If brew link openssl --force gives you this message:
Warning: Refusing to link: openssl Linking keg-only openssl means you may end up linking against the insecure, deprecated system OpenSSL while using the headers from Homebrew's openssl. Instead, pass the full include/library paths to your compiler e.g.: -I/usr/local/opt/openssl/include -L/usr/local/opt/openssl/lib
Try this:
$ brew doctor (now fix anything that it tells you to fix)
$ brew update
$ brew upgrade
Now let's install it:
$ brew install openssl
And now we'll link it into our public area so you don't have to figure out the magic environment variable to set while building your favorite OpenSSL-backed library:
$ cd /usr/local/include
$ ln -s ../opt/openssl/include/openssl .
All done! Enjoy
If you are on Mac OS X El Capitan, Apple doesn't include openssl any more because of security problems openssl had, I have similar problem installing Passenger. brew just installs openssl itself without development headers.
If you are on an older version of Mac OS X than El Capitan, you can use:
xcode-select --install
which installs openssl development headers as well.
EDIT:
Updating brew and installing openssl and force linking openssl to brew version solved my problem:
$ brew update
$ which openssl
/usr/bin/openssl
$ brew install openssl
$ brew link openssl --force
$ which openssl
/usr/local/bin/openssl
I just typed openssl version in terminal and I got following result:
OpenSSL 0.9.8y 5 Feb 2013
So I ran brew update and brew upgrade openssl.
Which the first one returned Updated Homebrew from 7afeb3af to 8cabfe85., And second one returned openssl-1.0.1g already installed.
So typed brew link --force openssl.
After above procedure I typed openssl version And I got the same result
OpenSSL 0.9.8y 5 Feb 2013.
How can I update openssl on mac osx 10.9.3?
Run brew info openssl and follow the instructions there. Do not try to --force link the latest openssl with the one that comes installed with OSX by default. (0.9.8)
Specifically it'll ask you to add the Homebrew version of openssl (should be 1.0.2 as of this date) into your $PATH.
echo 'export PATH="/usr/local/opt/openssl/bin:$PATH"' >> ~/.bash_profile
Note: Make sure to remove any export PATH lines from the bash_profile, since this line above exports it for you appending the rest of the $PATH variable to the end. To view the bash profile use vi ~/.bash_profile
Doing this should fix any problems with installing packages (especially Ruby Gems that need compiling).
So here's what is going on. You have two copies of OpenSSL.
Version 0.9.8 - located at /usr/bin/openssl, pre-installed on OS X
Version 1.0.1g - located at /usr/local/Cellar/openssl/1.0.1h/bin/openssl, installed by brew.
When you ran brew upgrade openssl, you actually ran brew install openssl since brew had not yet install openssl on your system. (Remember, brew doesn't control all the software on your computer - only what it installed).
Turns out that the message of brew install openssl:
==> Caveats
A CA file has been bootstrapped using certificates from the system
keychain. To add additional certificates, place .pem files in
/usr/local/etc/openssl/certs
and run
/usr/local/opt/openssl/bin/c_rehash
This formula is keg-only, so it was not symlinked into /usr/local.
Mac OS X already provides this software and installing another version in
parallel can cause all kinds of trouble.
The OpenSSL provided by OS X is too old for some software.
Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:
LDFLAGS: -L/usr/local/opt/openssl/lib
CPPFLAGS: -I/usr/local/opt/openssl/include
This actually explains that OS X comes preinstalled. Using a different non-system openssl may cause issues if you change from the default openssl. Hence, brew kindly did not link it into your /usr/local which is probably part of your path.
I presume you wanted to upgrade the openssl on you box because some package you were trying to install required a newer version. Ahoy - the message tells you that you should install that software package and point it at your new shiny brew openssl.