I have used brew install openssl to download and install openssl v1.0.2f, however, it comes back saying:
brew install openssl
A CA file has been bootstrapped using c
Try creating a symlink, make sure you have openssl installed in /usr/local/include first.
/usr/local/include
ln -s /usr/local/Cellar/openssl/{version}/include/openssl /usr/local/include/openssl
More info at Openssl with El Capitan.