TLS encryption channel - #12
Open
viacheslauK wants to merge 28 commits into
Open
Conversation
added 7 commits
July 22, 2026 15:46
…to avoid callbacks into dying objects
Wire the downstream CI to build the new TLS (`wss://`) support across the matrix by providing OpenSSL on every platform, and fix a clang build error. - Moved the downstream CI to the reusable workflow `@v2`, which added per-job CMake cache variables (not yet available in v1). - Added OpenSSL to the list of installed packages: `libssl-dev` on Linux x86_64, `libssl-dev:i386` on 32-bit Linux, and `vcpkg install openssl:x86-windows` on Windows x86. - Fixed an assignment inside an `if` condition that clang treated as an error (`-Werror,-Wparentheses`) in `websocket_streaming_client_module_impl.cpp`.
added 8 commits
August 3, 2026 18:38
…ility API; multi discovery config;
NikolaiShipilov
approved these changes
Aug 10, 2026
NikolaiShipilov
left a comment
Collaborator
There was a problem hiding this comment.
LGTM 👍 . The only minor comment is about recognizing the cause of connection failure.
viacheslauK
marked this pull request as ready for review
August 12, 2026 14:31
added 2 commits
August 12, 2026 18:53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TLS encryption channel
Summary
Adds an optional TLS-encrypted transport to the LT streaming client and server modules, with
server authentication, mutual TLS, and a mode that encrypts without authenticating the server.
daq.lt://anddaq.lts://are supported side by side: the server can open plain and TLS listenerssimultaneously, and the client picks its mode from the connection-string prefix. Both channels
are advertised over mDNS and published as openDAQ server capabilities.
Changes
Transport and configuration
WsStreamingServergains theEnableTlsStreamingPort,TlsWebsocketStreamingPort,EnableMutualTls,CertificateFilePath,KeyFilePathandCaCertificateFilePathproperties,and enables the plain and TLS listeners independently.
WsStreamingmapsdaq.lts://towss://and configures TLS from its own configurationobject.
WsStreamingDevice::createNewSecureType()andWsStreaming::createSecureType()register the
daq.ltsdevice and streaming types (OpenDAQLTStreamingSecure), with 7415 asthe default port.
VerifyServerCertificate(defaulttrue). Cleared, itrequires no CA, certificate or key, connects through
wss::client::enable_tls_without_verification(),and logs a warning: the connection is encrypted but the server is not authenticated. Mutual TLS
is hidden along with all three file paths.
Discovery and capabilities
_streaming-lts._tcp.local.alongside the existing services, andonCompleteServerCapability()accepts bothOpenDAQLTStreamingandOpenDAQLTStreamingSecure,defaulting the port per scheme and building
daq.lts://connection strings for the secure one.WsStreamingServer::getDiscoveryConfigs()(plural) emits one record per enabled channel, andaddCapability()publishes both with security levels 0 and 10.addCapability()now runs beforethe core-event subscription and the I/O thread start, with rollback on failure, and
removeCapability()is guarded so a restarted server does not strip its successor's capability.Error handling
InvalidParameterException;a rejected handshake surfaces as
AuthenticationFailedException(matched on the Asio SSL errorcategory) and an unreachable peer as
NotFoundException.WsStreamingtears the connection down on the I/O thread and disconnects its signal handlersthere, rather than stopping the I/O context, which corrupted the
ssl::streamduringdestruction.
Notes
and no protection against an active man-in-the-middle. It is off by default and warns at
connection time. Note that ws-streaming does not check the peer hostname against the certificate
even in the verified mode, so a certificate from a trusted CA is accepted whichever host it was
issued for.