New issue
Advanced search Search tips

Issue 680222 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: Mar 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 2
Type: Bug

Blocked on:
issue pdfium:11



Sign in to add a comment

Timeout in pdfium_fuzzer

Project Member Reported by ClusterFuzz, Jan 11 2017

Issue description

Cc: npm@chromium.org
Components: Internals>Plugins>PDF
Labels: Test-Predator-Wrong M-56
Could not find exact culprit CL using findit, regression range and code search. cc-ed developer who worked on this. please take a look and reassign if needed.

Thank you. 

Comment 2 by npm@chromium.org, Jan 12 2017

Cc: dsinclair@chromium.org
Owner: npm@chromium.org
Status: Assigned (was: Untriaged)
It's actually running faster than 25s on my side. This is taking most of the time in FPDFBitmap_FillRect even though the first page shows blank and the other 11000+ pages don't show. Will need to see where to improve performance.

Comment 3 by npm@chromium.org, Jan 12 2017

Blockedon: pdfium:11
Labels: -Pri-1 Pri-3
This pdf says it has a lot of pages, but no contents in the pages. We're just taking a long time to generate all of the blank pages. We can probably improve this once we start using Skia.

Comment 4 by kcc@chromium.org, Mar 15 2017

Cc: kcc@chromium.org infe...@chromium.org
why P3? 
Remember that if we have a timeout during fuzzing it means ClusterFuzz is burning 
much more CPUs and gets much fewer real security bugs detected. 

Comment 5 by npm@chromium.org, Mar 15 2017

Because as I said, we are timing out trying to generate a lot of blank pages, and we want to wait until we start using Skia. Is there a way to temporarily pause clusterfuzz so that it won't run this testcase for while?

Comment 6 by kcc@chromium.org, Mar 15 2017

>> until we start using Skia
ETA? issue pdfium:11 is 2.5 years old. 

>> a way to temporarily pause clusterfuzz
Mmm... Dunno. It still keeps finding bugs, so we should not disable it.
It just does it much less efficiently that it could due to timeouts like this one and OOMs like  issue 672177 



Comment 7 by npm@chromium.org, Mar 15 2017

>> ETA? issue pdfium:11 is 2.5 years old.
You can ask the owner of that bug.

>> Mmm... Dunno. It still keeps finding bugs, so we should not disable it.
Where did I say disable clusterfuzz? I said stop temporarily stop it from running inputs which will cost it lots of resources and which we know are not yet fixed.


Comment 8 by kcc@chromium.org, Mar 15 2017

Labels: -Pri-3 Pri-2
raising to P2. This may actually be closer to P1: with the new pdf corpus that I've just uploaded there are lots more timeouts. ClusterFuzz won't report them until this one is fixed. And so this timeout blocks us from finding more security bugs. 

Comment 9 by kcc@chromium.org, Mar 15 2017

>> I said stop temporarily stop it from running inputs which will cost it lots of resources

We don't know any way to do this.
Fuzzers are too smart -- they will keep re-discovering slow inputs. 

Comment 10 by npm@chromium.org, Mar 15 2017

>> ClusterFuzz won't report them until this one is fixed. And so this timeout blocks us from finding more security bugs.

If it doesn't report other bugs until a different bug is fixed, that sounds more like a clusterfuzz bug.

Comment 11 by kcc@chromium.org, Mar 15 2017

>> If it doesn't report other bugs until a different bug is fixed
This applies only to timeouts and OOMs. 
We don't know of any good way to de-duplicate these kinds of bugs,
so we are forced to report just one timeout and one OOM at a time.
Also, if one timeout bug does not get fixed there is little reason to report another one. :)
Are there samples of other pdfium_fuzzer timeouts? If the issue is always "pdfium_fuzzer spends too much time rendering 10K blank pages" then why don't we limit it to only render the first 10 instead? That's still plenty of room to find lots of bugs.
Labels: -M-56

Comment 14 by npm@chromium.org, Mar 15 2017

Status: Started (was: Assigned)
>> Also, if one timeout bug does not get fixed there is little reason to report another one.

Uhhh we have fixed several timeouts. But I saw something now that I missed before, so I can fix this now.

Comment 15 by kcc@chromium.org, Mar 15 2017

Attaching a fresh batch of non-deduplicated timeout reproducers. 
As I explained in #11 ClusterFuzz will file only one such timeout bug at a time. 
more-pdfium-timeouts.tgz
22.3 KB Download
Project Member

Comment 16 by bugdroid1@chromium.org, Mar 15 2017

The following revision refers to this bug:
  https://pdfium.googlesource.com/pdfium/+/c467d4619ebe0bae9a87b667ca9a06f576138f68

commit c467d4619ebe0bae9a87b667ca9a06f576138f68
Author: Nicolas Pena <npm@chromium.org>
Date: Wed Mar 15 21:35:55 2017

Reset tree traversal when we think we're at the start

If the PDF declares it has a gazillion pages when it does not, we just start
traversing again from the start. This CL fixes that.

BUG= chromium:680222 

Change-Id: Ie9b55abc0aaa372429b3d995a7e1e7ab58fb7965
Reviewed-on: https://pdfium-review.googlesource.com/3060
Commit-Queue: Nicolás Peña <npm@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>

[modify] https://crrev.com/c467d4619ebe0bae9a87b667ca9a06f576138f68/core/fpdfapi/parser/cpdf_document.cpp
[modify] https://crrev.com/c467d4619ebe0bae9a87b667ca9a06f576138f68/core/fpdfapi/parser/cpdf_document_unittest.cpp

Project Member

Comment 17 by bugdroid1@chromium.org, Mar 16 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/704aef7d3e590faa7af12dc6e9a20fbf947906d8

commit 704aef7d3e590faa7af12dc6e9a20fbf947906d8
Author: pdfium-deps-roller <pdfium-deps-roller@chromium.org>
Date: Thu Mar 16 00:41:10 2017

Roll src/third_party/pdfium/ 0029fb25b..c467d4619 (6 commits)

https://pdfium.googlesource.com/pdfium.git/+log/0029fb25b9b6..c467d4619ebe

$ git log 0029fb25b..c467d4619 --date=short --no-merges --format='%ad %ae %s'
2017-03-15 npm Reset tree traversal when we think we're at the start
2017-03-15 tsepez Use map of unique_ptr in cxfa_textparser.
2017-03-15 tsepez remove CFX_ArrayTemplate from fxet_list.
2017-03-15 thestig Refactor some CPDF_ColorSpace code.
2017-03-15 thestig Clean up more CPDF_PSEngine code.
2017-03-15 tsepez Fix botch introduced at 193e6ca, try 2.

Created with:
  roll-dep src/third_party/pdfium
BUG= 680222 

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, see:
http://www.chromium.org/developers/tree-sheriffs/sheriff-details-chromium#TOC-Failures-due-to-DEPS-rolls

TBR=dsinclair@chromium.org

Review-Url: https://codereview.chromium.org/2757443002
Cr-Commit-Position: refs/heads/master@{#457287}

[modify] https://crrev.com/704aef7d3e590faa7af12dc6e9a20fbf947906d8/DEPS

Project Member

Comment 19 by ClusterFuzz, Mar 16 2017

Labels: ClusterFuzz-Verified
Status: Verified (was: Started)
ClusterFuzz testcase 4809791206850560 is verified as fixed, so closing issue.

If this is incorrect, please add ClusterFuzz-Wrong label and re-open the issue.

Sign in to add a comment