README
1This directory contains client and server examples for the "Server Name
2Indication" (SNI) feature.
3
4Run server.py with no arguments. It will accept one client connection and
5then exit. It has two certificates it can use, one for "example.invalid"
6and another for "another.invalid". If a client indicates one of these names
7to it, it will use the corresponding certificate for that connection (if a
8client doesn't indicate a name or indicates another name, it won't try to
9use any certificate).
10
11Run client.py with one argument, the server name to indicate. For example:
12
13 $ python client.py example.invalid
14 Connecting... connected ('127.0.0.1', 8443)
15 Server subject is <X509Name object '/OU=Security/O=pyOpenSSL/CN=example.invalid/ST=New York/C=US/emailAddress=invalid@example.invalid/L=New York'>
16 $
17
18Depending on what hostname is supplied, the server will select a different
19certificate to use and the client output will be different.
20