summaryrefslogtreecommitdiff
path: root/examples/websockets/doc/sslechoclient.qdoc
diff options
context:
space:
mode:
authorØystein Heskestad <oystein.heskestad@qt.io>2023-02-14 12:50:38 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2023-03-15 17:15:30 +0000
commit47ae447bbec02fae88f42801f0f1fa368fc3e9a8 (patch)
tree64bda93e9c314607131ea2932f9b372afb06c3f5 /examples/websockets/doc/sslechoclient.qdoc
parent2288aa3ca314dba86e31ac7df52de8760624f499 (diff)
downloadqtwebsockets-47ae447bbec02fae88f42801f0f1fa368fc3e9a8.tar.gz
Expand documentation of examples
Add to the documentation to include what the examples do and how they do it, to make it easier for users to decide if an example is worth looking into, instead of how it was where they had to look at the code in the examples to decide if they are relevant for their purposes. Also added pictures to the examples. Task-number: QTBUG-110894 Change-Id: I2751939e9f9716cd970e5fa938dabf042f369329 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> (cherry picked from commit 0b665063815a429d7862e261dfa469ca50c55fa4) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'examples/websockets/doc/sslechoclient.qdoc')
-rw-r--r--examples/websockets/doc/sslechoclient.qdoc24
1 files changed, 18 insertions, 6 deletions
diff --git a/examples/websockets/doc/sslechoclient.qdoc b/examples/websockets/doc/sslechoclient.qdoc
index 16be47e..2136d5f 100644
--- a/examples/websockets/doc/sslechoclient.qdoc
+++ b/examples/websockets/doc/sslechoclient.qdoc
@@ -3,13 +3,25 @@
/*!
\example sslechoclient
- \title SSL Echo Client Example
+ \title Secure WebSocket Echo Client
+ \meta category {Networking}
\ingroup qtwebsockets-examples
- \brief Shows how to use the QWebSocket class to implement an echo
- client over a secure connection (wss).
+ \brief A simple client application using secure WebSockets (wss).
- The SSL Echo Client example shows how to use the QWebSocket class to implement
- an echo client over a secure connection (wss).
+ The Secure WebSocket Echo Client example shows how to use the
+ \l {Qt WebSockets}{WebSocket} class to implement an echo client over
+ a secure connection (wss). It connects to a server and sends a message,
+ and when it receives a message back, it prints it out and exits. SSL
+ support is required for this example to work.
- \sa {Echo Client Example}, {SSL Echo Server Example}
+ This example connects to localhost at port 1234 using a secure connection.
+ Though SSL errors are ignored in this example, this should never be done
+ in production code, because that would leave the client vulnerable to
+ man-in-the-middle attacks. To use a certificates not signed by an existing
+ CA, add a custom self-signed root CA certificate, trust it in your
+ application or system, and sign the server certificate with that.
+
+ \image echoclient-console-example.webp Secure WebSocket Echo Console Client
+
+ \sa {WebSocket Echo Client}, {Secure WebSocket Echo Server}
*/