The function you are looking for is:
bool BN_is_bit_set( const BIGNUM *a, int n );
... it behaves exactly like the bitwise operator AND
. For example, to see if the right-most bit is on I would call the function as follows:
bool is_set = BN_is_bit_set( ptr_my_bignum, 0x1 );
... notice my mask is 0x1
(which implies 1
in binary). More information on the BIGNUM library can be found here.