fix CVE-2019-9278
authorMarcus Meissner <meissner@suse.de>
Sat, 18 Jan 2020 08:29:42 +0000 (09:29 +0100)
committerMarcus Meissner <meissner@suse.de>
Sat, 18 Jan 2020 08:31:35 +0000 (09:31 +0100)
commit75aa73267fdb1e0ebfbc00369e7312bac43d0566
tree79bda04704a1fc9378662b52aed6bb44868bdce6
parentda025b3b85f076f8739ce3046c1de87f8670795c
fix CVE-2019-9278

avoid the use of unsafe integer overflow checking constructs (unsigned integer operations cannot overflow, so "u1 + u2 > u1" can be optimized away)

check for the actual sizes, which should also handle the overflows
document other places google patched, but do not seem relevant due to other restrictions

fixes https://github.com/libexif/libexif/issues/26
libexif/exif-data.c