[Python-bugs-list] [ python-Bugs-527521 ] httplib test causes SSL core dump

noreply@sourceforge.net noreply@sourceforge.net
Fri, 08 Mar 2002 11:57:03 -0800


Bugs item #527521, was opened at 2002-03-08 19:57
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=527521&group_id=5470

Category: Extension Modules
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Jeremy Hylton (jhylton)
Assigned to: Nobody/Anonymous (nobody)
Summary: httplib test causes SSL core dump

Initial Comment:
The test() function in the httplib module attempts to 
connect to SourceForge using SSL.  I've tried this 
with Python 2.1 and up, using OpenSSL 0.9.6.  The read 
call fails with an SSL error, then python dumps core 
instead OpenSSL.

I don't know if this is a Python bug or an SSL bug.  
At first blush, I'd guess that Python is probably 
using OpenSSL incorrectly.

Here's the Python traceback.

Traceback (most recent call last):
  File "../Lib/httplib.py", line 895, in ?
    test()
  File "../Lib/httplib.py", line 884, in test
    status, reason, headers = hs.getreply()
  File "../Lib/httplib.py", line 734, in getreply
    response = self._conn.getresponse()
  File "../Lib/httplib.py", line 579, in getresponse
    response = self.response_class(self.sock)
  File "../Lib/httplib.py", line 99, in __init__
    self.fp = sock.makefile('rb', 0)
  File "../Lib/httplib.py", line 614, in makefile
    buf = self.__ssl.read()
socket.sslerror: (1, 'error:1408F10B:SSL 
routines:SSL3_GET_RECORD:wrong version number')

And the gdb stack trace.

#0 0x401e96d1 in sk_pop_free () 
from /usr/local/ssl/lib/libcrypto.so.0.9.6
(gdb) bt
#0 0x401e96d1 in sk_pop_free () 
from /usr/local/ssl/lib/libcrypto.so.0.9.6
#1 0x40191068 in __DTOR_END__ () 
from /usr/local/ssl/lib/libssl.so.0.9.6
#2 0xe853 in ?? ()
Cannot access memory at address 0x5614ec83.


----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=527521&group_id=5470