Restrict filtered painting across cross-origin boundaries with transforms
authordino@apple.com <dino@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Jun 2017 01:01:08 +0000 (01:01 +0000)
committerdino@apple.com <dino@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Jun 2017 01:01:08 +0000 (01:01 +0000)
commit04115f4f1b2c9d3f13d468f6b2272d0da95c862a
treecc0889e0379a60cc6cc6fdac4117c5275f20f009
parent3d8fe16ee84e77d0cd7f0f4876f92c4582d712e2
Restrict filtered painting across cross-origin boundaries with transforms
https://bugs.webkit.org/show_bug.cgi?id=173388
<rdar://problem/27362159>

Reviewed by Simon Fraser.

Source/WebCore:

Make sure all cases of LayerPaintingInfo maintain the security
flag. In this case there was only one new place, and since
everything is scalar, there was no need for a real copy constructor.

Test: http/tests/css/filters-on-iframes-transform.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::paintLayerByApplyingTransform): Make sure the cross
origin flag is used in the call to paint the layer children.
* rendering/RenderLayer.h: Fix some typos.

LayoutTests:

New test that checks painting across a origin boundary when in
a transformed container. Also clean up the existing test
to make it smfr-compliant (green is good, red is bad).

* http/tests/css/filters-on-iframes-expected.html:
* http/tests/css/filters-on-iframes-transform-expected.html: Added.
* http/tests/css/filters-on-iframes-transform.html: Added.
* http/tests/css/filters-on-iframes.html:
* http/tests/css/resources/references-external-green.html: Copied from LayoutTests/http/tests/css/resources/references-external.html.
* http/tests/css/resources/references-external-red.html: Renamed from LayoutTests/http/tests/css/resources/references-external.html.
* http/tests/css/resources/solid-green.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@218300 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/http/tests/css/filters-on-iframes-expected.html
LayoutTests/http/tests/css/filters-on-iframes-transform-expected.html [new file with mode: 0644]
LayoutTests/http/tests/css/filters-on-iframes-transform.html [new file with mode: 0644]
LayoutTests/http/tests/css/filters-on-iframes.html
LayoutTests/http/tests/css/resources/references-external-green.html [new file with mode: 0644]
LayoutTests/http/tests/css/resources/references-external-red.html [moved from LayoutTests/http/tests/css/resources/references-external.html with 100% similarity]
LayoutTests/http/tests/css/resources/solid-green.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderLayer.cpp
Source/WebCore/rendering/RenderLayer.h