/[packages]/updates/5/swftools/current/SOURCES/0001-Fix-an-off-by-one-error-in-png.c.patch
ViewVC logotype

Contents of /updates/5/swftools/current/SOURCES/0001-Fix-an-off-by-one-error-in-png.c.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1106837 - (show annotations) (download)
Sun Jun 4 23:23:03 2017 UTC (6 years, 10 months ago) by luigiwalser
File size: 901 byte(s)
add patches from opensuse to fix CVE-2017-8400 and CVE-2017-8401
1 From 392fb1f3cd9a5b167787c551615c651c3f5326f2 Mon Sep 17 00:00:00 2001
2 From: Matthias Kramm <kramm@quiss.org>
3 Date: Wed, 26 Apr 2017 09:08:44 -0700
4 Subject: [PATCH] Fix an off-by-one error in png.c
5
6 This aims to fix https://github.com/matthiaskramm/swftools/issues/14
7 ---
8 lib/png.c | 2 +-
9 1 file changed, 1 insertion(+), 1 deletion(-)
10
11 diff --git a/lib/png.c b/lib/png.c
12 index 44a4b425..4bf29585 100644
13 --- a/lib/png.c
14 +++ b/lib/png.c
15 @@ -499,7 +499,7 @@ EXPORT int png_load(const char*sname, unsigned*destwidth, unsigned*destheight, u
16 return 0;
17 }
18
19 - unsigned long long imagedatalen_64 = ((unsigned long long)header.width + 1) * header.height * bypp;
20 + unsigned long long imagedatalen_64 = ((unsigned long long)header.width + 1) * header.height * bypp + 1;
21 if(imagedatalen_64 > 0xffffffff)
22 return 0;
23 unsigned long imagedatalen = (unsigned long)imagedatalen_64;
24 --
25 2.12.2
26

  ViewVC Help
Powered by ViewVC 1.1.30