blob: ecf95e5d635ff4574073e6183b46c5d7826e5634 [file] [log] [blame]
Jean-Paul Calderone897bc252008-02-18 20:50:23 -05001I've finally gotten around to writing some examples :-)
2
3They aren't many, but at least it's something. If you write any, feel free to
4send them to me and I will add themn.
5
6
7certgen.py - Certificate generation module
8==========================================
9
10Example module with three functions:
11 createKeyPair - Create a public/private key pair
12 createCertRequest - Create a certificate request
13 createCertificate - Create a certificate given a cert request
14In fact, I created the certificates and keys in the 'simple' directory with
15the script mk_simple_certs.py
16
17
18simple - Simple client/server example
19=====================================
20
21Start the server with
22 python server.py PORT
23and start clients with
24 python client.py HOST PORT
25
26The server is a simple echo server, anything a client sends, it sends back.
27
28
29proxy.py - Example of an SSL-enabled proxy
30==========================================
31
32The proxy example demonstrate how to use set_connect_state to start
33talking SSL over an already connected socket.
34
35Usage: python proxy.py server[:port] proxy[:port]
36
37Contributed by Mihai Ibanescu
38
39
40SecureXMLRPCServer.py - SSL-enabled version of SimpleXMLRPCServer
41=================================================================
42
43This acts exactly like SimpleXMLRPCServer from the standard python library,
44but uses secure connections. The technique and classes should work for any
45SocketServer style server. However, the code has not been extensively tested.
46
47Contributed by Michal Wallace
48