[issue30594] Refcounting mistake in _ssl.c

2017-06-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, this is now resolved, thanks to Nathaniel. -- resolution: -> fixed stage: backport needed -> resolved status: open -> closed ___ Python tracker

[issue30594] Refcounting mistake in _ssl.c

2017-06-09 Thread Jim Jewett
Jim Jewett added the comment: Serhiy -- do your last two messages mean that this is now resolved? -- nosy: +Jim.Jewett ___ Python tracker ___

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 54ba41ecc5711f89841342c5f9dd555ee13404b5 by Serhiy Storchaka (Nathaniel J. Smith) in branch '3.5': [3.5] bpo-30594: Fixed refcounting in newPySSLSocket (GH-1992) (#1993)

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 854f7ba1d5cbb6a42511beae66c8dbe34f2cbcd3 by Serhiy Storchaka (Nathaniel J. Smith) in branch '3.6': [3.6] bpo-30594: Fixed refcounting in newPySSLSocket (GH-1992) (#1994)

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Nathaniel Smith
Changes by Nathaniel Smith : -- pull_requests: +2065 ___ Python tracker ___ ___

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Nathaniel Smith
Nathaniel Smith added the comment: posted backports for 3.5 and 3.6. It looks like 2.7 is actually unaffected, because it doesn't have IDNA support, so there's no failure path in between when the reference is stored and when its INCREFed. -- versions: -Python 2.7

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Nathaniel Smith
Changes by Nathaniel Smith : -- pull_requests: +2057 ___ Python tracker ___ ___

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Nathaniel Smith
Changes by Nathaniel Smith : -- pull_requests: +2058 ___ Python tracker ___ ___

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your report and patch Nathaniel. Do you mind to create backporting PRs? -- stage: -> backport needed ___ Python tracker

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 65ece7ca2366308fa91a39a8dfa255e6bdce3cca by Serhiy Storchaka (Nathaniel J. Smith) in branch 'master': bpo-30594: Fixed refcounting in newPySSLSocket (#1992) https://github.com/python/cpython/commit/65ece7ca2366308fa91a39a8dfa255e6bdce3cca

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Nathaniel Smith
New submission from Nathaniel Smith: If you pass a server_hostname= that fails IDNA decoding to SSLContext.wrap_socket or SSLContext.wrap_bio, then the SSLContext object has a spurious Py_DECREF called on it, eventually leading to segfaults. Demo attached. -- assignee:

[issue30594] Refcounting mistake in _ssl.c

2017-06-08 Thread Nathaniel Smith
Changes by Nathaniel Smith : -- pull_requests: +2056 ___ Python tracker ___ ___