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

Issue 844872 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Last visit > 30 days ago
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 1
Type: Bug-Security



Sign in to add a comment

Heap-buffer-overflow in transform_scanline_bgrA

Project Member Reported by ClusterFuzz, May 19 2018

Issue description

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

Fuzzer: inferno_twister
Job Type: mac_asan_content_shell
Platform Id: mac

Crash Type: Heap-buffer-overflow WRITE 4
Crash Address: 0x000426914970
Crash State:
  transform_scanline_bgrA
  SkWebpEncoder::Encode
  blink::CanvasAsyncBlobCreator::EncodeImage
  
Sanitizer: address (ASAN)

Recommended Security Severity: High

Regressed: https://clusterfuzz.com/revisions?job=mac_asan_content_shell&range=521688:521717

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

Issue filed automatically.

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

Comment 1 by ClusterFuzz, May 19 2018

Components: Blink>Canvas Internals>Skia
Labels: Test-Predator-Auto-Components
Automatically applying components based on crash stacktrace and information from OWNERS files.

If this is incorrect, please apply the Test-Predator-Wrong-Components label.
Project Member

Comment 2 by ClusterFuzz, May 19 2018

Labels: Test-Predator-Auto-Owner
Owner: zakerinasab@chromium.org
Status: Assigned (was: Untriaged)
Automatically assigning owner based on suspected regression changelist https://chromium.googlesource.com/chromium/src/+/6e0ab6ae54cc837abd96024dae5595a8d299e7b8 (Refactor CanvasAsyncBlobCreator to use StaticBitmapImage).

If this is incorrect, please let us know why and apply the Test-Predator-Wrong-CLs label. If you aren't the correct owner for this issue, please unassign yourself as soon as possible so it can be re-triaged.
Project Member

Comment 3 by sheriffbot@chromium.org, May 20 2018

Labels: M-66
Project Member

Comment 4 by sheriffbot@chromium.org, May 20 2018

Labels: Pri-1
Cc: scroggo@chromium.org fs...@chromium.org
This is not locally reproducible. I tried to reproduce using both the cluster fuzz build and a local build on Mac 10.13. We had a similar issue recently which was also not reproducible ( crbug.com/808875 ).
Adding scroggo@ to take a look.
I initiated a Redo task on ClusterFuzz to try to minimize the test case one more time and also run the test case again to see if the test is flaky on the fuzzer.
Cc: junov@chromium.org
Project Member

Comment 8 by bugdroid1@chromium.org, May 24 2018

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

commit 1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0
Author: Reza.Zakerinasab <zakerinasab@chromium.org>
Date: Thu May 24 20:11:32 2018

Fixing heap buffer overflow in CanvasAsyncBlobCreator

When the size of the to-be-encoded-image is larger than the maximum
size supported by the encoder, we need to crop the image beforehand.
Otherwise, we might end up in heap buffer overflow.

Bug:  844872 
Change-Id: Ibea765a8b094a845a2a47f8d3e539fc53176ffb1
Reviewed-on: https://chromium-review.googlesource.com/1070326
Reviewed-by: Justin Novosad <junov@chromium.org>
Commit-Queue: Mohammad Reza Zakerinasab <zakerinasab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#561597}
[add] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/WebKit/LayoutTests/fast/canvas/canvas-toBlob-oversized.html
[modify] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/WebKit/LayoutTests/virtual/threaded/fast/idleToBlob/OffscreenCanvas-convertToBlob-failures.html
[add] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/WebKit/LayoutTests/virtual/threaded/fast/idleToBlob/OffscreenCanvas-convertToBlob-oversized.html
[modify] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/blink/renderer/core/html/canvas/canvas_async_blob_creator.cc
[modify] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/blink/renderer/core/html/canvas/canvas_async_blob_creator.h
[modify] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/blink/renderer/core/html/canvas/canvas_async_blob_creator_test.cc
[modify] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/blink/renderer/platform/image-encoders/image_encoder.cc
[modify] https://crrev.com/1591ea17958c3eefbbd34c6ff3e9c6cfb0b901a0/third_party/blink/renderer/platform/image-encoders/image_encoder.h

Project Member

Comment 9 by ClusterFuzz, May 25 2018

ClusterFuzz has detected this issue as fixed in range 561580:561613.

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

Fuzzer: inferno_twister
Job Type: mac_asan_content_shell
Platform Id: mac

Crash Type: Heap-buffer-overflow WRITE 4
Crash Address: 0x000426914970
Crash State:
  transform_scanline_bgrA
  SkWebpEncoder::Encode
  blink::CanvasAsyncBlobCreator::EncodeImage
  
Sanitizer: address (ASAN)

Recommended Security Severity: High

Regressed: https://clusterfuzz.com/revisions?job=mac_asan_content_shell&range=521688:521717
Fixed: https://clusterfuzz.com/revisions?job=mac_asan_content_shell&range=561580:561613

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

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 10 by ClusterFuzz, May 25 2018

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

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

Comment 11 by sheriffbot@chromium.org, May 25 2018

Labels: -Restrict-View-SecurityTeam Restrict-View-SecurityNotify
Labels: -M-66 M-68
Project Member

Comment 13 by sheriffbot@chromium.org, Jun 8 2018

Labels: Merge-Request-68
Project Member

Comment 14 by sheriffbot@chromium.org, Jun 8 2018

Labels: -Merge-Request-68 Hotlist-Merge-Review Merge-Review-68
This bug requires manual review: M68 has already been promoted to the beta branch, so this requires manual review
Please contact the milestone owner if you have questions.
Owners: cmasso@(Android), kariahda@(iOS), bhthompson@(ChromeOS), abdulsyed@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Merge-Review-68 Merge-Approved-68
Approved. branch:3440
This is already merged in 3440. The commit position for this change is refs/heads/master@{#561597}, while the commit position for branch 3440 is refs/heads/master@{561733}.
Project Member

Comment 17 by sheriffbot@chromium.org, Jun 12 2018

Cc: abdulsyed@google.com
This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible!

If all merges have been completed, please remove any remaining Merge-Approved labels from this issue.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 18 by sheriffbot@chromium.org, Jun 18 2018

This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible!

If all merges have been completed, please remove any remaining Merge-Approved labels from this issue.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Cc: abdulsyed@chromium.org
Pls merge you change to M68 branch 3440 ASAP so we can pick it up for this week Beta release. Merge has to happen latest by 1:00 PM PT tomorrow, Tuesday (06/19), so we can pick it up for Wednesday Beta release.




Comment 20 by fs...@chromium.org, Jun 19 2018

Labels: -Hotlist-Merge-Review -M-68 -Merge-Approved-68
As per #16, this is was committed before 3440 was branched. Removing the merge tags. 
Project Member

Comment 21 by sheriffbot@chromium.org, Aug 31

Labels: -Restrict-View-SecurityNotify allpublic
This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Sign in to add a comment