crypto/bn/bn_mont.c:299: error: BUFFER_OVERRUN_L1
  Offset: [3, +oo] (⇐ [0, +oo] + 3) Size: 2 by call to `BN_mod_inverse`.
Showing all 9 steps of the trace


crypto/bn/bn_mont.c:272:1: Array declaration
270.   	}
271.   
272. > int BN_MONT_CTX_set(BN_MONT_CTX *mont, const BIGNUM *mod, BN_CTX *ctx)
273.   	{
274.   	int ret = 0;

crypto/bn/bn_mont.c:294:3: Assignment
292.   		buf[0]=mod->d[0]; /* tmod = N mod word size */
293.   		buf[1]=0;
294.   		tmod.d=buf;
         ^
295.   		tmod.top = buf[0] != 0 ? 1 : 0;
296.   		tmod.dmax=2;

crypto/bn/bn_mont.c:299:8: Call
297.   		tmod.neg=0;
298.   							/* Ri = R^-1 mod N*/
299.   		if ((BN_mod_inverse(Ri,R,&tmod,ctx)) == NULL)
              ^
300.   			goto err;
301.   		if (!BN_lshift(Ri,Ri,BN_BITS2)) goto err; /* R*Ri */

crypto/bn/bn_gcd.c:206:1: Parameter `*n->d`
  204.   
  205.   /* solves ax == 1 (mod n) */
  206. > BIGNUM *BN_mod_inverse(BIGNUM *in,
  207.   	const BIGNUM *a, const BIGNUM *n, BN_CTX *ctx)
  208.   	{

crypto/bn/bn_gcd.c:235:6: Call
  233.   	BN_zero(Y);
  234.   	if (BN_copy(B,a) == NULL) goto err;
  235.   	if (BN_copy(A,n) == NULL) goto err;
              ^
  236.   	A->neg = 0;
  237.   	if (B->neg || (BN_ucmp(B, A) >= 0))

crypto/bn/bn_lib.c:497:1: <Length trace>
495.   	}
496.   
497. > BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
498.   	{
499.   	int i;

crypto/bn/bn_lib.c:497:1: Parameter `*b->d`
    495.   	}
    496.   
    497. > BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
    498.   	{
    499.   	int i;

crypto/bn/bn_lib.c:510:2: Assignment
    508.   #if 1
    509.   	A=a->d;
    510.   	B=b->d;
            ^
    511.   	for (i=b->top>>2; i>0; i--,A+=4,B+=4)
    512.   		{

crypto/bn/bn_lib.c:514:33: Array access: Offset: [3, +oo] (⇐ [0, +oo] + 3) Size: 2 by call to `BN_mod_inverse` 
    512.   		{
    513.   		BN_ULONG a0,a1,a2,a3;
    514.   		a0=B[0]; a1=B[1]; a2=B[2]; a3=B[3];
                                           ^
    515.   		A[0]=a0; A[1]=a1; A[2]=a2; A[3]=a3;
    516.   		}
