Bug 85245

Summary: [pdftops] (Eternal?) Loop writes huge file
Product: poppler Reporter: MH <ravdune+bugzilla>
Component: utilsAssignee: poppler-bugs <poppler-bugs>
Status: RESOLVED INVALID QA Contact:
Severity: minor    
Priority: medium    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: pdftops-eternalloop.pdf
86-unfuzzed.pdf

Description MH 2014-10-20 15:13:57 UTC
Created attachment 108121 [details]
pdftops-eternalloop.pdf

OS: Fedora 20 (running in virtualbox)
Dependencies installed with: yum-builddep poppler
Version: GIT Master
Command line for loop demonstration: master/utils/pdftops <attached.pdf> /dev/null
Command line for filling disk: master/utils/pdftops <attached.pdf> out.ps

Again missing EOF check? :)

#############################################################################
GDB output:

Starting program: /home/foobar/poppler/utils/.libs/lt-pdftops eternalloop-86-pdftopsfuzz-10.pdf /dev/null
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
Corrupt JPEG data: premature end of data segment

<keeps running>
Comment 1 MH 2014-10-21 13:46:55 UTC
Created attachment 108183 [details]
86-unfuzzed.pdf

Attached unfuzzed file as per request.
Comment 2 Albert Astals Cid 2015-01-08 16:54:53 UTC
$ time ./utils/pdftops /home/tsdgeos/okularfiles/pdf/bug-poppler85245.pdf a
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment
Corrupt JPEG data: premature end of data segment

real    2m1.773s
user    1m56.581s
sys     0m2.676s

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.