[#RSA_X931_derive_ex]
= RSA&lowbar;X931&lowbar;derive&lowbar;ex
:mrdocs:

Derive an RSA key from ANSI X9&period;31 intermediate values (deprecated)&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;deprecated&rsqb;&rsqb;
int
RSA&lowbar;X931&lowbar;derive&lowbar;ex(
    xref:RSA.adoc[RSA]* rsa,
    xref:BIGNUM.adoc[BIGNUM]* p1,
    xref:BIGNUM.adoc[BIGNUM]* p2,
    xref:BIGNUM.adoc[BIGNUM]* q1,
    xref:BIGNUM.adoc[BIGNUM]* q2,
    xref:BIGNUM.adoc[BIGNUM] const* Xp1,
    xref:BIGNUM.adoc[BIGNUM] const* Xp2,
    xref:BIGNUM.adoc[BIGNUM] const* Xp,
    xref:BIGNUM.adoc[BIGNUM] const* Xq1,
    xref:BIGNUM.adoc[BIGNUM] const* Xq2,
    xref:BIGNUM.adoc[BIGNUM] const* Xq,
    xref:BIGNUM.adoc[BIGNUM] const* e,
    xref:BN_GENCB.adoc[BN&lowbar;GENCB]* cb);
----

[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
| *rsa*
| Destination RSA object that receives the derived key&period;
| *p1*
| Optional output for the first p factor component, or NULL&period;
| *p2*
| Optional output for the second p factor component, or NULL&period;
| *q1*
| Optional output for the first q factor component, or NULL&period;
| *q2*
| Optional output for the second q factor component, or NULL&period;
| *Xp1*
| X9&period;31 Xp1 input value&period;
| *Xp2*
| X9&period;31 Xp2 input value&period;
| *Xp*
| X9&period;31 Xp input value&period;
| *Xq1*
| X9&period;31 Xq1 input value&period;
| *Xq2*
| X9&period;31 Xq2 input value&period;
| *Xq*
| X9&period;31 Xq input value&period;
| *e*
| Public exponent&period;
| *cb*
| Optional BN&lowbar;GENCB progress callback, or NULL&period;
|===


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