]> granicus.if.org Git - sysstat/commit
sa_conv.c: Fix untrusted loop bound
authorSebastien GODARD <sysstat@users.noreply.github.com>
Fri, 22 May 2015 19:26:54 +0000 (21:26 +0200)
committerSebastien GODARD <sysstat@users.noreply.github.com>
Fri, 22 May 2015 19:32:18 +0000 (21:32 +0200)
commit5dca48ac53d25761d87d2893ec38c64840d859bf
tree3e29cc49a8f6220c84010d21645f3a9be28379f5
parent73a0a9bbe27325a9e15ffe11d59b7d529998bc25
sa_conv.c: Fix untrusted loop bound

Variable file_hdr.sa_act_nr was used to allocate memory and as
a loop boundary in upgrade_header_section() function.
Its value is read from an untrusted source, so check its value before
using it.

CID #29718.

Signed-off-by: Sebastien GODARD <sysstat@users.noreply.github.com>
sa_conv.c