pyopenssl
pyopenssl copied to clipboard
set_session_id method is missing a word in its name
The correct method name should be set_session_id_context, since it is a wrapper around https://www.openssl.org/docs/man1.1.0/man3/SSL_CTX_set_session_id_context.html. Somewhat understandably the original implementation probably thought "context" was just a redundant-for-no-reason copy of "CTX", but the "session ID context" is legitimately a completely different thing from the "session ID" (which you set on the session object, with https://www.openssl.org/docs/man1.1.0/man3/SSL_SESSION_get_id.html, something that pyOpenSSL doesn't currently expose any methods on).
Note also that the documentation is completely incorrect as well, and states that this method sets the session ID.
(For context: Twisted has made a real mess of this... https://twistedmatrix.com/trac/ticket/9583)