Home
last modified time | relevance | path

Searched refs:BN_BITS2 (Results 1 – 19 of 19) sorted by relevance

/freebsd-10-stable/crypto/openssl/crypto/bn/
Dbn_shift.c146 nw = n / BN_BITS2; in BN_lshift()
149 lb = n % BN_BITS2; in BN_lshift()
150 rb = BN_BITS2 - lb; in BN_lshift()
187 nw = n / BN_BITS2; in BN_rshift()
188 rb = n % BN_BITS2; in BN_rshift()
189 lb = BN_BITS2 - rb; in BN_rshift()
194 i = (BN_num_bits(a) - n + (BN_BITS2 - 1)) / BN_BITS2; in BN_rshift()
Dbn_nist.c62 #define BN_NIST_192_TOP (192+BN_BITS2-1)/BN_BITS2
63 #define BN_NIST_224_TOP (224+BN_BITS2-1)/BN_BITS2
64 #define BN_NIST_256_TOP (256+BN_BITS2-1)/BN_BITS2
65 #define BN_NIST_384_TOP (384+BN_BITS2-1)/BN_BITS2
66 #define BN_NIST_521_TOP (521+BN_BITS2-1)/BN_BITS2
69 #if BN_BITS2 == 64
152 #elif BN_BITS2 == 32
322 #if BN_BITS2 == 64
552 #if BN_BITS2==64 in BN_nist_mod_224()
565 #if defined(NIST_INT64) && BN_BITS2!=64 in BN_nist_mod_224()
[all …]
Dbn_lib.c224 return ((i * BN_BITS2) + BN_num_bits_word(a->d[i])); in BN_num_bits()
295 if (words > (INT_MAX / (4 * BN_BITS2))) { in bn_expand_internal()
733 i = n / BN_BITS2; in BN_set_bit()
734 j = n % BN_BITS2; in BN_set_bit()
756 i = n / BN_BITS2; in BN_clear_bit()
757 j = n % BN_BITS2; in BN_clear_bit()
773 i = n / BN_BITS2; in BN_is_bit_set()
774 j = n % BN_BITS2; in BN_is_bit_set()
788 w = n / BN_BITS2; in BN_mask_bits()
789 b = n % BN_BITS2; in BN_mask_bits()
[all …]
Dbn_gf2m.c400 dN = p[0] / BN_BITS2; in BN_GF2m_mod_arr()
412 d0 = n % BN_BITS2; in BN_GF2m_mod_arr()
413 d1 = BN_BITS2 - d0; in BN_GF2m_mod_arr()
414 n /= BN_BITS2; in BN_GF2m_mod_arr()
422 d0 = p[0] % BN_BITS2; in BN_GF2m_mod_arr()
423 d1 = BN_BITS2 - d0; in BN_GF2m_mod_arr()
432 d0 = p[0] % BN_BITS2; in BN_GF2m_mod_arr()
436 d1 = BN_BITS2 - d0; in BN_GF2m_mod_arr()
449 n = p[k] / BN_BITS2; in BN_GF2m_mod_arr()
450 d0 = p[k] % BN_BITS2; in BN_GF2m_mod_arr()
[all …]
Dbn_mont.c397 mont->ri = (BN_num_bits(mod) + (BN_BITS2 - 1)) / BN_BITS2 * BN_BITS2; in BN_MONT_CTX_set()
399 # if defined(OPENSSL_BN_ASM_MONT) && (BN_BITS2<=32) in BN_MONT_CTX_set()
408 if (!(BN_set_bit(R, 2 * BN_BITS2))) in BN_MONT_CTX_set()
419 if (!BN_lshift(Ri, Ri, 2 * BN_BITS2)) in BN_MONT_CTX_set()
443 if (!(BN_set_bit(R, BN_BITS2))) in BN_MONT_CTX_set()
452 if (!BN_lshift(Ri, Ri, BN_BITS2)) in BN_MONT_CTX_set()
Dbn_div.c255 norm_shift = BN_BITS2 - ((BN_num_bits(divisor)) % BN_BITS2); in BN_div()
259 norm_shift += BN_BITS2; in BN_div()
362 q = (BN_ULONG)(((((BN_ULLONG) n0) << BN_BITS2) | n1) / d0); in BN_div()
381 if (t2 <= ((((BN_ULLONG) rem) << BN_BITS2) | wnump[-2])) in BN_div()
Dbn.h187 # define BN_BITS2 64 macro
216 # define BN_BITS2 64 macro
245 # define BN_BITS2 32 macro
745 bits > (INT_MAX - BN_BITS2 + 1) ? \
748 (((bits+BN_BITS2-1)/BN_BITS2) <= (a)->dmax) ? \
751 bn_expand2((a),(bits+BN_BITS2-1)/BN_BITS2) \
834 # define bn_check_size(bn, bits) bn_wcheck_size(bn, ((bits+BN_BITS2-1))/BN_BITS2)
Dexptest.c213 c = (c % BN_BITS) - BN_BITS2; in main()
217 c = (c % BN_BITS) - BN_BITS2; in main()
221 c = (c % BN_BITS) - BN_BITS2; in main()
Dbn_word.c82 ret = (BN_ULLONG) (((ret << (BN_ULLONG) BN_BITS2) | a->d[i]) % in BN_mod_word()
104 j = BN_BITS2 - BN_num_bits_word(w); in BN_div_word()
Dbn_asm.c254 return ((BN_ULONG)(((((BN_ULLONG) h) << BN_BITS2) | l) / (BN_ULLONG) d)); in bn_div_words()
270 assert((i == BN_BITS2) || (h <= (BN_ULONG)1 << i)); in bn_div_words()
272 i = BN_BITS2 - i; in bn_div_words()
278 h = (h << i) | (l >> (BN_BITS2 - i)); in bn_div_words()
339 ll >>= BN_BITS2; in bn_add_words()
342 ll >>= BN_BITS2; in bn_add_words()
345 ll >>= BN_BITS2; in bn_add_words()
348 ll >>= BN_BITS2; in bn_add_words()
358 ll >>= BN_BITS2; in bn_add_words()
Dbn_lcl.h305 # define Hw(t) (((BN_ULONG)((t)>>BN_BITS2))&BN_MASK2)
408 # define LHBITS(a) (((a)>>BN_BITS2)&BN_MASKl)
409 # define LL2HBITS(a) ((BN_ULLONG)((a)&BN_MASKl)<<BN_BITS2)
Dbn_print.c91 for (j = BN_BITS2 - 8; j >= 0; j -= 8) { in BN_bn2hex()
369 for (j = BN_BITS2 - 4; j >= 0; j -= 4) { in BN_print()
Dbntest.c526 BN_bntest_rand(&b, BN_BITS2, -1, 0); in test_div_word()
/freebsd-10-stable/crypto/openssl/engines/
De_ubsec.c607 r->top = (BN_num_bits(m) + BN_BITS2 - 1) / BN_BITS2; in ubsec_mod_exp()
678 r->top = (BN_num_bits(p) + BN_num_bits(q) + BN_BITS2 - 1) / BN_BITS2; in ubsec_mod_exp_crt()
767 if (!bn_wexpand(r, (160 + BN_BITS2 - 1) / BN_BITS2) || in ubsec_dsa_do_sign()
768 (!bn_wexpand(s, (160 + BN_BITS2 - 1) / BN_BITS2))) { in ubsec_dsa_do_sign()
814 r->top = (160 + BN_BITS2 - 1) / BN_BITS2; in ubsec_dsa_do_sign()
815 s->top = (160 + BN_BITS2 - 1) / BN_BITS2; in ubsec_dsa_do_sign()
1012 dh->pub_key->top = (pub_key_len + BN_BITS2 - 1) / BN_BITS2; in ubsec_dh_generate_key()
1014 dh->priv_key->top = (priv_key_len + BN_BITS2 - 1) / BN_BITS2; in ubsec_dh_generate_key()
De_gmp.c272 (BN_BITS2 == GMP_NUMB_BITS)) { in bn2gmp()
295 (BN_BITS2 == GMP_NUMB_BITS)) { in gmp2bn()
/freebsd-10-stable/crypto/openssl/crypto/ec/
Dec2_smpl.c194 if (bn_wexpand(&dest->a, (int)(dest->poly[0] + BN_BITS2 - 1) / BN_BITS2) in ec_GF2m_simple_group_copy()
197 if (bn_wexpand(&dest->b, (int)(dest->poly[0] + BN_BITS2 - 1) / BN_BITS2) in ec_GF2m_simple_group_copy()
226 if (bn_wexpand(&group->a, (int)(group->poly[0] + BN_BITS2 - 1) / BN_BITS2) in ec_GF2m_simple_group_set_curve()
235 if (bn_wexpand(&group->b, (int)(group->poly[0] + BN_BITS2 - 1) / BN_BITS2) in ec_GF2m_simple_group_set_curve()
/freebsd-10-stable/tools/tools/crypto/
Dcryptokeytest.c114 for (k = 0; k < BN_BITS2 / 8; k++) { in bignum_to_le()
119 j += BN_BITS2 / 8; in bignum_to_le()
/freebsd-10-stable/crypto/openssl/crypto/engine/
Deng_cryptodev.c967 for (k = 0; k < BN_BITS2 / 8; k++) { in bn2crparam()
972 j += BN_BITS2 / 8; in bn2crparam()
/freebsd-10-stable/crypto/openssl/doc/crypto/
Dbn_internal.pod79 BN_ULONG *d; /* Pointer to an array of 'BN_BITS2' bit chunks. */