[#EVP_PKEY_assign]
= EVP&lowbar;PKEY&lowbar;assign
:mrdocs:

Assign a low&hyphen;level key object of `type` to an EVP&lowbar;PKEY (deprecated)&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;deprecated&rsqb;&rsqb;
int
EVP&lowbar;PKEY&lowbar;assign(
    xref:EVP_PKEY.adoc[EVP&lowbar;PKEY]* pkey,
    int type,
    void* key);
----

[WARNING]
====
https://en.cppreference.com/cpp/language/attributes/deprecated[Deprecated^]. Use of this entity is allowed but discouraged.
====
== Return Value

1 on success, or 0 on failure&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *pkey*
| Destination key wrapper&semi; previous key material is freed&period;
| *type*
| Key type NID such as EVP&lowbar;PKEY&lowbar;RSA or EVP&lowbar;PKEY&lowbar;EC&period;
| *key*
| Type&hyphen;specific key pointer (for example RSA &ast;) that `pkey` will own&period;
|===


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