Add structured version info for ssl · Issue #157513 · python/cpython · GitHub
Skip to content

Add structured version info for ssl #157513

Description

@serhiy-storchaka

Feature or enhancement

ssl.OPENSSL_VERSION_INFO is a plain tuple of five integers. The version of the OpenSSL library that the module was built against is available only as the private ssl._OPENSSL_API_VERSION.

Make ssl.OPENSSL_VERSION_INFO a named tuple with fields major, minor, fix, patch and status, and add ssl.OPENSSL_API_VERSION_INFO for the build-time version, a named tuple of the same type. The existing names describe the runtime library, so the naming scheme of gh-117404 cannot be applied to ssl without renaming; "API version" is OpenSSL's own term for the headers the module was compiled with. _OPENSSL_API_VERSION is kept as an alias.

Linked PRs

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.16new features, bugs and security fixesextension-modulesC modules in the Modules dirtopic-SSLtype-featureA feature request or enhancement

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions