[#BN_mod_lshift]
= BN&lowbar;mod&lowbar;lshift
:mrdocs:

Compute r &equals; (a &lt;&lt; n) mod m (left&hyphen;shift then reduce)&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
int
BN&lowbar;mod&lowbar;lshift(
    xref:BIGNUM.adoc[BIGNUM]* r,
    xref:BIGNUM.adoc[BIGNUM] const* a,
    int n,
    xref:BIGNUM.adoc[BIGNUM] const* m,
    xref:BN_CTX.adoc[BN&lowbar;CTX]* ctx);
----

== Return Value

1 on success, or 0 on error&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *r*
| Destination for the result&period;
| *a*
| Value to shift&period;
| *n*
| Number of bits to shift left&semi; must be non&hyphen;negative&period;
| *m*
| Modulus&semi; must be non&hyphen;zero&period;
| *ctx*
| BN&lowbar;CTX for temporary storage&period;
|===


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