[Pgbigm-hackers] Checks for buffer overflow and update copyright information

アーカイブの一覧に戻る

Beena Emerson memis****@gmail*****
2014年 5月 21日 (水) 21:38:16 JST


On Wed, May 21, 2014 at 8:35 AM, Fujii Masao

> So the check of "(Size) slen >= (MaxAllocSize /
> pg_database_encoding_max_length()))"
> is not required?
>
>
No.



> Regarding the check of "(Size) (slen / 2) >= (MaxAllocSize /
> (sizeof(bigm) * 3))",
> could you convince me why this check is required? After this check, the
> memory
> is allocated as follows. The check is to prevent the part
> "sizeof(bigm) * (slen / 2 + 1) * 3"
> from overflowing the maximum size of integer?
>
>     (BIGM *) palloc(VARHDRSZ + sizeof(bigm) * (slen / 2 + 1) *3);
>

Yes.



> Anyway, I just applied the following part.
>
> -    if (len > 0)
> +    if (len > 1)
>
> > The second patch update-copyright-2014.patch, updates the copyright
> > information on various files.
>
> Thanks, applied!
>

 Thank You.


Regards,
Beena Emerson

Have a Great Day!
-------------- next part --------------
HTML$B$NE:IU%U%!%$%k$rJ]4I$7$^$7$?(B...
ダウンロード 



Pgbigm-hackers メーリングリストの案内
アーカイブの一覧に戻る