[#EVP_PKEY_CTX_set_dh_kdf_md]
= EVP&lowbar;PKEY&lowbar;CTX&lowbar;set&lowbar;dh&lowbar;kdf&lowbar;md
:mrdocs:

Set the message digest used for DH key&hyphen;derivation (KDF) on a key context&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
int
EVP&lowbar;PKEY&lowbar;CTX&lowbar;set&lowbar;dh&lowbar;kdf&lowbar;md(
    xref:EVP_PKEY_CTX.adoc[EVP&lowbar;PKEY&lowbar;CTX]* ctx,
    xref:EVP_MD.adoc[EVP&lowbar;MD] const* md);
----

== Return Value

1 on success, or a non&hyphen;positive value on failure&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *ctx*
| Key context configured for a DH KDF operation&period;
| *md*
| Digest method such as EVP&lowbar;sha256()&semi; ownership is not transferred&period;
|===


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