Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: LayoutTests/platform/chromium/http/tests/security/aboutBlank/xss-DENIED-set-opener-expected.txt

Issue 9895001: Merge 111098 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1025/
Patch Set: Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 CONSOLE MESSAGE: Unsafe JavaScript attempt to access frame with URL http://local host:8000/security/resources/innocent-victim.html from frame with URL http://127 .0.0.1:8000/security/aboutBlank/xss-DENIED-set-opener.html. Domains, protocols a nd ports must match. 1 CONSOLE MESSAGE: Unsafe JavaScript attempt to access frame with URL http://local host:8000/security/resources/innocent-victim.html from frame with URL http://127 .0.0.1:8000/security/aboutBlank/xss-DENIED-set-opener.html. Domains, protocols a nd ports must match.
2 2
3 CONSOLE MESSAGE: Unsafe JavaScript attempt to access frame with URL http://local host:8000/security/resources/innocent-victim.html from frame with URL http://127 .0.0.1:8000/security/aboutBlank/xss-DENIED-set-opener.html. Domains, protocols a nd ports must match.
4
3 CONSOLE MESSAGE: line 1: Uncaught TypeError: Cannot read property 'body' of unde fined 5 CONSOLE MESSAGE: line 1: Uncaught TypeError: Cannot read property 'body' of unde fined
4 This page opens a window to "", injects malicious code, and then uses window.ope n.call to set its opener to the victim. The opened window then tries to scripts its opener. 6 This page opens a window to "", injects malicious code, and then uses window.ope n.call to set its opener to the victim. The opened window then tries to scripts its opener.
5 Code injected into window: 7 Code injected into window:
6 <script>function write(target, message) { target.document.body.innerHTML = messa ge; } 8 <script>function write(target, message) { target.document.body.innerHTML = messa ge; }
7 setTimeout(function() {write(window.opener.top.frames[0], 'FAIL: XSS was allowed .');}, 100); 9 setTimeout(function() {write(window.opener.top.frames[0], 'FAIL: XSS was allowed .');}, 100);
8 setTimeout(function() {write(window.opener.top.frames[1], 'SUCCESS: Window remai ned in original SecurityOrigin.');}, 200); 10 setTimeout(function() {write(window.opener.top.frames[1], 'SUCCESS: Window remai ned in original SecurityOrigin.');}, 200);
9 setTimeout(function() { if (window.layoutTestController) layoutTestController.gl obalFlag = true; }, 300);</script> 11 setTimeout(function() { if (window.layoutTestController) layoutTestController.gl obalFlag = true; }, 300);</script>
10 12
11 13
12 -------- 14 --------
13 Frame: '<!--framePath //<!--frame0-->-->' 15 Frame: '<!--framePath //<!--frame0-->-->'
14 -------- 16 --------
15 This page doesn't do anything special. 17 This page doesn't do anything special.
16 18
17 -------- 19 --------
18 Frame: '<!--framePath //<!--frame1-->-->' 20 Frame: '<!--framePath //<!--frame1-->-->'
19 -------- 21 --------
20 SUCCESS: Window remained in original SecurityOrigin. 22 SUCCESS: Window remained in original SecurityOrigin.
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698