[#SSL_CTX_set_session_id_context]
= SSL&lowbar;CTX&lowbar;set&lowbar;session&lowbar;id&lowbar;context
:mrdocs:

Set the server&hyphen;side session&hyphen;id context within which sessions may be reused for a context&period;

== Synopsis

Declared in `&lt;openssl&sol;ssl&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
int
SSL&lowbar;CTX&lowbar;set&lowbar;session&lowbar;id&lowbar;context(
    xref:SSL_CTX.adoc[SSL&lowbar;CTX]* ctx,
    unsigned char const* sid&lowbar;ctx,
    unsigned int sid&lowbar;ctx&lowbar;len);
----

== Return Value

1 on success, or 0 if `sid&lowbar;ctx&lowbar;len` is too large&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *ctx*
| SSL context (server) whose sid&lowbar;ctx is set and inherited by new SSL objects&period;
| *sid&lowbar;ctx*
| Opaque application context bytes stored with exported sessions&period;
| *sid&lowbar;ctx&lowbar;len*
| Length of `sid&lowbar;ctx` (must not exceed SSL&lowbar;MAX&lowbar;SID&lowbar;CTX&lowbar;LENGTH)&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
