New submission from A.M. Kuchling <[EMAIL PROTECTED]>:

On my MacOS 10.4.11 machine, the example SSL server and client in the
documentation don't work, and they fail with a mysterious error 0.  The
attached tarball contains my slightly-modified version of the scripts
and the test key/cert I'm using.  

When I run the server, and then the client, the output of the server is:

[EMAIL PROTECTED]:~/source/p/python$ ./python.exe server.py
Waiting for connection...
Connection received from ('127.0.0.1', 61915)
Traceback (most recent call last):
  File "server.py", line 16, in <module>
    certfile='cert.pem')
  File "/Users/amk/source/p/python/Lib/ssl.py", line 466, in wrap_socket
    ssl_version=ssl_version, ca_certs=ca_certs)
  File "/Users/amk/source/p/python/Lib/ssl.py", line 103, in __init__
    cert_reqs, ssl_version, ca_certs)
ssl.SSLError: [Errno 8] _ssl.c:429: EOF occurred in violation of protocol

And the client is:
[EMAIL PROTECTED]:~/source/p/python$ ./python.exe client.py
Traceback (most recent call last):
  File "client.py", line 10, in <module>
    ssl_sock.connect(('', 9000))
  File "/Users/amk/source/p/python/Lib/ssl.py", line 204, in connect
    self.ca_certs)
ssl.SSLError: [Errno 0] _ssl.c:327: error:00000000:lib(0):func(0):reason(0)
[EMAIL PROTECTED]:~/source/p/python$ 

The error 0 is very puzzling.

Perhaps I generated the key and cert incorrectly, and parsing them is
failing in this strange way?

----------
assignee: janssen
components: Extension Modules
files: ssl-example.tgz
messages: 65770
nosy: akuchling, janssen
priority: high
severity: normal
status: open
title: SSL example script fails mysteriously on MacOS
type: behavior
versions: Python 2.6
Added file: http://bugs.python.org/file10102/ssl-example.tgz

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2687>
__________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to