[#EVP_PKEY_Q_keygen]
= EVP&lowbar;PKEY&lowbar;Q&lowbar;keygen
:mrdocs:

Quickly generate a key of algorithm `type` using varargs size&sol;curve parameters&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
xref:EVP_PKEY.adoc[EVP&lowbar;PKEY]*
EVP&lowbar;PKEY&lowbar;Q&lowbar;keygen(
    xref:OSSL_LIB_CTX.adoc[OSSL&lowbar;LIB&lowbar;CTX]* libctx,
    char const* propq,
    char const* type, &period;&period;&period;);
----

== Return Value

Newly allocated EVP&lowbar;PKEY, or NULL on failure&semi; free with EVP&lowbar;PKEY&lowbar;free()&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *libctx*
| Library context for fetches, or NULL for the default&period;
| *propq*
| Property query string, or NULL&period;
| *type*
| Algorithm name (for example &quot;RSA&quot;, &quot;EC&quot;, &quot;ED25519&quot;)&period;
|===


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