Struct SolidSyslogMbedTlsStreamConfig¶
ClassList > SolidSyslogMbedTlsStreamConfig
#include <SolidSyslogMbedTlsStream.h>
struct SolidSyslogMbedTlsStreamConfig
{
struct SolidSyslogStream* Transport;
struct SolidSyslogMbedTlsCredentials* Credentials;
SolidSyslogSleepFunction Sleep;
SolidSyslogTlsHandshakeTimeoutFunction GetHandshakeTimeoutMs;
void* HandshakeTimeoutContext;
struct mbedtls_ctr_drbg_context* Rng;
SolidSyslogMbedTlsProfileFunction Profile;
void* ProfileContext;
SolidSyslogStreamVersionFunction Version;
void* VersionContext;
};
Detailed Description¶
Wires SolidSyslogMbedTlsStream to its transport, trust anchors, and identity.
Wiring only: every value a connection is made with arrives through the Credentials or the Profile, so nothing here goes stale when a deployment changes.
Public Attributes Documentation¶
Credentials¶
Where the trust anchors, any pinned peer fingerprints and the mutual-TLS client credential come from; required - a NULL is reported at SolidSyslogMbedTlsStream_Create.
Asked once per connection, so material is fetched only for a connection actually being made, and told when the connection ends. Borrowed - the caller owns it and must keep it valid until SolidSyslogMbedTlsStream_Destroy.
GetHandshakeTimeoutMs¶
Per-attempt handshake deadline in ms; NULL uses the SOLIDSYSLOG_TLS_HANDSHAKE_TIMEOUT_MS tunable.
HandshakeTimeoutContext¶
Passed back to GetHandshakeTimeoutMs unchanged; NULL is fine.
Profile¶
Supplies the per-connection profile.
NULL leaves every profile field at the library default, which for ServerName means an unverified peer.
ProfileContext¶
Passed to Profile unchanged; NULL is fine.
Rng¶
Seeded CTR-DRBG for the handshake; caller-built and caller-owned.
Required - a NULL is reported at SolidSyslogMbedTlsStream_Create. Seeded is the caller's to guarantee: a context that was initialised and never seeded returns bytes without error, makes every session's keys predictable, and cannot be told apart from a seeded one here.
Sleep¶
Bridges the WANT_READ/WANT_WRITE polls of the bounded handshake retry; required - a NULL is reported at SolidSyslogMbedTlsStream_Create.
Transport¶
Underlying byte stream the TLS records ride on; required - a NULL is reported at SolidSyslogMbedTlsStream_Create.
Borrowed - this stream may Close it but never destroys it; the caller owns it and must keep it valid until SolidSyslogMbedTlsStream_Destroy.
Version¶
Bumped by the integrator when anything above changes at runtime - the Credentials, or anything the Profile supplies.
The sender polls it every Send and reconnects on the next pass when it moves, so a rotation applies without calling SolidSyslogSender_Disconnect. Polled from the servicing thread, so it must be cheap and pure. NULL means this configuration never changes.
VersionContext¶
Passed to Version unchanged; NULL is fine.
The documentation for this class was generated from the following file Platform/MbedTls/Interface/SolidSyslogMbedTlsStream.h