The provided below cp_tls_builtin.py
and cp_tls_pyopenssl.py
modules are
almost bare minimum CherryPy apps set up to serve a static string over HTTPS.
I say "almost" because having an HTTP handler mounted isn't really necesary to
verify that TLS works but having it provides a nice visual cue when using
curl
, for example.
This instruction assumes that you have a freshly made virtualenv where you
executed something like pip install 'CherryPy[ssl]' trustme
. The ssl
extra
is only needed to pull in pyOpenSSL and isn't needed for the built-in stdlib
TLS adapter. The trustme project is needed for demonstration purposes — it'll