SSL Issue

Jonathan Gardner jgardner.jonathangardner.net at gmail.com
Thu Sep 6 19:08:35 EDT 2007


On Sep 5, 10:47 pm, Harry George <harry.g.geo... at boeing.com> wrote:
> Jurian Botha <jur... at oco.co.za> writes:
> > Sorry if this is a real dumb question, but I'm totally stumped.
>
> > I'm trying to connect to a https url in order to do some xml-rpc method
> > calls, but I'm getting the following error:
>
> > Error Type: sslerror
> > Error Value: (6, 'TLS/SSL connection has been closed')
>
> > What could be causing this error, any clues would be greatly appreciated.
>
> > Thanks
> > --
> > View this message in context:http://www.nabble.com/SSL-Issue-tf4388062.html#a12510772
> > Sent from the Python - python-list mailing list archive at Nabble.com.
>
> I don't have a complete story, but here are some hints:
>
> 1. The message is from:http://www.openssl.org/docs/ssl/SSL_get_error.html
> (see "ZERO RETURN")
> probably as filtered by
> PyOpenSSL, which has its own issues:http://mail.python.org/pipermail/python-dev/2007-August/074322.html
>
> 2. Chances are that your certificates are out of whack, or you are
> misusing the SSL context parameters, or are not telling the HTTP
> Connection object about the SSL Connection properly.
>
> 3. Debugging at the python layer is easier (put print statements in
> M2Crypto's SSL/Context and SSL/Connection) but if necessary, dive into
> openssl:
> http://www.mail-archive.com/openssl-us...@openssl.org/msg49287.html
>
> 4. You can check for the "hello" handshake using WireShark.
>
> 5. I haven't found a tutorial for full Python client/server over HTTPS
> with verification of both client and server certificates.  If that is
> where you are going, let me know what works.
>


Try the "openssl s_client <host>:<port>" command to get some handy
info on what is happening. It's kind of like telnet but for SSL. This
will help isolate SSL issues from the Python layer.




More information about the Python-list mailing list