crypto/rsa/rsa_ossl.c:684: error: BUFFER_OVERRUN_L3
  Offset added: [8, +oo] Size: [0, +oo] by call to `BN_div`.
Showing all 17 steps of the trace


crypto/rsa/rsa_ossl.c:627:9: Call
625.               goto err;
626.           }
627.           BN_with_flags(p, rsa->p, BN_FLG_CONSTTIME);
               ^
628.           BN_with_flags(q, rsa->q, BN_FLG_CONSTTIME);
629.   

crypto/bn/bn_lib.c:886:1: Parameter `*b->d`
  884.   }
  885.   
  886. > void BN_with_flags(BIGNUM *dest, const BIGNUM *b, int flags)
  887.   {
  888.       dest->d = b->d;

crypto/bn/bn_lib.c:888:5: Assignment
  886.   void BN_with_flags(BIGNUM *dest, const BIGNUM *b, int flags)
  887.   {
  888.       dest->d = b->d;
             ^
  889.       dest->top = b->top;
  890.       dest->dmax = b->dmax;

crypto/rsa/rsa_ossl.c:680:13: Call
678.               }
679.               /* We MUST free dmq1 before any further use of rsa->dmq1 */
680.               BN_free(dmq1);
                   ^
681.           }
682.   

crypto/bn/bn_lib.c:198:1: Parameter `*a->d`
  196.   }
  197.   
  198. > void BN_free(BIGNUM *a)
  199.   {
  200.       if (a == NULL)

crypto/rsa/rsa_ossl.c:684:14: Call
682.   
683.           /* compute I mod p */
684.           if (!BN_mod(r1, c, rsa->p, ctx)) {
                    ^
685.               BN_free(c);
686.               goto err;

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.   {

crypto/bn/bn_div.c:254:10: Call
  252.   
  253.       /* Setup to 'res' */
  254.       if (!bn_wexpand(res, (loop + 1)))
                  ^
  255.           goto err;
  256.       res->neg = (num->neg ^ divisor->neg);

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

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

crypto/bn/bn_lib.c:284:1: Parameter `*b->d`
      282.    */
      283.   
      284. > BIGNUM *bn_expand2(BIGNUM *b, int words)
      285.   {
      286.       bn_check_top(b);

crypto/bn/bn_lib.c:289:23: Call
      287.   
      288.       if (words > b->dmax) {
      289.           BN_ULONG *a = bn_expand_internal(b, words);
                                   ^
      290.           if (!a)
      291.               return NULL;

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

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

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

crypto/bn/bn_lib.c:246:1: Parameter `*b->d`
        244.   /* This is used by bn_expand2() */
        245.   /* The caller MUST check that words > b->dmax before calling this */
        246. > static BN_ULONG *bn_expand_internal(const BIGNUM *b, int words)
        247.   {
        248.       BN_ULONG *a = NULL;

crypto/bn/bn_lib.c:271:9: Array access: Offset added: [8, +oo] Size: [0, +oo] by call to `BN_div` 
        269.       assert(b->top <= words);
        270.       if (b->top > 0)
        271.           memcpy(a, b->d, sizeof(*a) * b->top);
                       ^
        272.   
        273.       return a;
