Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

GH-113214: Fix SSLProto exception handling in SSL-over-SSL scenarios#113334

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
gvanrossum merged 2 commits intopython:mainfrommjpieters:asyncio_fix_ssl_abort
Dec 20, 2023

Conversation

@mjpieters
Copy link
Contributor

@mjpietersmjpieters commentedDec 20, 2023
edited by bedevere-appbot
Loading

When wrapped,_SSLProtocolTransport._force_close(exc) is called just like in the unwrapped scenario_SelectorTransport._force_close(exc) or_ProactorBasePipeTransport._force_close(exc) would be called, except here the exception needs to be passed through theSSLProtocol._abort() method, which didn't accept an exception object.

This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).

Copy link
Member

@gvanrossumgvanrossum left a comment

Choose a reason for hiding this comment

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

This looks great except a comment nit. Once you fix that I'll merge, and full speed ahead on the 3.12 and 3.11 backports.

mjpieters reacted with thumbs up emoji
@gvanrossumgvanrossum added needs backport to 3.11only security fixes needs backport to 3.12only security fixes labelsDec 20, 2023
mjpietersand others added2 commitsDecember 20, 2023 22:12
When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).
Copy link
Member

@gvanrossumgvanrossum left a comment

Choose a reason for hiding this comment

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

Thanks! Merging now, hopefully the backports will be uneventful (but boy do they generate a lot of notification email :-).

PS. Next time please do not force-push -- it makes the review harder. We squash-merge into main anyway.

@gvanrossumgvanrossum merged commit1ff0238 intopython:mainDec 20, 2023
@miss-islington-app
Copy link

Thanks@mjpieters for the PR, and@gvanrossum 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 requestDec 20, 2023
…arios (pythonGH-113334)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).(cherry picked from commit1ff0238)Co-authored-by: Martijn Pieters <mj@zopatista.com>
@bedevere-app
Copy link

GH-113339 is a backport of this pull request to the3.12 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.12only security fixes labelDec 20, 2023
@bedevere-app
Copy link

GH-113340 is a backport of this pull request to the3.11 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestDec 20, 2023
…arios (pythonGH-113334)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).(cherry picked from commit1ff0238)Co-authored-by: Martijn Pieters <mj@zopatista.com>
@bedevere-appbedevere-appbot removed the needs backport to 3.11only security fixes labelDec 20, 2023
@mjpietersmjpieters deleted the asyncio_fix_ssl_abort branchDecember 20, 2023 23:11
gvanrossum pushed a commit that referenced this pull requestDec 21, 2023
…narios (GH-113334) (#113339)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).(cherry picked from commit1ff0238)Co-authored-by: Martijn Pieters <mj@zopatista.com>
gvanrossum pushed a commit that referenced this pull requestDec 21, 2023
…narios (GH-113334) (#113340)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).(cherry picked from commit1ff0238)Co-authored-by: Martijn Pieters <mj@zopatista.com>
ryan-duve pushed a commit to ryan-duve/cpython that referenced this pull requestDec 26, 2023
…arios (python#113334)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).
kulikjak pushed a commit to kulikjak/cpython that referenced this pull requestJan 22, 2024
…arios (python#113334)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).
aisk pushed a commit to aisk/cpython that referenced this pull requestFeb 11, 2024
…arios (python#113334)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).
Glyphack pushed a commit to Glyphack/cpython that referenced this pull requestSep 2, 2024
…arios (python#113334)When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@gvanrossumgvanrossumgvanrossum approved these changes

@1st11st1Awaiting requested review from 1st1

@asvetlovasvetlovAwaiting requested review from asvetlov

@kumaraditya303kumaraditya303Awaiting requested review from kumaraditya303

@willingcwillingcAwaiting requested review from willingc

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@mjpieters@gvanrossum

[8]ページ先頭

©2009-2025 Movatter.jp