crypto/ec/ecp_smpl.c:288: error: BUFFER_OVERRUN_L3
  Offset: [1, +oo] Size: [0, 8388607] by call to `BN_mod_sqr`.
Showing all 17 steps of the trace


crypto/ec/ecp_smpl.c:259:9: Call
257.       }
258.       BN_CTX_start(ctx);
259.       a = BN_CTX_get(ctx);
               ^
260.       b = BN_CTX_get(ctx);
261.       tmp_1 = BN_CTX_get(ctx);

crypto/bn/bn_ctx.c:229:5: Call
  227.       }
  228.       /* OK, make sure the returned bignum is "zero" */
  229.       BN_zero(ret);
             ^
  230.       /* clear BN_FLG_CONSTTIME if leaked from previous frames */
  231.       ret->flags &= (~BN_FLG_CONSTTIME);

crypto/bn/bn_lib.c:359:1: Parameter `*a->d`
    357.   }
    358.   
    359. > int BN_set_word(BIGNUM *a, BN_ULONG w)
    360.   {
    361.       bn_check_top(a);

crypto/bn/bn_lib.c:362:9: Call
    360.   {
    361.       bn_check_top(a);
    362.       if (bn_expand(a, (int)sizeof(BN_ULONG) * 8) == NULL)
                   ^
    363.           return 0;
    364.       a->neg = 0;

crypto/bn/bn_lcl.h:660:1: Parameter `*a->d`
      658.                            const BIGNUM *add, const BIGNUM *rem, BN_CTX *ctx);
      659.   
      660. > static ossl_inline BIGNUM *bn_expand(BIGNUM *a, int bits)
      661.   {
      662.       if (bits > (INT_MAX - BN_BITS2 + 1))

crypto/ec/ecp_smpl.c:288:14: Call
286.               goto err;
287.       } else if (!BN_is_zero(b)) {
288.           if (!BN_mod_sqr(tmp_1, a, p, ctx))
                    ^
289.               goto err;
290.           if (!BN_mod_mul(tmp_2, tmp_1, a, p, ctx))

crypto/bn/bn_mod.c:222:1: Parameter `*r->d`
  220.   }
  221.   
  222. > int BN_mod_sqr(BIGNUM *r, const BIGNUM *a, const BIGNUM *m, BN_CTX *ctx)
  223.   {
  224.       if (!BN_sqr(r, a, ctx))

crypto/bn/bn_mod.c:224:10: Call
  222.   int BN_mod_sqr(BIGNUM *r, const BIGNUM *a, const BIGNUM *m, BN_CTX *ctx)
  223.   {
  224.       if (!BN_sqr(r, a, ctx))
                  ^
  225.           return 0;
  226.       /* r->neg == 0,  thus we don't need BN_nnmod */

crypto/bn/bn_sqr.c:19:15: Call
    17.   int BN_sqr(BIGNUM *r, const BIGNUM *a, BN_CTX *ctx)
    18.   {
    19.       int ret = bn_sqr_fixed_top(r, a, ctx);
                        ^
    20.   
    21.       bn_correct_top(r);

crypto/bn/bn_sqr.c:27:1: Parameter `r->top`
      25.   }
      26.   
      27. > int bn_sqr_fixed_top(BIGNUM *r, const BIGNUM *a, BN_CTX *ctx)
      28.   {
      29.       int max, al;

crypto/bn/bn_sqr.c:21:5: Call
    19.       int ret = bn_sqr_fixed_top(r, a, ctx);
    20.   
    21.       bn_correct_top(r);
              ^
    22.       bn_check_top(r);
    23.   

crypto/bn/bn_lib.c:944:1: <Offset trace>
942.   }
943.   
944. > void bn_correct_top(BIGNUM *a)
945.   {
946.       BN_ULONG *ftl;

crypto/bn/bn_lib.c:944:1: Parameter `a->top`
      942.   }
      943.   
      944. > void bn_correct_top(BIGNUM *a)
      945.   {
      946.       BN_ULONG *ftl;

crypto/bn/bn_lib.c:947:5: Assignment
      945.   {
      946.       BN_ULONG *ftl;
      947.       int tmp_top = a->top;
                 ^
      948.   
      949.       if (tmp_top > 0) {

crypto/bn/bn_lib.c:944:1: <Length trace>
942.   }
943.   
944. > void bn_correct_top(BIGNUM *a)
945.   {
946.       BN_ULONG *ftl;

crypto/bn/bn_lib.c:944:1: Parameter `*a->d`
      942.   }
      943.   
      944. > void bn_correct_top(BIGNUM *a)
      945.   {
      946.       BN_ULONG *ftl;

crypto/bn/bn_lib.c:950:14: Array access: Offset: [1, +oo] Size: [0, 8388607] by call to `BN_mod_sqr` 
      948.   
      949.       if (tmp_top > 0) {
      950.           for (ftl = &(a->d[tmp_top]); tmp_top > 0; tmp_top--) {
                          ^
      951.               ftl--;
      952.               if (*ftl != 0)
