sslkeylog


Namesslkeylog JSON
Version 0.5.1 PyPI version JSON
download
home_pagehttps://github.com/segevfiner/sslkeylog
SummaryLog SSL/TLS keys for decrypting SSL/TLS connections
upload_time2024-06-15 11:30:01
maintainerNone
docs_urlNone
authorSegev Finer
requires_pythonNone
licenseMIT
keywords ssl tls sslkeylogfile
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            sslkeylog
=========

.. image:: https://img.shields.io/pypi/v/sslkeylog.svg
   :target: https://pypi.org/project/sslkeylog/
   :alt: PyPI

.. image:: https://readthedocs.org/projects/sslkeylog/badge/?version=latest
   :target: https://sslkeylog.readthedocs.io/en/latest/?badge=latest
   :alt: Documentation Status

.. image:: https://github.com/segevfiner/sslkeylog/actions/workflows/build-and-test.yml/badge.svg
   :target: https://github.com/segevfiner/sslkeylog/actions/workflows/build-and-test.yml
   :alt: Build & Test Status

This is an implementation of the ``SSLKEYLOGFILE`` facility, available in Firefox and
Chromium/Google Chrome, that is supported by Wireshark in order to decrypt SSL/TLS connections
even when you don't have the private key, or when using key exchange methods that will prevent
decryption even if you do (Such as Diffie-Hellman).

This is for the standard library ``ssl`` module, it won't work for other ssl modules.

**Note:**
   Python 3.8+ includes built-in support for generating an SSL key log file via
   ``ssl.SSLContext.keylog_filename``, and will also enable it when the ``SSLKEYLOGFILE``
   environment variable is set when creating a context via ``ssl.create_default_context``.

   This package uses the same callback the built-in implementation is using, which will likely cause
   both implementations to trample each other, causing the other not to work, or other unintended
   consequences. As such, you should probably not enable both at the same time.

Quick Start
-----------
.. code-block:: python

    import os
    import sslkeylog

    sslkeylog.set_keylog(os.environ.get('SSLKEYLOGFILE'))  # Or directly specify a path

    # Do anything involving SSL (Using the built-in ssl module)

Set the ``SSLKEYLOGFILE`` environment variable if you use it, and set "(Pre)-Master-Secret log
filename" in Wireshark's SSL protocol preferences to the resulting file.

Links
-----
* `NSS Key Log Format`_
* `Wireshark - SSL`_

.. _NSS Key Log Format: https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Key_Log_Format
.. _Wireshark - SSL: https://wiki.wireshark.org/SSL

License
-------
MIT License, except OpenSSL which is licensed under it's own license. See LICENSE.txt

This product includes software developed by the OpenSSL Project
for use in the OpenSSL Toolkit (http://www.openssl.org/)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/segevfiner/sslkeylog",
    "name": "sslkeylog",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "ssl tls sslkeylogfile",
    "author": "Segev Finer",
    "author_email": "segev208@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/9a/eb/ff9ab49fcc97b9316fbbd3a665e24d3573f4efe01f59145e82076d927f85/sslkeylog-0.5.1.tar.gz",
    "platform": null,
    "description": "sslkeylog\r\n=========\r\n\r\n.. image:: https://img.shields.io/pypi/v/sslkeylog.svg\r\n   :target: https://pypi.org/project/sslkeylog/\r\n   :alt: PyPI\r\n\r\n.. image:: https://readthedocs.org/projects/sslkeylog/badge/?version=latest\r\n   :target: https://sslkeylog.readthedocs.io/en/latest/?badge=latest\r\n   :alt: Documentation Status\r\n\r\n.. image:: https://github.com/segevfiner/sslkeylog/actions/workflows/build-and-test.yml/badge.svg\r\n   :target: https://github.com/segevfiner/sslkeylog/actions/workflows/build-and-test.yml\r\n   :alt: Build & Test Status\r\n\r\nThis is an implementation of the ``SSLKEYLOGFILE`` facility, available in Firefox and\r\nChromium/Google Chrome, that is supported by Wireshark in order to decrypt SSL/TLS connections\r\neven when you don't have the private key, or when using key exchange methods that will prevent\r\ndecryption even if you do (Such as Diffie-Hellman).\r\n\r\nThis is for the standard library ``ssl`` module, it won't work for other ssl modules.\r\n\r\n**Note:**\r\n   Python 3.8+ includes built-in support for generating an SSL key log file via\r\n   ``ssl.SSLContext.keylog_filename``, and will also enable it when the ``SSLKEYLOGFILE``\r\n   environment variable is set when creating a context via ``ssl.create_default_context``.\r\n\r\n   This package uses the same callback the built-in implementation is using, which will likely cause\r\n   both implementations to trample each other, causing the other not to work, or other unintended\r\n   consequences. As such, you should probably not enable both at the same time.\r\n\r\nQuick Start\r\n-----------\r\n.. code-block:: python\r\n\r\n    import os\r\n    import sslkeylog\r\n\r\n    sslkeylog.set_keylog(os.environ.get('SSLKEYLOGFILE'))  # Or directly specify a path\r\n\r\n    # Do anything involving SSL (Using the built-in ssl module)\r\n\r\nSet the ``SSLKEYLOGFILE`` environment variable if you use it, and set \"(Pre)-Master-Secret log\r\nfilename\" in Wireshark's SSL protocol preferences to the resulting file.\r\n\r\nLinks\r\n-----\r\n* `NSS Key Log Format`_\r\n* `Wireshark - SSL`_\r\n\r\n.. _NSS Key Log Format: https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Key_Log_Format\r\n.. _Wireshark - SSL: https://wiki.wireshark.org/SSL\r\n\r\nLicense\r\n-------\r\nMIT License, except OpenSSL which is licensed under it's own license. See LICENSE.txt\r\n\r\nThis product includes software developed by the OpenSSL Project\r\nfor use in the OpenSSL Toolkit (http://www.openssl.org/)\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Log SSL/TLS keys for decrypting SSL/TLS connections",
    "version": "0.5.1",
    "project_urls": {
        "Documentation": "https://sslkeylog.readthedocs.io/",
        "Homepage": "https://github.com/segevfiner/sslkeylog",
        "Issue Tracker": "https://github.com/segevfiner/sslkeylog/issues"
    },
    "split_keywords": [
        "ssl",
        "tls",
        "sslkeylogfile"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "9aebff9ab49fcc97b9316fbbd3a665e24d3573f4efe01f59145e82076d927f85",
                "md5": "04c9273fdd8693356668ff4cf4a07c7d",
                "sha256": "47b0eb3f0e0b38142f275e0b3d26a61d4f017d2d56d84811801ca6cdbeefc596"
            },
            "downloads": -1,
            "filename": "sslkeylog-0.5.1.tar.gz",
            "has_sig": false,
            "md5_digest": "04c9273fdd8693356668ff4cf4a07c7d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 5566785,
            "upload_time": "2024-06-15T11:30:01",
            "upload_time_iso_8601": "2024-06-15T11:30:01.483003Z",
            "url": "https://files.pythonhosted.org/packages/9a/eb/ff9ab49fcc97b9316fbbd3a665e24d3573f4efe01f59145e82076d927f85/sslkeylog-0.5.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-06-15 11:30:01",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "segevfiner",
    "github_project": "sslkeylog",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "sslkeylog"
}
        
Elapsed time: 0.27164s