-zsh ~ % which openssl
/usr/bin/openssl
-zsh ~ % openssl version
LibreSSL 2.8.3
-zsh ~ %
-zsh ~ % brew install openssl
(snip)
openssl@3 is keg-only, which means it was not symlinked into /opt/homebrew,
because macOS provides LibreSSL.
If you need to have openssl@3 first in your PATH, run:
echo 'export PATH="/opt/homebrew/opt/openssl@3/bin:$PATH"' >> ~/.zshrc
(snip)
-zsh ~ % /opt/homebrew/Cellar/openssl@3/3.0.3/bin/openssl version
OpenSSL 3.0.3 3 May 2022 (Library: OpenSSL 3.0.3 3 May 2022)
-zsh ~ % which openssl
/usr/bin/openssl
-zsh ~ %
-zsh ~ % echo 'export PATH="/opt/homebrew/opt/openssl@3/bin:$PATH"' >> ~/.zshrc
-zsh ~ % source ~/.zshrc
-zsh ~ % which openssl
/opt/homebrew/opt/openssl@3/bin/openssl
-zsh ~ % openssl version
OpenSSL 3.0.3 3 May 2022 (Library: OpenSSL 3.0.3 3 May 2022)
-zsh ~ %