Skip to content

Instantly share code, notes, and snippets.

@nathansgreen
Last active November 4, 2015 19:46
Show Gist options
  • Save nathansgreen/4a52d94047f11ad44266 to your computer and use it in GitHub Desktop.
Save nathansgreen/4a52d94047f11ad44266 to your computer and use it in GitHub Desktop.
Homebrew install Python 2.7.8 with SSLv2 support
cd /usr/local/Library/Formula
# remove no-ssl2 from configure options
vi openssl.rb
brew install openssl --universal
# verify support
/usr/local/opt/openssl/bin/openssl ciphers -ssl2
# I install a separate python 2.7.8 so I can switch between versions as-needed
git checkout 9c9664e -- python.rb
brew install python --universal --with-brewed-openssl
python -c "import ssl; print ssl.OPENSSL_VERSION; print ssl.PROTOCOL_SSLv2"
# clean up #
git reset HEAD python.rb openssl.rb
git checkout -- python.rb openssl.rb
# switch to specific python version
brew switch python 2.7.8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment