gh-94199: Remove ssl.wrap_socket() documentation by vstinner · Pull Request #99023 · python/cpython (original) (raw)
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation11 Commits5 Checks0 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
The function has been removed. In the ssl documentation, replace references to the ssl.wrap_socket() function with references to the ssl.SSLContext.wrap_socket() method.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating the doc!
Some arguments of ssl.wrap_socket
are no longer present in SSLContext.wrap_socket
.
@illia-v: I updated my PR, would you mind to review it? I removed references to non-existing parameters.
I made it clear the wrap_socket() is now the only way to create SSL socket objects, as already stated in the SSLSocket documentation: https://docs.python.org/dev/library/ssl.html#ssl.SSLSocket
Instances of SSLSocket must be created using the SSLContext.wrap_socket() method.
Comment on lines 2053 to 2054
case, only the ``certfile`` parameter to :meth:`SSLContext.load_cert_chain` |
---|
and :func:`wrap_socket` needs to be passed. If the private key is stored |
and :meth:`SSLContext.wrap_socket` needs to be passed. If the private key is stored |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Co-authored-by: Illia Volochii illia.volochii@gmail.com
Co-authored-by: Illia Volochii illia.volochii@gmail.com
Thanks @illia-v, it was more complicated than expected. Not just a simple text replace before/after ;-)