[#SSL_get0_next_proto_negotiated]
= SSL&lowbar;get0&lowbar;next&lowbar;proto&lowbar;negotiated
:mrdocs:

Return the Next Protocol Negotiation (NPN) protocol selected on this connection&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
void
SSL&lowbar;get0&lowbar;next&lowbar;proto&lowbar;negotiated(
    xref:SSL.adoc[SSL] const* s,
    unsigned char const** data,
    unsigned int* len);
----

== Description

NPN is obsolete relative to ALPN and cannot be used with QUIC SSL objects&period;

== Return Value

the Next Protocol Negotiation (NPN) protocol selected on this connection&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *s*
| SSL connection that completed NPN during the handshake&period;
| *data*
| Receives a pointer to the protocol name (not NUL&hyphen;terminated), or NULL if none was negotiated&period;
| *len*
| Receives the length of the protocol name in bytes, or 0 if `data` is NULL&period;
|===


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