test/bntest.c:1540: error: BUFFER_OVERRUN_L3
  Offset added: [8, +oo] Size: [0, 536870848] by call to `BN_mod_exp`.
Showing all 18 steps of the trace


test/bntest.c:1535:17: Call
1533.               || !TEST_ptr(e = getBN(s, "E"))
1534.               || !TEST_ptr(m = getBN(s, "M"))
1535.               || !TEST_ptr(mod_exp = getBN(s, "ModExp"))
                        ^
1536.               || !TEST_ptr(ret = BN_new())
1537.               || !TEST_ptr(d = BN_new()))

test/bntest.c:107:9: Call
  105.       }
  106.   
  107.       if (parseBN(&ret, hex) != (int)strlen(hex)) {
                 ^
  108.           TEST_error("Could not decode '%s'", hex);
  109.           return NULL;

test/bntest.c:88:12: Call
    86.   {
    87.       *out = NULL;
    88.       return BN_hex2bn(out, in);
                     ^
    89.   }
    90.   

crypto/bn/bn_conv.c:126:1: Parameter `(*bn)->top`
      124.   #endif
      125.   
      126. > int BN_hex2bn(BIGNUM **bn, const char *a)
      127.   {
      128.       BIGNUM *ret = NULL;

test/bntest.c:1540:10: Call
1538.           goto err;
1539.   
1540.       if (!TEST_true(BN_mod_exp(ret, a, e, m, ctx))
                 ^
1541.               || !equalBN("A ^ E (mod M)", mod_exp, ret))
1542.           goto err;

crypto/bn/bn_exp.c:89:1: Parameter `m->top`
  87.   }
  88.   
  89. > int BN_mod_exp(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, const BIGNUM *m,
  90.                  BN_CTX *ctx)
  91.   {

crypto/bn/bn_exp.c:134:9: Call
  132.   
  133.   #ifdef MONT_MUL_MOD
  134.       if (BN_is_odd(m)) {
                 ^
  135.   # ifdef MONT_EXP_WORD
  136.           if (a->top == 1 && !a->neg

crypto/bn/bn_lib.c:881:1: Parameter `a->top`
    879.   }
    880.   
    881. > int BN_is_odd(const BIGNUM *a)
    882.   {
    883.       return (a->top > 0) && (a->d[0] & 1);

crypto/bn/bn_exp.c:149:15: Call
  147.   #ifdef RECP_MUL_MOD
  148.       {
  149.           ret = BN_mod_exp_recp(r, a, p, m, ctx);
                       ^
  150.       }
  151.   #else

crypto/bn/bn_exp.c:161:1: Parameter `m->top`
    159.   }
    160.   
    161. > int BN_mod_exp_recp(BIGNUM *r, const BIGNUM *a, const BIGNUM *p,
    162.                       const BIGNUM *m, BN_CTX *ctx)
    163.   {

crypto/bn/bn_exp.c:200:14: Call
    198.       if (m->neg) {
    199.           /* ignore sign of 'm' */
    200.           if (!BN_copy(aa, m))
                        ^
    201.               goto err;
    202.           aa->neg = 0;

crypto/bn/bn_lib.c:281:1: <Offset trace>
279.   }
280.   
281. > BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
282.   {
283.       bn_check_top(b);

crypto/bn/bn_lib.c:281:1: Parameter `b->top`
      279.   }
      280.   
      281. > BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
      282.   {
      283.       bn_check_top(b);

crypto/bn/bn_lib.c:281:1: <Length trace>
279.   }
280.   
281. > BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
282.   {
283.       bn_check_top(b);

crypto/bn/bn_lib.c:281:1: Parameter `*a->d`
      279.   }
      280.   
      281. > BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
      282.   {
      283.       bn_check_top(b);

crypto/bn/bn_lib.c:287:9: Call
      285.       if (a == b)
      286.           return a;
      287.       if (bn_wexpand(a, b->top) == NULL)
                     ^
      288.           return NULL;
      289.   

crypto/bn/bn_lib.c:962:1: Parameter `*a->d`
        960.   }
        961.   
        962. > BIGNUM *bn_wexpand(BIGNUM *a, int words)
        963.   {
        964.       return (words <= a->dmax) ? a : bn_expand2(a, words);

crypto/bn/bn_lib.c:291:9: Array access: Offset added: [8, +oo] Size: [0, 536870848] by call to `BN_mod_exp` 
      289.   
      290.       if (b->top > 0)
      291.           memcpy(a->d, b->d, sizeof(b->d[0]) * b->top);
                     ^
      292.   
      293.       a->neg = b->neg;
