]> git.ipfire.org Git - thirdparty/util-linux.git/commit
libblkid: Fix out of bounds reads on bad GPT header
authorAlden Tondettar <alden.tondettar@gmail.com>
Tue, 24 Jan 2017 06:28:00 +0000 (23:28 -0700)
committerKarel Zak <kzak@redhat.com>
Tue, 21 Feb 2017 12:10:51 +0000 (13:10 +0100)
commita89d4c992f486f4b04c7035cfd937b6372df21f2
tree6789c6f98e67a6cec380a6428f3b07b6cff05900
parent9ebc8a7a882ddfd93bc3262514791a0dcaadba09
libblkid: Fix out of bounds reads on bad GPT header

If a GUID Partition Table claims to have more than 2**25 entries, or if the
size of each entry is not exactly 128 bytes, libblkid can read out of bounds
and segfault. Perform the appropriate checks.

[kzak@redhat.com: - fix typo]

Signed-off-by: Alden Tondettar <alden.tondettar@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
libblkid/src/partitions/gpt.c