Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
Control: tags -1 + pending On Mon, 2013-07-08 at 13:05 +0800, Paul Wise wrote: > On Sun, 2013-07-07 at 14:13 +0100, Adam D. Barratt wrote: > > > Please go ahead; thanks. > > Thanks, uploaded to ssh.upload.d.o, will be on ftp.d.o soon. Flagged for acceptance. Regards, Adam -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
On Sun, 2013-07-07 at 14:13 +0100, Adam D. Barratt wrote: > Please go ahead; thanks. Thanks, uploaded to ssh.upload.d.o, will be on ftp.d.o soon. -- bye, pabs http://wiki.debian.org/PaulWise signature.asc Description: This is a digitally signed message part
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
Control: tags -1 + confirmed On Fri, 2013-07-05 at 13:34 +0800, Paul Wise wrote: > On Thu, 2013-07-04 at 13:51 +0200, Jonas Smedegaard wrote: > > > I will now prepare a 9.05~dfsg-8 release for Sid with this bugfix > > applied. > > Updated the spu to include both patches, see attached. Please go ahead; thanks. Regards, Adam -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
On Thu, 2013-07-04 at 13:51 +0200, Jonas Smedegaard wrote: > I will now prepare a 9.05~dfsg-8 release for Sid with this bugfix > applied. Updated the spu to include both patches, see attached. -- bye, pabs http://wiki.debian.org/PaulWise diff -Nru ghostscript-9.05~dfsg/debian/changelog ghostscript-9.05~dfsg/debian/changelog --- ghostscript-9.05~dfsg/debian/changelog 2012-11-26 03:23:28.0 +1030 +++ ghostscript-9.05~dfsg/debian/changelog 2013-07-05 15:02:48.0 +0930 @@ -1,3 +1,10 @@ +ghostscript (9.05~dfsg-6.3+deb7u1) wheezy; urgency=low + + * Add patches to fix endless loops related to unbalanced q/Q +operators. (Closes: #714247) + + -- Paul Wise Mon, 01 Jul 2013 23:28:32 +0930 + ghostscript (9.05~dfsg-6.3) unstable; urgency=low * Non-maintainer upload. diff -Nru ghostscript-9.05~dfsg/debian/patches/020120909~3a56f4e.patch ghostscript-9.05~dfsg/debian/patches/020120909~3a56f4e.patch --- ghostscript-9.05~dfsg/debian/patches/020120909~3a56f4e.patch 1970-01-01 09:30:00.0 +0930 +++ ghostscript-9.05~dfsg/debian/patches/020120909~3a56f4e.patch 2013-07-05 14:57:27.0 +0930 @@ -0,0 +1,23 @@ +Description: Correctly restore PS stack when PDF stream run aborts. + Fix "File has unbalanced q/Q operators (too many Q's)" endless loop. +Origin: upstream, http://git.ghostscript.com/?p=ghostpdl.git;a=commit;h=3a56f4e +Author: Alex Cherepanov +Forwarded: yes +Bug: http://bugs.ghostscript.com/show_bug.cgi?id=693045 +Bug-Debian: http://bugs.debian.org/714247 +Last-Update: 2013-07-04 + +--- a/Resource/Init/pdf_draw.ps b/Resource/Init/pdf_draw.ps +@@ -1746,9 +1746,8 @@ + ] cvx /PaintProc exch put + % Adjust pdfemptycount since we have an extra dictionary on the stack + pdfemptycount countdictstack 3 -1 roll +- /pdfemptycount count 2 sub store +- q execform % gsave / grestore around the Form +- ++ /pdfemptycount count 3 sub store ++ /q cvx /execform cvx 5 -2 roll 4 .execn + % Restore pdfemptycount + 0 + { countdictstack diff -Nru ghostscript-9.05~dfsg/debian/patches/020130619~daceba6.patch ghostscript-9.05~dfsg/debian/patches/020130619~daceba6.patch --- ghostscript-9.05~dfsg/debian/patches/020130619~daceba6.patch 1970-01-01 09:30:00.0 +0930 +++ ghostscript-9.05~dfsg/debian/patches/020130619~daceba6.patch 2013-07-05 14:57:32.0 +0930 @@ -0,0 +1,59 @@ +Description: PDF interpreter - ignore invalid /DecodeParams for streams + Fix "File has unbalanced q/Q operators (too many Q's)" endless loop. + . + The PDF file is invalid, it has a /Filters array with 2 elements, and a + /DecodeParams array with 1 element. The DecodeParams array must have + either the same number of elements as the Filters, or not be present + (default). + . + We now test the length of each array and ignore the DecodeParams if the + lengths are not the same (as we have no way to know which Params relate + to which Filter) +Origin: upstream, http://git.ghostscript.com/?p=ghostpdl.git;a=commit;h=daceba6 +Author: Ken Sharp +Forwarded: yes +Bug: http://bugs.ghostscript.com/show_bug.cgi?id=694353 +Bug-Debian: http://bugs.debian.org/714247 +Last-Update: 2013-07-04 + +--- a/Resource/Init/pdf_base.ps b/Resource/Init/pdf_base.ps +@@ -969,16 +969,30 @@ + currentdict /pdf_rules_dict undef + + /applyfilters { %applyfilters +- 2 index //null eq { ++ 2 index //null eq ++ { + { filtername add_A85_param filter } +- } { +-{ % Stack: parms source filtername +- 2 index 0 oget dup type /dicttype ne { pop } { +-exch filtername dup /JBIG2Decode eq { exch jbig2cachectx exch } if +- } ifelse add_A85_param filter +- exch dup length 1 sub 1 exch getinterval exch ++ } ++ { ++dup length 3 index length ne %% compare lengths of DecodeParmas and Filter arrays ++{%% if they aren't the same, ignore the decode params ++ ( Warning: ignoring stream /DecodeParams array as its length is different to the Filters array.\n) pdfformaterror ++ 3 -1 roll pop //null 3 1 roll ++ { filtername add_A85_param filter } + } +- } ifelse forall exch pop ++{ ++ { % Stack: parms source filtername ++2 index 0 oget dup type /dicttype ne ++{ pop } ++{ ++ exch filtername dup /JBIG2Decode eq { exch jbig2cachectx exch } if ++} ifelse ++add_A85_param filter ++exch dup length 1 sub 1 exch getinterval exch ++ } ++} ifelse ++ } ifelse ++ forall exch pop + } bind def + + % JBIG2 streams have an optional 'globals' stream obj for diff -Nru ghostscript-9.05~dfsg/debian/patches/series ghostscript-9.05~dfsg/debian/patches/series --- ghostscript-9.05~dfsg/debian/patches/series 2012-11-26 02:18:34.0 +1030 +++ ghostscript-9.05~dfsg/debian/patches/series 2013-07-05 14:57:32.0 +0930 @@ -8,3 +8,5 @@ 2002_gs_man_fix_debian.patch 2003_support_multiarch.patch CVE-2012-4405.patch +020130619~daceba6.patch +020120909~3a56f4e.patch
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
Quoting Jonas Smedegaard (2013-07-04 13:51:52) > Quoting Paul Wise (2013-07-01 16:17:28) > > On Mon, 2013-07-01 at 15:09 +0100, Adam D. Barratt wrote: > > > > > ghostscript currently has the same version in wheezy, jessie and > > > sid; is there a plan for getting sid fixed? > > > > I expect the maintainers intend to upload the new upstream 9.07 > > soon, it contains the patch. CCing the maintainers to find out their > > plans. > > The 9.07~dfsg-1 release is blocked by bug#701993. ...and for Sid/Jessy also blocked by bug#659226. > I will now prepare a 9.05~dfsg-8 release for Sid with this bugfix > applied. Compiling now. Please consider adopting for the backport this other patch for a similar endless loop, included with the 9.05~dfsg-8 release: http://bugs.ghostscript.com/show_bug.cgi?id=694353 - Jonas -- * Jonas Smedegaard - idealist & Internet-arkitekt * Tlf.: +45 40843136 Website: http://dr.jones.dk/ [x] quote me freely [ ] ask before reusing [ ] keep private signature.asc Description: signature
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
Quoting Paul Wise (2013-07-01 16:17:28) > On Mon, 2013-07-01 at 15:09 +0100, Adam D. Barratt wrote: > > > ghostscript currently has the same version in wheezy, jessie and sid; > > is there a plan for getting sid fixed? > > I expect the maintainers intend to upload the new upstream 9.07 soon, > it contains the patch. CCing the maintainers to find out their plans. The 9.07~dfsg-1 release is blocked by bug#701993. I will now prepare a 9.05~dfsg-8 release for Sid with this bugfix applied. - Jonas -- * Jonas Smedegaard - idealist & Internet-arkitekt * Tlf.: +45 40843136 Website: http://dr.jones.dk/ [x] quote me freely [ ] ask before reusing [ ] keep private signature.asc Description: signature
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
On Mon, 2013-07-01 at 15:09 +0100, Adam D. Barratt wrote: > ghostscript currently has the same version in wheezy, jessie and sid; > is there a plan for getting sid fixed? I expect the maintainers intend to upload the new upstream 9.07 soon, it contains the patch. CCing the maintainers to find out their plans. -- bye, pabs http://wiki.debian.org/PaulWise signature.asc Description: This is a digitally signed message part
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
Control: tags -1 + wheezy moreinfo On 2013-07-01 15:02, Paul Wise wrote: ghostscript from wheezy shipped with a regression (#714247) that causes an infinite loop with some files. I would like to get this fixed in the next point release. I have attached a debdiff that I have tested and fixes the issue. Jonas Smedegaard has acked the update on IRC. ghostscript currently has the same version in wheezy, jessie and sid; is there a plan for getting sid fixed? Regards, ADam -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#714639: pu: package ghostscript/9.05~dfsg-6.3
Package: release.debian.org Severity: normal User: release.debian@packages.debian.org Usertags: pu X-Debbugs-CC: 714...@bugs.debian.org ghostscript from wheezy shipped with a regression (#714247) that causes an infinite loop with some files. I would like to get this fixed in the next point release. I have attached a debdiff that I have tested and fixes the issue. Jonas Smedegaard has acked the update on IRC. -- bye, pabs http://wiki.debian.org/PaulWise diff -Nru ghostscript-9.05~dfsg/debian/changelog ghostscript-9.05~dfsg/debian/changelog --- ghostscript-9.05~dfsg/debian/changelog 2012-11-26 03:23:28.0 +1030 +++ ghostscript-9.05~dfsg/debian/changelog 2013-07-01 23:29:00.0 +0930 @@ -1,3 +1,9 @@ +ghostscript (9.05~dfsg-6.3+deb7u1) wheezy; urgency=low + + * Backport infinite loop patch (Closes: #714247) + + -- Paul Wise Mon, 01 Jul 2013 23:28:32 +0930 + ghostscript (9.05~dfsg-6.3) unstable; urgency=low * Non-maintainer upload. diff -Nru ghostscript-9.05~dfsg/debian/patches/fix-infinite-loop.patch ghostscript-9.05~dfsg/debian/patches/fix-infinite-loop.patch --- ghostscript-9.05~dfsg/debian/patches/fix-infinite-loop.patch 1970-01-01 09:30:00.0 +0930 +++ ghostscript-9.05~dfsg/debian/patches/fix-infinite-loop.patch 2013-07-01 23:26:54.0 +0930 @@ -0,0 +1,20 @@ +From: Alex Cherepanov +Date: Sun, 9 Sep 2012 22:43:52 + (-0400) +Subject: Bug 693045: Correctly restore PS stack when PDF stream run aborts. +Origin: upstream, commit:3a56f4eb5a9f15795725374b297edab0fb8ebc5d +Applied-Upstream: 9.07rc1 +Bug: http://bugs.ghostscript.com/show_bug.cgi?id=693045 +--- a/Resource/Init/pdf_draw.ps b/Resource/Init/pdf_draw.ps +@@ -1773,9 +1773,8 @@ currentdict /last-ditch-bpc-csp undef + ] cvx /PaintProc exch put + % Adjust pdfemptycount since we have an extra dictionary on the stack + pdfemptycount countdictstack 3 -1 roll +- /pdfemptycount count 2 sub store +- q execform % gsave / grestore around the Form +- ++ /pdfemptycount count 3 sub store ++ /q cvx /execform cvx 5 -2 roll 4 .execn + % Restore pdfemptycount + 0 + { countdictstack diff -Nru ghostscript-9.05~dfsg/debian/patches/series ghostscript-9.05~dfsg/debian/patches/series --- ghostscript-9.05~dfsg/debian/patches/series 2012-11-26 02:18:34.0 +1030 +++ ghostscript-9.05~dfsg/debian/patches/series 2013-07-01 23:26:54.0 +0930 @@ -8,3 +8,4 @@ 2002_gs_man_fix_debian.patch 2003_support_multiarch.patch CVE-2012-4405.patch +fix-infinite-loop.patch signature.asc Description: This is a digitally signed message part