[#BN_asc2bn]
= BN&lowbar;asc2bn
:mrdocs:

Parse an ASCII decimal or hexadecimal integer into a BIGNUM&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
int
BN&lowbar;asc2bn(
    xref:BIGNUM.adoc[BIGNUM]** a,
    char const* str);
----

== Description

A leading &apos;&hyphen;&apos; sets the negative flag&period; Trailing non&hyphen;digit characters are ignored after a successful parse of a number prefix&period;

== Return Value

1 on success, or 0 on parse error&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *a*
| Location of the BIGNUM pointer&semi; allocated if &ast;`a` is NULL&period;
| *str*
| Decimal digits, or a hex string with a leading &quot;0x&quot; &sol; &quot;0X&quot;&period;
|===


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