Senthil Kumaran <sent...@uthcode.com> added the comment:

This is resolved by Issue 31122 and code now raises SSLEOFError instead of 
OSError.

The reason for OSError in the first place was PySSL_SetError function had the 
following call s->errorhandler();

https://github.com/python/cpython/blob/3.7/Modules/_ssl.c#L782

Where the errorhandler of socketmodule.c was called, and error message that 
raised was OSError 
(https://github.com/python/cpython/blob/master/Modules/socketmodule.c#L607)

---

In issue31122, Dima.Tisnek contributed a patch to remove the s-errorhandler() 
and replace it with  SSLEOFError 
https://github.com/python/cpython/commit/495bd035662fda29639f9d52bb6baebea31d72fa
 

Since the patch was ported to 3.8 and 3.9, OSError is no longer raised by the 
ssl module for the do_handshake call or wherever PySSL_SetError is utilized.

Closing this bug report as resolved.

----------
assignee: docs@python -> orsenthil
nosy: +Dima.Tisnek, orsenthil
resolution:  -> fixed
stage:  -> resolved
status: open -> closed

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue41450>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to