OpenSSL BN_CTX_new(3openssl)
NNNNAAAAMMMMEEEEBN_CTX_new, BN_CTX_init, BN_CTX_free - allocate and free
BN_CTX structures
SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS#include
BN_CTX *BN_CTX_new(void);
void BN_CTX_init(BN_CTX *c);
void BN_CTX_free(BN_CTX *c);
DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNNA BBBBNNNN_CCCCTTTTXXXX is a structure that holds BBBBIIIIGGGGNNNNUUUUMMMM temporary
variables used by library functions. Since dynamic memory allocation to create BBBBIIIIGGGGNNNNUUUUMMMMs is rather expensive when usedin conjunction with repeated subroutine calls, the BBBBNNNN_CCCCTTTTXXXX
structure is used.BN_CTX_new() allocates and initializes a BBBBNNNN_CCCCTTTTXXXX structure.
BN_CTX_init() initializes an existing uninitialized BBBBNNNN_CCCCTTTTXXXX.
BN_CTX_free() frees the components of the BBBBNNNN_CCCCTTTTXXXX, and if it
was created by BN_CTX_new(), also the structure itself. If
BN_CTX_start(3) has been used on the BBBBNNNN_CCCCTTTTXXXX, BN_CTX_end(3)
must be called before the BBBBNNNN_CCCCTTTTXXXX may be freed by
BN_CTX_free().
RRRREEEETTTTUUUURRRRNNNN VVVVAAAALLLLUUUUEEEESSSSBN_CTX_new() returns a pointer to the BBBBNNNN_CCCCTTTTXXXX. If the
allocation fails, it returns NNNNUUUULLLLLLLL and sets an error codethat can be obtained by ERR_get_error(3).
BN_CTX_init() and BN_CTX_free() have no return values.
SSSSEEEEEEEE AAAALLLLSSSSOOOObn(3), ERR_get_error(3), BN_add(3), BN_CTX_start(3)
HHHHIIIISSSSTTTTOOOORRRRYYYYBN_CTX_new() and BN_CTX_free() are available in all versions
on SSLeay and OpenSSL. BN_CTX_init() was added in SSLeay
0.9.1b.25/Sep/2002 Last change: 0.9.8o 1
OpenSSL BN_CTX_new(3openssl)
25/Sep/2002 Last change: 0.9.8o 2