New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 759012 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: Aug 2017
Cc:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 1
Type: Bug



Sign in to add a comment

Stack-overflow in CPDF_ColorSpace::Load

Project Member Reported by ClusterFuzz, Aug 25 2017

Issue description

Detailed report: https://clusterfuzz.com/testcase?key=5908975131557888

Fuzzer: lszekeres_pdf_small
Job Type: linux_asan_pdfium
Platform Id: linux

Crash Type: Stack-overflow
Crash Address: 0x7ffc9d7c1ea8
Crash State:
  CPDF_ColorSpace::Load
  CPDF_DocPageData::GetColorSpaceImpl
  CPDF_DocPageData::GetColorSpace
  
Sanitizer: address (ASAN)

Reproducer Testcase: https://clusterfuzz.com/download?testcase_id=5908975131557888

Issue filed automatically.

See https://github.com/google/clusterfuzz-tools for more information.
 
Cc: msrchandra@chromium.org sandeepkumars@chromium.org
Labels: Test-Predator-Wrong-CLs M-61
Owner: tsepez@chromium.org
Status: Assigned (was: Untriaged)
Predator and CL could not provide any possible suspects.
Using Code Search for the file, "docpagedata.cpp" assigning to the concern owner who might be related.

Suspecting Commit#
https://pdfium.googlesource.com/pdfium.git/+/4734512572776f8fc705e28fba8a46d981372e99

@tsepez -- Could you please look into the issue, kindly re-assign if this is not related to your changes.
Thank You.

Comment 2 by tsepez@chromium.org, Aug 28 2017

Owner: dsinclair@chromium.org
Over to Dan.
Cc: dsinclair@chromium.org
Owner: hnakashima@chromium.org
hnakashima@ can you take a look?
Status: Started (was: Assigned)
This is a crafty test case. The call cycle:

- CPDF_DocPageData::GetColorSpace(A)
- CPDF_DocPageData::GetColorSpaceImpl(A)
- CPDF_ColorSpace::Load(A)
- CPDF_ICCBasedCS::v_load(A)
- CPDF_ICCBasedCS::FindAlternateProfile(A[1].dict)
- CPDF_ColorSpace::Load(B)
- CPDF_IndexedCS::Load(B)
- CPDF_DocPageData::GetColorSpace(A) - back to beginning


This happens when loading an Indexed color space A that uses an ICCBased color space B as "base", while B uses A as "Alternate" (fallback). One therefore depends on the other creating this 8-shaped stack overflow.

Status: Fixed (was: Started)
Project Member

Comment 7 by ClusterFuzz, Sep 2 2017

ClusterFuzz has detected this issue as fixed in range 499274:499353.

Detailed report: https://clusterfuzz.com/testcase?key=5908975131557888

Fuzzer: lszekeres_pdf_small
Job Type: linux_asan_pdfium
Platform Id: linux

Crash Type: Stack-overflow
Crash Address: 0x7ffc9d7c1ea8
Crash State:
  CPDF_ColorSpace::Load
  CPDF_DocPageData::GetColorSpaceImpl
  CPDF_DocPageData::GetColorSpace
  
Sanitizer: address (ASAN)

Fixed: https://clusterfuzz.com/revisions?job=linux_asan_pdfium&range=499274:499353

Reproducer Testcase: https://clusterfuzz.com/download?testcase_id=5908975131557888

See https://github.com/google/clusterfuzz-tools for more information.

If you suspect that the result above is incorrect, try re-doing that job on the test case report page.
Project Member

Comment 8 by ClusterFuzz, Sep 2 2017

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

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

Sign in to add a comment