You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

pyopenssl

Package Overview
Dependencies
Maintainers
3
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pyopenssl - pypi Package Compare versions

Comparing version
23.2.0
to
23.3.0
+32
-0
CHANGELOG.rst

@@ -7,2 +7,34 @@ Changelog

23.3.0 (2023-10-25)
-------------------
Backward-incompatible changes:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Dropped support for Python 3.6.
- The minimum ``cryptography`` version is now 41.0.5.
- Removed ``OpenSSL.crypto.loads_pkcs7`` and ``OpenSSL.crypto.loads_pkcs12`` which had been deprecated for 3 years.
- Added ``OpenSSL.SSL.OP_LEGACY_SERVER_CONNECT`` to allow legacy insecure renegotiation between OpenSSL and unpatched servers.
`#1234 <https://github.com/pyca/pyopenssl/pull/1234>`_.
Deprecations:
^^^^^^^^^^^^^
- Deprecated ``OpenSSL.crypto.PKCS12`` (which was intended to have been deprecated at the same time as ``OpenSSL.crypto.load_pkcs12``).
- Deprecated ``OpenSSL.crypto.NetscapeSPKI``.
- Deprecated ``OpenSSL.crypto.CRL``
- Deprecated ``OpenSSL.crypto.Revoked``
- Deprecated ``OpenSSL.crypto.load_crl`` and ``OpenSSL.crypto.dump_crl``
- Deprecated ``OpenSSL.crypto.sign`` and ``OpenSSL.crypto.verify``
- Deprecated ``OpenSSL.crypto.X509Extension``
Changes:
^^^^^^^^
- Changed ``OpenSSL.crypto.X509Store.add_crl`` to also accept
``cryptography``'s ``x509.CertificateRevocationList`` arguments in addition
to the now deprecated ``OpenSSL.crypto.CRL`` arguments.
- Fixed ``test_set_default_verify_paths`` test so that it is skipped if no
network connection is available.
23.2.0 (2023-05-30)

@@ -9,0 +41,0 @@ -------------------

+0
-14

@@ -71,6 +71,2 @@ .. _openssl-crypto:

.. autofunction:: load_pkcs7_data
.. autofunction:: load_pkcs12
Signing and verifying signatures

@@ -163,4 +159,2 @@ --------------------------------

.. _openssl-pkcs7:
.. py:data:: TYPE_RSA

@@ -171,10 +165,2 @@ TYPE_DSA

PKCS7 objects
-------------
PKCS7 objects have the following methods:
.. autoclass:: PKCS7
:members:
.. _openssl-pkcs12:

@@ -181,0 +167,0 @@

+0
-2

@@ -1,2 +0,1 @@

# -*- coding: utf-8 -*-
#

@@ -19,3 +18,2 @@ # pyOpenSSL documentation build configuration file, created by

HERE = os.path.abspath(os.path.dirname(__file__))

@@ -22,0 +20,0 @@

@@ -17,3 +17,3 @@ .. _intro:

Over the time the standard library's ``ssl`` module improved, never reaching the completeness of pyOpenSSL's API coverage.
Despite `PEP 466`_ many useful features remain Python 3-only and pyOpenSSL remains the only alternative for full-featured TLS code across all noteworthy Python versions from 2.7 through 3.6 and PyPy_.
pyOpenSSL remains the only choice for full-featured TLS code in Python versions 3.7+ and PyPy_.

@@ -26,5 +26,3 @@

Current maintainer and release manager is `Hynek Schlawack`_.
.. include:: ../CONTRIBUTING.rst

@@ -35,5 +33,3 @@

.. _PyPy: http://pypy.org
.. _PEP 466: https://www.python.org/dev/peps/pep-0466/
.. _PyCA: https://github.com/pyca
.. _cryptography: https://github.com/pyca/cryptography
.. _Hynek Schlawack: https://hynek.me/
Metadata-Version: 2.1
Name: pyOpenSSL
Version: 23.2.0
Version: 23.3.0
Summary: Python wrapper module around the OpenSSL library

@@ -17,3 +17,2 @@ Home-page: https://pyopenssl.org/

Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7

@@ -24,2 +23,3 @@ Classifier: Programming Language :: Python :: 3.8

Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython

@@ -30,6 +30,12 @@ Classifier: Programming Language :: Python :: Implementation :: PyPy

Classifier: Topic :: System :: Networking
Requires-Python: >=3.6
Requires-Python: >=3.7
License-File: LICENSE
Requires-Dist: cryptography<42,>=41.0.5
Provides-Extra: test
Requires-Dist: flaky; extra == "test"
Requires-Dist: pretend; extra == "test"
Requires-Dist: pytest>=3.0.1; extra == "test"
Provides-Extra: docs
License-File: LICENSE
Requires-Dist: sphinx!=5.2.0,!=5.2.0.post0,!=7.2.5; extra == "docs"
Requires-Dist: sphinx_rtd_theme; extra == "docs"

@@ -87,2 +93,34 @@ ========================================================

23.3.0 (2023-10-25)
-------------------
Backward-incompatible changes:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Dropped support for Python 3.6.
- The minimum ``cryptography`` version is now 41.0.5.
- Removed ``OpenSSL.crypto.loads_pkcs7`` and ``OpenSSL.crypto.loads_pkcs12`` which had been deprecated for 3 years.
- Added ``OpenSSL.SSL.OP_LEGACY_SERVER_CONNECT`` to allow legacy insecure renegotiation between OpenSSL and unpatched servers.
`#1234 <https://github.com/pyca/pyopenssl/pull/1234>`_.
Deprecations:
^^^^^^^^^^^^^
- Deprecated ``OpenSSL.crypto.PKCS12`` (which was intended to have been deprecated at the same time as ``OpenSSL.crypto.load_pkcs12``).
- Deprecated ``OpenSSL.crypto.NetscapeSPKI``.
- Deprecated ``OpenSSL.crypto.CRL``
- Deprecated ``OpenSSL.crypto.Revoked``
- Deprecated ``OpenSSL.crypto.load_crl`` and ``OpenSSL.crypto.dump_crl``
- Deprecated ``OpenSSL.crypto.sign`` and ``OpenSSL.crypto.verify``
- Deprecated ``OpenSSL.crypto.X509Extension``
Changes:
^^^^^^^^
- Changed ``OpenSSL.crypto.X509Store.add_crl`` to also accept
``cryptography``'s ``x509.CertificateRevocationList`` arguments in addition
to the now deprecated ``OpenSSL.crypto.CRL`` arguments.
- Fixed ``test_set_default_verify_paths`` test so that it is skipped if no
network connection is available.
23.2.0 (2023-05-30)

@@ -89,0 +127,0 @@ -------------------

[tool.black]
line-length = 79
target-version = ["py36"]
target-version = ["py37"]
[tool.ruff]
select = ['E', 'F', 'I', 'W', 'UP', 'RUF']
line-length = 79
[tool.ruff.isort]
known-first-party = ["OpenSSL", "tests"]
+10
-13
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#

@@ -16,3 +15,2 @@ # Copyright (C) Jean-Paul Calderone 2008-2015, All rights reserved

HERE = os.path.abspath(os.path.dirname(__file__))

@@ -27,5 +25,3 @@ META_PATH = os.path.join("src", "OpenSSL", "version.py")

"""
with open(
os.path.join(HERE, *parts), "r", encoding="utf-8", newline=None
) as f:
with open(os.path.join(HERE, *parts), encoding="utf-8", newline=None) as f:
return f.read()

@@ -42,7 +38,7 @@

meta_match = re.search(
r"^__{meta}__ = ['\"]([^'\"]*)['\"]".format(meta=meta), META_FILE, re.M
rf"^__{meta}__ = ['\"]([^'\"]*)['\"]", META_FILE, re.M
)
if meta_match:
return meta_match.group(1)
raise RuntimeError("Unable to find __{meta}__ string.".format(meta=meta))
raise RuntimeError(f"Unable to find __{meta}__ string.")

@@ -87,3 +83,2 @@

"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",

@@ -94,2 +89,3 @@ "Programming Language :: Python :: 3.8",

"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",

@@ -101,14 +97,15 @@ "Programming Language :: Python :: Implementation :: PyPy",

],
python_requires=">=3.6",
python_requires=">=3.7",
packages=find_packages(where="src"),
package_dir={"": "src"},
install_requires=[
# Fix cryptographyMinimum in tox.ini when changing this!
# 40.0.0 and .1 are missing X509_V_* constants that we re-export.
"cryptography>=38.0.0,<42,!=40.0.0,!=40.0.1",
"cryptography>=41.0.5,<42",
],
extras_require={
"test": ["flaky", "pretend", "pytest>=3.0.1"],
"docs": ["sphinx!=5.2.0,!=5.2.0.post0", "sphinx_rtd_theme"],
"docs": [
"sphinx!=5.2.0,!=5.2.0.post0,!=7.2.5",
"sphinx_rtd_theme",
],
},
)

@@ -20,3 +20,2 @@ # Copyright (C) AB Strakt

__all__ = [

@@ -23,0 +22,0 @@ "SSL",

@@ -1,3 +0,1 @@

from __future__ import print_function
import ssl

@@ -7,3 +5,2 @@ import sys

import cffi
import cryptography

@@ -15,3 +12,2 @@

_env_info = """\

@@ -18,0 +14,0 @@ pyOpenSSL: {pyopenssl}

@@ -20,3 +20,3 @@ # Copyright (C) AB Strakt

__version__ = "23.2.0"
__version__ = "23.3.0"

@@ -29,2 +29,2 @@ __title__ = "pyOpenSSL"

__license__ = "Apache License, Version 2.0"
__copyright__ = "Copyright 2001-2023 {0}".format(__author__)
__copyright__ = f"Copyright 2001-2023 {__author__}"
Metadata-Version: 2.1
Name: pyOpenSSL
Version: 23.2.0
Version: 23.3.0
Summary: Python wrapper module around the OpenSSL library

@@ -17,3 +17,2 @@ Home-page: https://pyopenssl.org/

Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7

@@ -24,2 +23,3 @@ Classifier: Programming Language :: Python :: 3.8

Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython

@@ -30,6 +30,12 @@ Classifier: Programming Language :: Python :: Implementation :: PyPy

Classifier: Topic :: System :: Networking
Requires-Python: >=3.6
Requires-Python: >=3.7
License-File: LICENSE
Requires-Dist: cryptography<42,>=41.0.5
Provides-Extra: test
Requires-Dist: flaky; extra == "test"
Requires-Dist: pretend; extra == "test"
Requires-Dist: pytest>=3.0.1; extra == "test"
Provides-Extra: docs
License-File: LICENSE
Requires-Dist: sphinx!=5.2.0,!=5.2.0.post0,!=7.2.5; extra == "docs"
Requires-Dist: sphinx_rtd_theme; extra == "docs"

@@ -87,2 +93,34 @@ ========================================================

23.3.0 (2023-10-25)
-------------------
Backward-incompatible changes:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Dropped support for Python 3.6.
- The minimum ``cryptography`` version is now 41.0.5.
- Removed ``OpenSSL.crypto.loads_pkcs7`` and ``OpenSSL.crypto.loads_pkcs12`` which had been deprecated for 3 years.
- Added ``OpenSSL.SSL.OP_LEGACY_SERVER_CONNECT`` to allow legacy insecure renegotiation between OpenSSL and unpatched servers.
`#1234 <https://github.com/pyca/pyopenssl/pull/1234>`_.
Deprecations:
^^^^^^^^^^^^^
- Deprecated ``OpenSSL.crypto.PKCS12`` (which was intended to have been deprecated at the same time as ``OpenSSL.crypto.load_pkcs12``).
- Deprecated ``OpenSSL.crypto.NetscapeSPKI``.
- Deprecated ``OpenSSL.crypto.CRL``
- Deprecated ``OpenSSL.crypto.Revoked``
- Deprecated ``OpenSSL.crypto.load_crl`` and ``OpenSSL.crypto.dump_crl``
- Deprecated ``OpenSSL.crypto.sign`` and ``OpenSSL.crypto.verify``
- Deprecated ``OpenSSL.crypto.X509Extension``
Changes:
^^^^^^^^
- Changed ``OpenSSL.crypto.X509Store.add_crl`` to also accept
``cryptography``'s ``x509.CertificateRevocationList`` arguments in addition
to the now deprecated ``OpenSSL.crypto.CRL`` arguments.
- Fixed ``test_set_default_verify_paths`` test so that it is skipped if no
network connection is available.
23.2.0 (2023-05-30)

@@ -89,0 +127,0 @@ -------------------

@@ -1,5 +0,5 @@

cryptography!=40.0.0,!=40.0.1,<42,>=38.0.0
cryptography<42,>=41.0.5
[docs]
sphinx!=5.2.0,!=5.2.0.post0
sphinx!=5.2.0,!=5.2.0.post0,!=7.2.5
sphinx_rtd_theme

@@ -6,0 +6,0 @@

@@ -10,5 +10,6 @@ # Copyright (c) The pyOpenSSL developers

def pytest_report_header(config):
import OpenSSL.SSL
import cryptography
import OpenSSL.SSL
return "OpenSSL: {openssl}\ncryptography: {cryptography}".format(

@@ -15,0 +16,0 @@ openssl=OpenSSL.SSL.SSLeay_version(OpenSSL.SSL.SSLEAY_VERSION),

@@ -6,3 +6,2 @@ import sys

sys.modules["ssl"] = None

@@ -26,3 +25,3 @@ sys.modules["_hashlib"] = None

"""
) # noqa
)
_api = _ffi.verify(

@@ -84,3 +83,3 @@ """

del heap[p]
log("free(0x%x)" % (int(_ffi.cast("int", p)),))
log("free(0x{:x})".format(int(_ffi.cast("int", p))))

@@ -87,0 +86,0 @@

+5
-10
[tox]
envlist = py{py,py3,36,37,38,39,310,311}{,-cryptographyMinimum}{,-useWheel}{,-randomorder},py311-twistedTrunk,check-manifest,flake8,py311-mypy,docs,coverage-report
envlist = py{py3,37,38,39,310,311,312}{,-cryptographyMinimum}{,-useWheel}{,-randomorder},py311-twistedTrunk,check-manifest,lint,py311-mypy,docs,coverage-report

@@ -21,3 +21,3 @@ [testenv]

coverage>=4.2
cryptographyMinimum: cryptography==38.0.0
cryptographyMinimum: cryptography==41.0.5
randomorder: pytest-randomly

@@ -45,12 +45,11 @@ setenv =

[testenv:flake8]
[testenv:lint]
basepython = python3
deps =
black
flake8
flake8-import-order
ruff==0.0.284
skip_install = true
commands =
black --check .
flake8 .
ruff .

@@ -83,5 +82,1 @@ [testenv:py311-mypy]

coverage report
[flake8]
application-import-names = OpenSSL
ignore = E203,W503,W504

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display