-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
bpo-37120: Add SSLContext.num_tickets (GH-13719) #13719
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 and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two small comments.
This attribute is not available unless the ssl module is compiled | ||
with OpenSSL 1.1.1 or newer. | ||
|
||
.. versionadded:: 3.8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably worth noting explicitly that it only affects TLS 1.3 connections, and possibly that it doesn't affect connections that are resumed using a ticket.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SGTM, the first sentence mentions that it's about TLS 1.3. I added another sentence to explicitly state that the setting does not affect TLS 1.0 to 1.2.
ctx.num_tickets = None | ||
|
||
ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT) | ||
self.assertEqual(ctx.num_tickets, 2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's maybe slightly nicer to make this error out too, I guess?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You mean getattr access? I'm not sure how much trouble it's going to create.
Signed-off-by: Christian Heimes <[email protected]>
57ba3de
to
0d12770
Compare
Signed-off-by: Christian Heimes <[email protected]>
Signed-off-by: Christian Heimes [email protected]
https://bugs.python.org/issue37120