From the tests:

from OpenSSL import SSL

Response to the edit: pip install pyopenssl should have installed six. If you're trying to install yourself, I'd not do this, but you can install the dependencies manually using pip install six cryptography and then your import should work fine. If not, leave a comment and I'll do some further investigation.

Response to comment: There are instructions on installing pip on windows.

Answer from hd1 on Stack Overflow
🌐
PyPI
pypi.org › project › pyOpenSSL
pyOpenSSL · PyPI
Note: The Python Cryptographic Authority strongly suggests the use of pyca/cryptography where possible. If you are using pyOpenSSL for anything other than making a TLS connection you should move to cryptography and drop your pyOpenSSL dependency. High-level wrapper around a subset of the OpenSSL library.
      » pip install pyOpenSSL
    
Published   Apr 24, 2026
Version   26.1.0
🌐
Pyopenssl
pyopenssl.org
Welcome to pyOpenSSL’s documentation! — pyOpenSSL 26.1.0 documentation
OpenSSL — Python interface to OpenSSL · crypto — Generic cryptographic module · SSL — An interface to the SSL-specific parts of OpenSSL · Internals · Exceptions · Callbacks · Accessing Socket Methods · Backward Compatibility · Versioning Policy ·
🌐
GitHub
github.com › pyca › pyopenssl
GitHub - pyca/pyopenssl: A Python wrapper around the OpenSSL library · GitHub
A Python wrapper around the OpenSSL library. Contribute to pyca/pyopenssl development by creating an account on GitHub.
Starred by 938 users
Forked by 428 users
Languages   Python
🌐
Pyopenssl
pyopenssl.org › en › latest › api.html
OpenSSL — Python interface to OpenSSL — pyOpenSSL 26.0.0 documentation
OpenSSL — Python interface to OpenSSL · View page source · This package provides a high-level interface to the functions in the OpenSSL library. The following modules are defined: crypto — Generic cryptographic module · Elliptic curves · Serialization and deserialization ·
🌐
Python
docs.python.org › 3 › library › ssl.html
ssl — TLS/SSL wrapper for socket objects — Python 3.14.4 ...
In the Python use of certificates, a client or server can use a certificate to prove who they are. The other side of a network connection can also be required to produce a certificate, and that certificate can be validated to the satisfaction of the client or server that requires such validation. The connection attempt can be set to raise an exception if the validation fails. Validation is done automatically, by the underlying OpenSSL framework; the application need not concern itself with its mechanics.
🌐
Python.org
discuss.python.org › python help
Python 3.12.1 build can not find the openssl libraries on RHEL9.3 host - Python Help - Discussions on Python.org
March 28, 2024 - openssl seems to be installed on the rhel9 server, but I am not able to find the shared dynamic library libsslxxxx.so anywhere on the host. The command “openssl version” gives back - 3.0.7 and in the OPENSSL_LIBRARY path…
Find elsewhere
🌐
PyPI
pypi.org › project › openssl-python
openssl-python
April 26, 2017 - JavaScript is disabled in your browser. Please enable JavaScript to proceed · A required part of this site couldn’t load. This may be due to a browser extension, network issues, or browser settings. Please check your connection, disable any ad blockers, or try using a different browser
🌐
Python
peps.python.org › pep-0644
PEP 644 – Require OpenSSL 1.1.1 or newer | peps.python.org
This PEP proposes for CPython’s ... incompatible forks, and other TLS libraries are dropped. Python makes use of OpenSSL in hashlib, hmac, and ssl modules....
🌐
Medium
mikail-eliyah.medium.com › openssl-in-python-keys-and-certificates-e304df79ee0f
OpenSSL in Python: Keys and Certificates | by Mi'kail Eli'yah | Medium
March 28, 2024 - #!pip install pyOpenSSL from OpenSSL import crypto, SSL import time # Generate private key key = crypto.PKey() key.generate_key(crypto.TYPE_RSA, key_length_RSA) # Create a certificate signing request for key exchange req =…
🌐
Python.org
discuss.python.org › core development
Our future with OpenSSL - Core Development - Discussions on Python.org
November 28, 2022 - With OpenSSL 1.1.1 reaching EOL 20223-09-11 and from what I can gather folks concerned about OpenSSL 3.0 stability, I think it might be time to start a discuss about weaning ourselves off of OpenSSL as a critical dependency that we have. I know this has been a consistent pain on non-Unix platforms ...
🌐
Delft Stack
delftstack.com › home › howto › python › python openssl
How to Import OpenSSL in Python | Delft Stack
February 26, 2025 - This tutorial demonstrates how to work with OpenSSL in Python, covering methods such as using pyOpenSSL, cryptography, and the OpenSSL command line tool. Learn to create self-signed certificates and manage secure communications effectively.
🌐
GitHub
gist.github.com › vishvananda › 980132c0970f8621bb3c
Using OpenSSL from Python with python-cffi · GitHub
The deprecated-declarations warning suppression is passed into the compiler because the apple has decided to mark all of the OpenSSL EVP routines as deprecated so people will use higher-level encryption functions. The code works fine without the extra_compile_args, but will emit a bunch of warnings on OSX the first time you run it. The last step is simply calling these methods via the object we created with verify. Note that we create a buffer for the resulting data and extract it to a python string using the string method:
🌐
Multani
multani.info › projects › pyopenssl › doc › latex-conversion
Python OpenSSL Manual — pyOpenSSL v0.12 documentation
With thin wrapper I mean that a lot of the object methods do nothing more than calling a corresponding function in the OpenSSL library. The reason pyOpenSSL was created is that the SSL support in the socket module in Python 2.1 (the contemporary version of Python when the pyOpenSSL project ...
🌐
Anaconda.org
anaconda.org › anaconda › pyopenssl
pyopenssl - anaconda | Anaconda.org
March 17, 2026 - pyOpenSSL is a high-level wrapper around a subset of the OpenSSL library. It includes: -SSL.Connection objects, wrapping the methods of Python's portable sockets -Callbacks written in Python -Extensive error-handling mechanism, mirroring OpenSSL's error codes and much more.
🌐
Egenix
egenix.com › products › python › pyOpenSSL
eGenix.com: Products: Python: eGenix.com pyOpenSSL Distribution - Python OpenSSL Interface
November 11, 2016 - It comes with an easy-to-use installer ... authority (CA) root bundles. pyOpenSSL is an open-source Python add-on that allows writing SSL-aware networking applications as as certificate management tools....