Skip to content

Commit

Permalink
Clarify that the TLS example is simplistic.
Browse files Browse the repository at this point in the history
Fix #1381.
  • Loading branch information
aaugustin committed Jul 15, 2023
1 parent b870c46 commit 8ed5424
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions docs/howto/quickstart.rst
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,6 @@ Here's how to adapt the server to encrypt connections. You must download
:download:`localhost.pem <../../example/quickstart/localhost.pem>` and save it
in the same directory as ``server_secure.py``.

See the documentation of the :mod:`ssl` module for details on configuring the
TLS context securely.

.. literalinclude:: ../../example/quickstart/server_secure.py
:caption: server_secure.py
:language: python
Expand All @@ -79,6 +76,15 @@ When connecting to a secure WebSocket server with a valid certificate — any
certificate signed by a CA that your Python installation trusts — you can
simply pass ``ssl=True`` to :func:`~client.connect`.

.. admonition:: Configure the TLS context securely
:class: attention

This example demonstrates the ``ssl`` argument with a TLS certificate shared
between the client and the server. This is a simplistic setup.

Please review the advice and security considerations in the documentation of
the :mod:`ssl` module to configure the TLS context securely.

Connect from a browser
----------------------

Expand Down

0 comments on commit 8ed5424

Please sign in to comment.