crypto/bn/bn_mont.c:428: error: BUFFER_OVERRUN_L3
  Offset: [-1, 0] Size: 2 by call to `BN_mod_inverse`.
Showing all 13 steps of the trace


crypto/bn/bn_mont.c:352:1: Array declaration
350.   }
351.   
352. > int BN_MONT_CTX_set(BN_MONT_CTX *mont, const BIGNUM *mod, BN_CTX *ctx)
353.   {
354.       int ret = 0;

crypto/bn/bn_mont.c:371:9: Assignment
369.   
370.           BN_init(&tmod);
371.           tmod.d = buf;
               ^
372.           tmod.dmax = 2;
373.           tmod.neg = 0;

crypto/bn/bn_mont.c:428:14: Call
426.           tmod.top = buf[0] != 0 ? 1 : 0;
427.           /* Ri = R^-1 mod N */
428.           if ((BN_mod_inverse(Ri, R, &tmod, ctx)) == NULL)
                    ^
429.               goto err;
430.           if (!BN_lshift(Ri, Ri, BN_BITS2))

crypto/bn/bn_gcd.c:226:1: Parameter `*n->d`
  224.                                           BN_CTX *ctx);
  225.   
  226. > BIGNUM *BN_mod_inverse(BIGNUM *in,
  227.                          const BIGNUM *a, const BIGNUM *n, BN_CTX *ctx)
  228.   {

crypto/bn/bn_gcd.c:231:10: Call
  229.       BIGNUM *rv;
  230.       int noinv;
  231.       rv = int_bn_mod_inverse(in, a, n, ctx, &noinv);
                  ^
  232.       if (noinv)
  233.           BNerr(BN_F_BN_MOD_INVERSE, BN_R_NO_INVERSE);

crypto/bn/bn_gcd.c:237:1: Parameter `*n->d`
    235.   }
    236.   
    237. > BIGNUM *int_bn_mod_inverse(BIGNUM *in,
    238.                              const BIGNUM *a, const BIGNUM *n, BN_CTX *ctx,
    239.                              int *pnoinv)

crypto/bn/bn_gcd.c:294:26: Call
    292.        */
    293.   
    294.       if (BN_is_odd(n) && (BN_num_bits(n) <= (BN_BITS <= 32 ? 450 : 2048))) {
                                    ^
    295.           /*
    296.            * Binary inversion algorithm; requires odd modulus. This is faster

crypto/bn/bn_lib.c:216:1: <Offset trace>
214.   }
215.   
216. > int BN_num_bits(const BIGNUM *a)
217.   {
218.       int i = a->top - 1;

crypto/bn/bn_lib.c:216:1: Parameter `a->top`
      214.   }
      215.   
      216. > int BN_num_bits(const BIGNUM *a)
      217.   {
      218.       int i = a->top - 1;

crypto/bn/bn_lib.c:218:5: Assignment
      216.   int BN_num_bits(const BIGNUM *a)
      217.   {
      218.       int i = a->top - 1;
                 ^
      219.       bn_check_top(a);
      220.   

crypto/bn/bn_lib.c:216:1: <Length trace>
214.   }
215.   
216. > int BN_num_bits(const BIGNUM *a)
217.   {
218.       int i = a->top - 1;

crypto/bn/bn_lib.c:216:1: Parameter `*a->d`
      214.   }
      215.   
      216. > int BN_num_bits(const BIGNUM *a)
      217.   {
      218.       int i = a->top - 1;

crypto/bn/bn_lib.c:223:47: Array access: Offset: [-1, 0] Size: 2 by call to `BN_mod_inverse` 
      221.       if (BN_is_zero(a))
      222.           return 0;
      223.       return ((i * BN_BITS2) + BN_num_bits_word(a->d[i]));
                                                           ^
      224.   }
      225.   
