summaryrefslogtreecommitdiff
path: root/user/catdoc/CVE-2017-11110.patch
diff options
context:
space:
mode:
authorMax Rees <maxcrees@me.com>2019-08-01 03:41:43 -0500
committerMax Rees <maxcrees@me.com>2019-08-01 03:59:46 -0500
commit74a96529112e2a6793d41fc1981285772a388201 (patch)
tree793432e275b8d4f910955d4dc1ce2addfba4b2aa /user/catdoc/CVE-2017-11110.patch
parente26f14b36dfc9afc1041e69a6792cd44b6cf1aae (diff)
downloadpackages-74a96529112e2a6793d41fc1981285772a388201.tar.gz
packages-74a96529112e2a6793d41fc1981285772a388201.tar.bz2
packages-74a96529112e2a6793d41fc1981285772a388201.tar.xz
packages-74a96529112e2a6793d41fc1981285772a388201.zip
user/catdoc: patch for CVE-2017-11110 (#160)
Diffstat (limited to 'user/catdoc/CVE-2017-11110.patch')
-rw-r--r--user/catdoc/CVE-2017-11110.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/user/catdoc/CVE-2017-11110.patch b/user/catdoc/CVE-2017-11110.patch
new file mode 100644
index 000000000..d36d5d63c
--- /dev/null
+++ b/user/catdoc/CVE-2017-11110.patch
@@ -0,0 +1,32 @@
+Description: CVE-2017-11110: Heap buffer overflow in ole_init
+Origin: vendor, https://build.opensuse.org/package/view_file/openSUSE:Maintenance:6985/catdoc.openSUSE_Leap_42.2_Update/CVE-2017-11110.patch?rev=d437c3be72c2e5a3516b75f4e9de6b35
+Bug-Debian: https://bugs.debian.org/867717
+Bug-SuSE: https://bugzilla.novell.com/show_bug.cgi?id=1047877
+Forwarded: no
+Author: Andreas Stieger <astieger@suse.com>
+Reviewed-by: Salvatore Bonaccorso <carnil@debian.org>
+Last-Update: 2017-07-20
+
+--- a/src/ole.c
++++ b/src/ole.c
+@@ -106,6 +106,11 @@ FILE* ole_init(FILE *f, void *buffer, si
+ return NULL;
+ }
+ sectorSize = 1<<getshort(oleBuf,0x1e);
++ /* CVE-2017-11110 */
++ if (sectorSize < 4) {
++ fprintf(stderr, "sectorSize < 4 not supported\n");
++ return NULL;
++ }
+ shortSectorSize=1<<getshort(oleBuf,0x20);
+
+ /* Read BBD into memory */
+@@ -147,7 +152,7 @@ FILE* ole_init(FILE *f, void *buffer, si
+ }
+
+ fseek(newfile, 512+mblock*sectorSize, SEEK_SET);
+- if(fread(tmpBuf+MSAT_ORIG_SIZE+(sectorSize-4)*i,
++ if(fread(tmpBuf+MSAT_ORIG_SIZE+(sectorSize-4)*i, /* >=4 for CVE-2017-11110 */
+ 1, sectorSize, newfile) != sectorSize) {
+ fprintf(stderr, "Error read MSAT!\n");
+ ole_finish();