Overview of the minimal secure streams server
mainThis application demonstrates a TLS + WebSocket (WS) server running on https://localhost:7681 using Libwebsockets' Secure Streams feature.
Key characteristics:
- Policy Configuration: Server operation logic is defined via a JSON policy located in
main.c. - Client Interaction: When visited in a modern browser, the server serves HTML and JavaScript. The JavaScript establishes a WebSocket connection back to the server, which then transmits an incrementing number every 100ms.
- Secure Streams: The server utilizes Secure Streams to manage the TLS and protocol transitions.