
#use wml::openssl-macros area=docs page=EVP_PKEY_print_private

<title>Documents, EVP_PKEY_print_private(3)</title>

<h1>EVP_PKEY_print_private(3)</h1>

#use wml::imp::generic

{:
## What's this? [[s|(<STRONG>[^<].+?)</A>(</STRONG><DD>)|$1$2|sg]]
[[s|<P>\s+<P>|<P>|sg]]
[[s|<P>\s+</|</|sg]]
[[s|<DD>\s*<DT>|<DD>&nbsp;<DT>|sg]]
[[s|<DD>\s*</DL>|<DD>&nbsp;</DL>|sg]]
[[s|\[|&#91;|sg]]
[[s|\]|&#93;|sg]]

<!-- INDEX BEGIN -->

<UL>

	<LI><A HREF="#NAME">NAME</A>
	<LI><A HREF="#SYNOPSIS">SYNOPSIS</A>
	<LI><A HREF="#DESCRIPTION">DESCRIPTION</A>
	<LI><A HREF="#NOTES">NOTES</A>
	<LI><A HREF="#RETURN_VALUES">RETURN VALUES</A>
	<LI><A HREF="#SEE_ALSO">SEE ALSO</A>
	<LI><A HREF="#HISTORY">HISTORY</A>
</UL>
<!-- INDEX END -->

<HR>
<P>
<HR>
<H1><A NAME="NAME">NAME</A></H1>
<P>
EVP_PKEY_print_public, EVP_PKEY_print_private, EVP_PKEY_print_params -
public key algorithm printing routines.

</P>
<P>
<HR>
<H1><A NAME="SYNOPSIS">SYNOPSIS</A></H1>
<PRE> #include &lt;openssl/evp.h&gt;
</PRE>
<PRE> int EVP_PKEY_print_public(BIO *out, const EVP_PKEY *pkey,
                                int indent, ASN1_PCTX *pctx);
 int EVP_PKEY_print_private(BIO *out, const EVP_PKEY *pkey,
                                int indent, ASN1_PCTX *pctx);
 int EVP_PKEY_print_params(BIO *out, const EVP_PKEY *pkey,
                                int indent, ASN1_PCTX *pctx);
</PRE>
<P>
<HR>
<H1><A NAME="DESCRIPTION">DESCRIPTION</A></H1>
<P>
The functions <CODE>EVP_PKEY_print_public(),</CODE>
<CODE>EVP_PKEY_print_private()</CODE> and
<CODE>EVP_PKEY_print_params()</CODE> print out the public, private or
parameter components of key <STRONG>pkey</STRONG> respectively. The key is sent to BIO <STRONG>out</STRONG> in human readable form. The parameter <STRONG>indent</STRONG> indicated how far the printout should be indented.

</P>
<P>
The <STRONG>pctx</STRONG> parameter allows the print output to be finely tuned by using ASN1 printing
options. If <STRONG>pctx</STRONG> is set to NULL then default values will be used.

</P>
<P>
<HR>
<H1><A NAME="NOTES">NOTES</A></H1>
<P>
Currently no public key algorithms include any options in the <STRONG>pctx</STRONG> parameter parameter.

</P>
<P>
If the key does not include all the components indicated by the function
then only those contained in the key will be printed. For example passing a
public key to <CODE>EVP_PKEY_print_private()</CODE> will only print the
public components.

</P>
<P>
<HR>
<H1><A NAME="RETURN_VALUES">RETURN VALUES</A></H1>
<P>
These functions all return 1 for success and 0 or a negative value for
failure. In particular a return value of -2 indicates the operation is not
supported by the public key algorithm.

</P>
<P>
<HR>
<H1><A NAME="SEE_ALSO">SEE ALSO</A></H1>
<P>
<A HREF="../crypto/EVP_PKEY_CTX_new.html#">EVP_PKEY_CTX_new(3)</A>,
<A HREF="../crypto/EVP_PKEY_keygen.html#">EVP_PKEY_keygen(3)</A> 

 

</P>
<P>
<HR>
<H1><A NAME="HISTORY">HISTORY</A></H1>
<P>
These functions were first added to OpenSSL 1.0.0.

</P>
:}


