I ran into this bug on another host, 62.44.69.195. The problem is not urllib2, its ssl.do_handshake() which fails. urllib2 just wraps the error.

Python 2.7.3 (default, Sep  9 2012, 17:41:34)
[GCC 4.7.1] on linux2
>>> import ssl, socket; ssl.wrap_socket(socket.create_connection(('secure.nicovideo.jp', 443)))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/ssl.py", line 381, in wrap_socket
    ciphers=ciphers)
  File "/usr/lib/python2.7/ssl.py", line 143, in __init__
    self.do_handshake()
  File "/usr/lib/python2.7/ssl.py", line 305, in do_handshake
    self._sslobj.do_handshake()
socket.error: [Errno 104] Connection reset by peer

Compared with:
Python 2.6.6 (r266:84292, Dec 26 2010, 22:31:48)
[GCC 4.4.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import ssl, socket; ssl.wrap_socket(socket.create_connection(('secure.nicovideo.jp', 443)))
<ssl.SSLSocket object at 0x7f3e215b3f50>


Ubuntus python2.7 package is not affected by this bug. Also python2.6 from squeeze connects fine. But using python2.7 from testing or unstable both fails. The non-working hosts seem to be only apaches so far, but also lots of other apache ssl pages work fine. The bug is 100% reproducible for me on two of my debian machines, no networking errors besides this bug. I'm happy to provide any further details, if told, how to get them.

Michael


--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to