Added bug fixes and new functions to openssl.py