Lines Matching refs:bn
72 BIGNUM *bn = NULL; in BN_bin2bn() local
75 ret = bn = BN_new(); in BN_bin2bn()
90 if (bn) { in BN_bin2bn()
91 BN_free(bn); in BN_bin2bn()
194 char *BN_bn2hex(const BIGNUM *bn) { in BN_bn2hex() argument
199 buf = (char *)OPENSSL_malloc(bn->top * BN_BYTES * 2 + 2); in BN_bn2hex()
206 if (bn->neg) { in BN_bn2hex()
210 if (BN_is_zero(bn)) { in BN_bn2hex()
214 for (i = bn->top - 1; i >= 0; i--) { in BN_bn2hex()
217 v = ((int)(bn->d[i] >> (long)j)) & 0xff; in BN_bn2hex()
231 static void decode_hex(BIGNUM *bn, const char *in, int i) { in decode_hex() argument
255 bn->d[h++] = l; in decode_hex()
263 bn->top = h; in decode_hex()
267 static void decode_dec(BIGNUM *bn, const char *in, int in_len) { in decode_dec() argument
280 BN_mul_word(bn, BN_DEC_CONV); in decode_dec()
281 BN_add_word(bn, l); in decode_dec()
288 typedef void (*decode_func) (BIGNUM *bn, const char *in, int i);
492 BN_ULONG BN_get_word(const BIGNUM *bn) { in BN_get_word() argument
493 switch (bn->top) { in BN_get_word()
497 return bn->d[0]; in BN_get_word()