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

Commitdc8e1d0

Browse files
authored
gh-94101 Disallow instantiation of SSLSession objects (GH-94102)
Fixes#94101Automerge-Triggered-By: GH:tiran
1 parentfda4b2f commitdc8e1d0

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Manual instantiation of:class:`ssl.SSLSession` objects is no longer allowed
2+
as it lead to misconfigured instances that crashed the interpreter when
3+
attributes where accessed on them.

‎Modules/_ssl.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5067,7 +5067,8 @@ static PyType_Spec PySSLSession_spec = {
50675067
.name="_ssl.SSLSession",
50685068
.basicsize=sizeof(PySSLSession),
50695069
.flags= (Py_TPFLAGS_DEFAULT |Py_TPFLAGS_HAVE_GC |
5070-
Py_TPFLAGS_IMMUTABLETYPE),
5070+
Py_TPFLAGS_IMMUTABLETYPE |
5071+
Py_TPFLAGS_DISALLOW_INSTANTIATION),
50715072
.slots=PySSLSession_slots,
50725073
};
50735074

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp