[#SSL_CTX_set_generate_session_id]
= SSL&lowbar;CTX&lowbar;set&lowbar;generate&lowbar;session&lowbar;id
:mrdocs:

Set the callback used to generate new session IDs for server SSL objects from 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;generate&lowbar;session&lowbar;id(
    xref:SSL_CTX.adoc[SSL&lowbar;CTX]* ctx,
    xref:GEN_SESSION_CB.adoc[GEN&lowbar;SESSION&lowbar;CB] cb);
----

== Return Value

1 on success, or 0 on failure&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *ctx*
| Server SSL context whose session&hyphen;ID generator is replaced&period;
| *cb*
| Generator callback&semi; see GEN&lowbar;SESSION&lowbar;CB&period;
|===


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