crypto/ec/ecdsa_ossl.c:109: error: BUFFER_OVERRUN_L3
  Offset added: [8, +oo] Size: [0, 67108856] by call to `EC_POINT_mul`.
Showing all 29 steps of the trace


crypto/ec/ecdsa_ossl.c:83:10: Call
81.       /* Preallocate space */
82.       order_bits = BN_num_bits(order);
83.       if (!BN_set_bit(k, order_bits)
               ^
84.           || !BN_set_bit(r, order_bits)
85.           || !BN_set_bit(X, order_bits))

crypto/bn/bn_lib.c:595:1: Parameter `a->top`
  593.   }
  594.   
  595. > int BN_set_bit(BIGNUM *a, int n)
  596.   {
  597.       int i, j, k;

crypto/ec/ecdsa_ossl.c:106:16: Call
104.                   }
105.               }
106.           while (BN_is_zero(k));
                      ^
107.   
108.           /* compute r the x-coordinate of generator * k */

crypto/bn/bn_lib.c:853:1: Parameter `a->top`
  851.   }
  852.   
  853. > int BN_is_zero(const BIGNUM *a)
  854.   {
  855.       return a->top == 0;

crypto/ec/ecdsa_ossl.c:109:14: Call
107.   
108.           /* compute r the x-coordinate of generator * k */
109.           if (!EC_POINT_mul(group, tmp_point, k, NULL, NULL, ctx)) {
                    ^
110.               ECerr(EC_F_ECDSA_SIGN_SETUP, ERR_R_EC_LIB);
111.               goto err;

crypto/ec/ec_lib.c:956:1: Parameter `r->X->top`
  954.   }
  955.   
  956. > int EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *g_scalar,
  957.                    const EC_POINT *point, const BIGNUM *p_scalar, BN_CTX *ctx)
  958.   {

crypto/ec/ec_lib.c:967:12: Call
  965.       scalars[0] = p_scalar;
  966.   
  967.       return EC_POINTs_mul(group, r, g_scalar,
                    ^
  968.                            (point != NULL
  969.                             && p_scalar != NULL), points, scalars, ctx);

crypto/ec/ec_lib.c:918:1: Parameter `r->X->top`
    916.    */
    917.   
    918. > int EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
    919.                     size_t num, const EC_POINT *points[],
    920.                     const BIGNUM *scalars[], BN_CTX *ctx)

crypto/ec/ec_lib.c:950:15: Call
    948.       else
    949.           /* use default */
    950.           ret = ec_wNAF_mul(group, r, scalar, num, points, scalars, ctx);
                         ^
    951.   
    952.       BN_CTX_free(new_ctx);

crypto/ec/ec_mult.c:410:1: Parameter `r->X->top`
      408.    * in the addition if scalar != NULL
      409.    */
      410. > int ec_wNAF_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
      411.                   size_t num, const EC_POINT *points[], const BIGNUM *scalars[],
      412.                   BN_CTX *ctx)

crypto/ec/ec_mult.c:453:20: Call
      451.                * always call the ladder version.
      452.                */
      453.               return ec_scalar_mul_ladder(group, r, scalar, NULL, ctx);
                                ^
      454.           }
      455.           if ((scalar == NULL) && (num == 1)) {

crypto/ec/ec_mult.c:139:1: Parameter `r->X->top`
        137.    * Returns 1 on success, 0 otherwise.
        138.    */
        139. > int ec_scalar_mul_ladder(const EC_GROUP *group, EC_POINT *r,
        140.                            const BIGNUM *scalar, const EC_POINT *point,
        141.                            BN_CTX *ctx)

crypto/ec/ec_mult.c:253:13: Call
        251.           || (bn_wexpand(s->Y, group_top) == NULL)
        252.           || (bn_wexpand(s->Z, group_top) == NULL)
        253.           || (bn_wexpand(r->X, group_top) == NULL)
                           ^
        254.           || (bn_wexpand(r->Y, group_top) == NULL)
        255.           || (bn_wexpand(r->Z, group_top) == NULL)

crypto/bn/bn_lib.c:949:1: Parameter `a->top`
          947.   }
          948.   
          949. > BIGNUM *bn_wexpand(BIGNUM *a, int words)
          950.   {
          951.       return (words <= a->dmax) ? a : bn_expand2(a, words);

crypto/bn/bn_lib.c:951:37: Call
          949.   BIGNUM *bn_wexpand(BIGNUM *a, int words)
          950.   {
          951.       return (words <= a->dmax) ? a : bn_expand2(a, words);
                                                     ^
          952.   }
          953.   

crypto/bn/bn_lib.c:245:1: Parameter `b->top`
            243.    */
            244.   
            245. > BIGNUM *bn_expand2(BIGNUM *b, int words)
            246.   {
            247.       if (words > b->dmax) {

crypto/bn/bn_lib.c:248:23: Call
            246.   {
            247.       if (words > b->dmax) {
            248.           BN_ULONG *a = bn_expand_internal(b, words);
                                         ^
            249.           if (!a)
            250.               return NULL;

crypto/bn/bn_lib.c:209:1: <Offset trace>
207.   /* This is used by bn_expand2() */
208.   /* The caller MUST check that words > b->dmax before calling this */
209. > static BN_ULONG *bn_expand_internal(const BIGNUM *b, int words)
210.   {
211.       BN_ULONG *a = NULL;

crypto/bn/bn_lib.c:209:1: Parameter `b->top`
              207.   /* This is used by bn_expand2() */
              208.   /* The caller MUST check that words > b->dmax before calling this */
              209. > static BN_ULONG *bn_expand_internal(const BIGNUM *b, int words)
              210.   {
              211.       BN_ULONG *a = NULL;

crypto/bn/bn_lib.c:209:1: <Length trace>
207.   /* This is used by bn_expand2() */
208.   /* The caller MUST check that words > b->dmax before calling this */
209. > static BN_ULONG *bn_expand_internal(const BIGNUM *b, int words)
210.   {
211.       BN_ULONG *a = NULL;

crypto/bn/bn_lib.c:209:1: Parameter `words`
              207.   /* This is used by bn_expand2() */
              208.   /* The caller MUST check that words > b->dmax before calling this */
              209. > static BN_ULONG *bn_expand_internal(const BIGNUM *b, int words)
              210.   {
              211.       BN_ULONG *a = NULL;

crypto/bn/bn_lib.c:224:13: Call
              222.           a = OPENSSL_secure_zalloc(words * sizeof(*a));
              223.       else
              224.           a = OPENSSL_zalloc(words * sizeof(*a));
                                 ^
              225.       if (a == NULL) {
              226.           BNerr(BN_F_BN_EXPAND_INTERNAL, ERR_R_MALLOC_FAILURE);

crypto/mem.c:228:1: Parameter `num`
                226.   }
                227.   
                228. > void *CRYPTO_zalloc(size_t num, const char *file, int line)
                229.   {
                230.       void *ret = CRYPTO_malloc(num, file, line);

crypto/mem.c:230:17: Call
                228.   void *CRYPTO_zalloc(size_t num, const char *file, int line)
                229.   {
                230.       void *ret = CRYPTO_malloc(num, file, line);
                                       ^
                231.   
                232.       FAILTEST();

crypto/mem.c:201:9: Assignment
                  199.   
                  200.       if (num == 0)
                  201.           return NULL;
                                 ^
                  202.   
                  203.       FAILTEST();

crypto/mem.c:230:5: Assignment
                228.   void *CRYPTO_zalloc(size_t num, const char *file, int line)
                229.   {
                230.       void *ret = CRYPTO_malloc(num, file, line);
                           ^
                231.   
                232.       FAILTEST();

crypto/mem.c:235:5: Assignment
                233.       if (ret != NULL)
                234.           memset(ret, 0, num);
                235.       return ret;
                           ^
                236.   }
                237.   

crypto/bn/bn_lib.c:224:9: Assignment
              222.           a = OPENSSL_secure_zalloc(words * sizeof(*a));
              223.       else
              224.           a = OPENSSL_zalloc(words * sizeof(*a));
                             ^
              225.       if (a == NULL) {
              226.           BNerr(BN_F_BN_EXPAND_INTERNAL, ERR_R_MALLOC_FAILURE);

crypto/bn/bn_lib.c:232:9: Array access: Offset added: [8, +oo] Size: [0, 67108856] by call to `EC_POINT_mul` 
              230.       assert(b->top <= words);
              231.       if (b->top > 0)
              232.           memcpy(a, b->d, sizeof(*a) * b->top);
                             ^
              233.   
              234.       return a;
