[openssl-users] openssl 1.1.1 opaque structures
Viktor Dukhovni
openssl-users at dukhovni.org
Mon Nov 26 13:32:33 UTC 2018
> On Nov 26, 2018, at 12:45 AM, priya p <priyahere223 at gmail.com> wrote:
>
> I am trying to fix this part of code:
>
> int Func1 (var, bn) {
> *var = rc_vmalloc(bn->top * BN_BYTES); ------------------> Trying to fix this. Error it throws is " error: dereferencing pointer to incomplete type".
>
> (*var)->l = BN_bn2bin(bn, (unsigned char *)(*var)->v);
> .
> .
> }
Have you considered looking at the BN_bn2bin documentation?
https://www.openssl.org/docs/man1.0.2/crypto/BN_bn2bin.html
SYNOPSIS:
int BN_bn2bin(const BIGNUM *a, unsigned char *to);
DESCRIPTION:
BN_bn2bin() converts the absolute value of a into big-endian form and
stores it at to. to must point to BN_num_bytes(a) bytes of memory.
--
Viktor.
More information about the openssl-users
mailing list