8000 gh-106831: Fix `NULL` check of `d2i_SSL_SESSION` result in `_ssl.c` by sobolevn · Pull Request #106832 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-106831: Fix NULL check of d2i_SSL_SESSION result in _ssl.c #106832

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 yo 8000 ur account

Merged
merged 2 commits into from
Jul 17, 2023

Conversation

sobolevn
Copy link
Member
@sobolevn sobolevn commented Jul 17, 2023

@vstinner you've recently commited to this module, would you have time to take a look at the fix I am proposing? :)

Copy link
Member
@vstinner vstinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vstinner you've recently commited to this module, would you have time to take a look at the fix I am proposing? :)

Oh no. What did I do?

@sobolevn
Copy link
Member Author

Oh no. What did I do?

😆 ad95c72

Done, I've addressed your review. Thanks for the quick feedback 👍

Copy link
Member
@vstinner vstinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

goto error;
}
const_p = senc;
newsession = d2i_SSL_SESSION(NULL, &const_p, slen);
if (session == NULL) {
if (newsession == NULL) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, now I see the typo! Previous, session was checked, but newsession must checked! Nicely spotted.

@vstinner vstinner enabled auto-merge (squash) July 17, 2023 19:28
@vstinner vstinner added needs backpor 8000 t to 3.11 only security fixes needs backport to 3.12 only security fixes labels Jul 17, 2023
@vstinner vstinner merged commit ebf2c56 into python:main Jul 17, 2023
@miss-islington
Copy link
Contributor

Thanks @sobolevn for the PR, and @vstinner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 17, 2023
…pythonGH-106832)

(cherry picked from commit ebf2c56)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
@bedevere-bot
Copy link

GH-106835 is a backport of this pull request to the 3.12 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.12 only security fixes label Jul 17, 2023
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 17, 2023
…pythonGH-106832)

(cherry picked from commit ebf2c56)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
@bedevere-bot
Copy link

GH-106836 is a backport of this pull request to the 3.11 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.11 only security fixes label Jul 17, 2023
vstinner pushed a commit that referenced this pull request Jul 17, 2023
GH-106832) (#106836)

gh-106831: Fix NULL check of d2i_SSL_SESSION() result in _ssl.c (GH-106832)
(cherry picked from commit ebf2c56)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
vstinner pushed a commit that referenced this pull request Jul 17, 2023
GH-106832) (#106835)

gh-106831: Fix NULL check of d2i_SSL_SESSION() result in _ssl.c (GH-106832)
(cherry picked from commit ebf2c56)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0