classification
Title: ssl.SSLContext(True).load_verify_locations(None, True) segfault
Type: crash Stage: commit review
Components: Library (Lib) Versions: Python 3.2, Python 3.3
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: georg.brandl, pitrou, vstinner
Priority: release blocker Keywords: patch

Created on 2011-01-23 22:02 by vstinner, last changed 2011-01-29 11:32 by vstinner. This issue is now closed.

Files
File name Uploaded Description Edit
ssl.patch vstinner, 2011-01-27 23:10
Messages (8)
msg126901 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2011-01-23 22:02
ssl.SSLContext(True).load_verify_locations(None, True) does segfault. Py_DECREF(cafile_bytes) in Modules/_ssl.c:1686 should be replaced by Py_XDECREF(cafile_bytes).
msg126902 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2011-01-23 22:07
Needs a patch + tests :)
msg127237 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2011-01-27 23:10
Here is a patch including a test.

The test pass on regrtest with -R 3:3: (no reference leak).
msg127238 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2011-01-27 23:27
Looks good to me.
msg127365 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2011-01-29 01:36
Should it be fixed in Python 3.2 or not? (load_verify_locations was introduced with SSLContext in Python 3.2)
msg127367 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2011-01-29 01:37
Well, I think you can commit.
msg127386 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2011-01-29 09:21
It's reviewed by Antoine, so you can commit.
msg127405 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2011-01-29 11:32
Ok, fixed in r88228. Not backport needed, SSLContext was introduced in Python 3.2.
History
Date User Action Args
2011-01-29 11:32:55vstinnersetstatus: open -> closed

messages: + msg127405
resolution: accepted -> fixed
nosy: georg.brandl, pitrou, vstinner
2011-01-29 09:21:22georg.brandlsetnosy: georg.brandl, pitrou, vstinner
messages: + msg127386
2011-01-29 01:37:59pitrousetnosy: georg.brandl, pitrou, vstinner
messages: + msg127367
2011-01-29 01:36:59vstinnersetpriority: high -> release blocker
nosy: georg.brandl, pitrou, vstinner
messages: + msg127365
2011-01-27 23:27:51pitrousetnosy: georg.brandl, pitrou, vstinner
messages: + msg127238
resolution: accepted
stage: needs patch -> commit review
2011-01-27 23:10:56vstinnersetfiles: + ssl.patch

messages: + msg127237
keywords: + patch
nosy: georg.brandl, pitrou, vstinner
2011-01-23 22:07:18pitrousetpriority: normal -> high

nosy: + georg.brandl
messages: + msg126902

type: crash
stage: needs patch
2011-01-23 22:02:01vstinnercreate