[#EVP_DigestSignInit]
= EVP&lowbar;DigestSignInit
:mrdocs:

Initialise `ctx` for a one&hyphen;shot or streaming DigestSign with key `pkey&period;`

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
int
EVP&lowbar;DigestSignInit(
    xref:EVP_MD_CTX.adoc[EVP&lowbar;MD&lowbar;CTX]* ctx,
    xref:EVP_PKEY_CTX.adoc[EVP&lowbar;PKEY&lowbar;CTX]** pctx,
    xref:EVP_MD.adoc[EVP&lowbar;MD] const* type,
    xref:ENGINE.adoc[ENGINE]* e,
    xref:EVP_PKEY.adoc[EVP&lowbar;PKEY]* pkey);
----

== Return Value

1 on success, or 0 on error&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *ctx*
| Digest&sol;sign context to initialise&period;
| *pctx*
| Optional out&hyphen;parameter receiving the internal EVP&lowbar;PKEY&lowbar;CTX, or NULL&period;
| *type*
| Digest to use, or NULL for algorithms that do not take a separate MD&period;
| *e*
| Legacy ENGINE, or NULL&period;
| *pkey*
| Private key used for signing&period;
|===


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