libressl-DH_size3
Get diffie-hellman prime size
Usage
Crypto Library (libcrypto, -lcrypto)
#include <openssl/dh.h>
int
DH_size(const DH *dh);
int
DH_bits(const DH *dh);
Overview
DH_size() returns the Diffie-Hellman prime size in bytes. It can be used to determine how much memory must be allocated for the shared secret computed by DH_compute_key(3).
DH_bits() returns the number of significant bits in the key.
dh and dh->p must not be NULL.