crypto/asn1/t_pkey.c:297: error: BUFFER_OVERRUN_L3
  Offset: [1, +oo] Size: [0, +oo] by call to `print`.
Showing all 11 steps of the trace


crypto/asn1/t_pkey.c:286:4: Call
284.   	int reason=ERR_R_BUF_LIB,i,ret=0;
285.   
286.   	i=BN_num_bytes(x->p);
          ^
287.   	m=(unsigned char *)Malloc((unsigned int)i+10);
288.   	if (m == NULL)

crypto/bn/bn_lib.c:245:19: Assignment
  243.   	bn_check_top(a);
  244.   
  245.   	if (a->top == 0) return(0);
                           ^
  246.   	l=a->d[a->top-1];
  247.   	i=(a->top-1)*BN_BITS2;

crypto/asn1/t_pkey.c:286:2: Assignment
284.   	int reason=ERR_R_BUF_LIB,i,ret=0;
285.   
286.   	i=BN_num_bytes(x->p);
        ^
287.   	m=(unsigned char *)Malloc((unsigned int)i+10);
288.   	if (m == NULL)

crypto/asn1/t_pkey.c:287:21: Array declaration
285.   
286.   	i=BN_num_bytes(x->p);
287.   	m=(unsigned char *)Malloc((unsigned int)i+10);
                           ^
288.   	if (m == NULL)
289.   		{

crypto/asn1/t_pkey.c:287:2: Assignment
285.   
286.   	i=BN_num_bytes(x->p);
287.   	m=(unsigned char *)Malloc((unsigned int)i+10);
        ^
288.   	if (m == NULL)
289.   		{

crypto/asn1/t_pkey.c:297:7: Call
295.   		BN_num_bits(x->p)) <= 0)
296.   		goto err;
297.   	if (!print(bp,"prime:",x->p,m,4)) goto err;
             ^
298.   	if (!print(bp,"generator:",x->g,m,4)) goto err;
299.   	if (x->length != 0)

crypto/asn1/t_pkey.c:212:1: Parameter `*buf`
  210.   #endif /* !NO_DSA */
  211.   
  212. > static int print(BIO *bp, const char *number, BIGNUM *num, unsigned char *buf,
  213.   	     int off)
  214.   	{

crypto/asn1/t_pkey.c:240:5: Call
  238.   			(neg[0] == '-')?" (Negative)":"") <= 0)
  239.   			return(0);
  240.   		n=BN_bn2bin(num,&buf[1]);
             ^
  241.   	
  242.   		if (buf[1] & 0x80)

crypto/bn/bn_lib.c:632:1: <Length trace>
630.   
631.   /* ignore negative */
632. > int BN_bn2bin(const BIGNUM *a, unsigned char *to)
633.   	{
634.   	int n,i;

crypto/bn/bn_lib.c:632:1: Parameter `*to`
    630.   
    631.   /* ignore negative */
    632. > int BN_bn2bin(const BIGNUM *a, unsigned char *to)
    633.   	{
    634.   	int n,i;

crypto/bn/bn_lib.c:641:3: Array access: Offset: [1, +oo] Size: [0, +oo] by call to `print` 
    639.   		{
    640.   		l=a->d[i/BN_BYTES];
    641.   		*(to++)=(unsigned char)(l>>(8*(i%BN_BYTES)))&0xff;
             ^
    642.   		}
    643.   	return(n);
