apps/s_client.c:241: error: BUFFER_OVERRUN_L3
  Offset: [1, +oo] Size: [0, 8388607] by call to `BN_is_prime_ex`.
Showing all 21 steps of the trace


apps/s_client.c:238:9: Call
236.       int ret =
237.           g != NULL && N != NULL && bn_ctx != NULL && BN_is_odd(N) &&
238.           BN_is_prime_ex(N, SRP_NUMBER_ITERATIONS_FOR_PRIME, bn_ctx, NULL) == 1 &&
               ^
239.           p != NULL && BN_rshift1(p, N) &&
240.           /* p = (N-1)/2 */

crypto/bn/bn_prime.c:150:12: Call
  148.                      BN_GENCB *cb)
  149.   {
  150.       return BN_is_prime_fasttest_ex(a, checks, ctx_passed, 0, cb);
                    ^
  151.   }
  152.   

crypto/bn/bn_prime.c:227:13: Call
    225.           /* now 1 <= check < a */
    226.   
    227.           j = witness(check, a, A1, A1_odd, k, ctx, mont);
                       ^
    228.           if (j == -1)
    229.               goto err;

crypto/bn/bn_prime.c:253:10: Call
      251.                      BN_MONT_CTX *mont)
      252.   {
      253.       if (!BN_mod_exp_mont(w, w, a1_odd, a, ctx, mont)) /* w := w^a1_odd mod a */
                      ^
      254.           return -1;
      255.       if (BN_is_one(w))

crypto/bn/bn_exp.c:350:14: Call
        348.   
        349.       if (a->neg || BN_ucmp(a, m) >= 0) {
        350.           if (!BN_nnmod(val[0], a, m, ctx))
                            ^
        351.               goto err;
        352.           aa = val[0];

crypto/bn/bn_mod.c:20:11: Call
          18.        */
          19.   
          20.       if (!(BN_mod(r, m, d, ctx)))
                          ^
          21.           return 0;
          22.       if (!r->neg)

crypto/bn/bn_div.c:140:1: Parameter `*dv->d`
            138.    * If 'dv' or 'rm' is NULL, the respective value is not returned.
            139.    */
            140. > int BN_div(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num, const BIGNUM *divisor,
            141.              BN_CTX *ctx)
            142.   {

apps/s_client.c:239:22: Call
237.           g != NULL && N != NULL && bn_ctx != NULL && BN_is_odd(N) &&
238.           BN_is_prime_ex(N, SRP_NUMBER_ITERATIONS_FOR_PRIME, bn_ctx, NULL) == 1 &&
239.           p != NULL && BN_rshift1(p, N) &&
                            ^
240.           /* p = (N-1)/2 */
241.           BN_is_prime_ex(p, SRP_NUMBER_ITERATIONS_FOR_PRIME, bn_ctx, NULL) == 1 &&

crypto/bn/bn_shift.c:46:1: Parameter `*r->d`
  44.   }
  45.   
  46. > int BN_rshift1(BIGNUM *r, const BIGNUM *a)
  47.   {
  48.       BN_ULONG *ap, *rp, t, c;

apps/s_client.c:241:9: Call
239.           p != NULL && BN_rshift1(p, N) &&
240.           /* p = (N-1)/2 */
241.           BN_is_prime_ex(p, SRP_NUMBER_ITERATIONS_FOR_PRIME, bn_ctx, NULL) == 1 &&
               ^
242.           r != NULL &&
243.           /* verify g^((N-1)/2) == -1 (mod N) */

crypto/bn/bn_prime.c:147:1: Parameter `*a->d`
  145.   }
  146.   
  147. > int BN_is_prime_ex(const BIGNUM *a, int checks, BN_CTX *ctx_passed,
  148.                      BN_GENCB *cb)
  149.   {

crypto/bn/bn_prime.c:150:12: Call
  148.                      BN_GENCB *cb)
  149.   {
  150.       return BN_is_prime_fasttest_ex(a, checks, ctx_passed, 0, cb);
                    ^
  151.   }
  152.   

crypto/bn/bn_prime.c:153:1: Parameter `*a->d`
    151.   }
    152.   
    153. > int BN_is_prime_fasttest_ex(const BIGNUM *a, int checks, BN_CTX *ctx_passed,
    154.                               int do_trial_division, BN_GENCB *cb)
    155.   {

crypto/bn/bn_prime.c:227:13: Call
    225.           /* now 1 <= check < a */
    226.   
    227.           j = witness(check, a, A1, A1_odd, k, ctx, mont);
                       ^
    228.           if (j == -1)
    229.               goto err;

crypto/bn/bn_prime.c:249:1: Parameter `*a->d`
      247.   }
      248.   
      249. > static int witness(BIGNUM *w, const BIGNUM *a, const BIGNUM *a1,
      250.                      const BIGNUM *a1_odd, int k, BN_CTX *ctx,
      251.                      BN_MONT_CTX *mont)

crypto/bn/bn_prime.c:253:10: Call
      251.                      BN_MONT_CTX *mont)
      252.   {
      253.       if (!BN_mod_exp_mont(w, w, a1_odd, a, ctx, mont)) /* w := w^a1_odd mod a */
                      ^
      254.           return -1;
      255.       if (BN_is_one(w))

crypto/bn/bn_exp.c:389:14: <Offset trace>
387.           /* 2^(top*BN_BITS2) - m */
388.           r->d[0] = (0 - m->d[0]) & BN_MASK2;
389.           for (i = 1; i < j; i++)
                    ^
390.               r->d[i] = (~m->d[i]) & BN_MASK2;
391.           r->top = j;

crypto/bn/bn_exp.c:389:14: Assignment
        387.           /* 2^(top*BN_BITS2) - m */
        388.           r->d[0] = (0 - m->d[0]) & BN_MASK2;
        389.           for (i = 1; i < j; i++)
                            ^
        390.               r->d[i] = (~m->d[i]) & BN_MASK2;
        391.           r->top = j;

crypto/bn/bn_exp.c:294:1: <Length trace>
292.   }
293.   
294. > int BN_mod_exp_mont(BIGNUM *rr, const BIGNUM *a, const BIGNUM *p,
295.                       const BIGNUM *m, BN_CTX *ctx, BN_MONT_CTX *in_mont)
296.   {

crypto/bn/bn_exp.c:294:1: Parameter `*m->d`
        292.   }
        293.   
        294. > int BN_mod_exp_mont(BIGNUM *rr, const BIGNUM *a, const BIGNUM *p,
        295.                       const BIGNUM *m, BN_CTX *ctx, BN_MONT_CTX *in_mont)
        296.   {

crypto/bn/bn_exp.c:390:25: Array access: Offset: [1, +oo] Size: [0, 8388607] by call to `BN_is_prime_ex` 
        388.           r->d[0] = (0 - m->d[0]) & BN_MASK2;
        389.           for (i = 1; i < j; i++)
        390.               r->d[i] = (~m->d[i]) & BN_MASK2;
                                       ^
        391.           r->top = j;
        392.           /*
