Per-session configuration handed to ra8_tls_session_open.
The struct carries the BIO function pointers plus an opaque user context that the facade passes back unchanged on every BIO call. Optional server_name enables SNI when non-NULL.
- Invariant
- bio_send and bio_recv are non-NULL.
-
bio_ctx is owned by the caller for the full session lifetime (open -> close).
static int loop_send(void* ctx, const uint8_t* buf, size_t len) { ... }
static int loop_recv(void* ctx, uint8_t* buf, size_t len) { ... }
cfg.bio_send = loop_send;
cfg.bio_recv = loop_recv;
cfg.bio_ctx = &my_socket;
cfg.server_name = "api.example.com";
ra8_err_codes_t ra8_err_t
Canonical error-return type used by every ra8-firmware API.
struct ra8_tls_session_handle * ra8_tls_session_t
Opaque TLS session handle (typed pointer into the static pool).
ra8_err_t ra8_tls_session_open(ra8_tls_session_t *out_session, const ra8_tls_session_cfg_t *cfg)
Allocate a TLS session from the static pool.
struct ra8_tls_session_cfg ra8_tls_session_cfg_t
- Since
- 0.1.0