Changeset 205301 in webkit
- Timestamp:
- Sep 1, 2016 11:34:12 AM (8 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r205298 r205301 1 2016-09-01 Chris Dumez <cdumez@apple.com> 2 3 Unreviewed, rolling out r205297. 4 5 Caused some JSC test failures 6 7 Reverted changeset: 8 9 "Align cross-origin proto getter / setter behavior with the 10 specification" 11 https://bugs.webkit.org/show_bug.cgi?id=161455 12 http://trac.webkit.org/changeset/205297 13 1 14 2016-09-01 Jiewen Tan <jiewen_tan@apple.com> 2 15 -
trunk/LayoutTests/http/tests/security/cross-frame-access-object-getPrototypeOf-expected.txt
r205297 r205301 1 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match.2 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match.3 1 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match. 4 2 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match. … … 7 5 PASS: Object.getPrototypeOf(targetWindow) should be 'null' and is. 8 6 PASS: Object.getPrototypeOf(targetWindow.location) should be 'null' and is. 9 PASS: protoGetter.call(targetWindow) should be 'null' and is.10 PASS: protoGetter.call(targetWindow.location) should be 'null' and is.11 7 PASS targetWindow.history threw exception SecurityError (DOM Exception 18): Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match.. 12 8 PASS: successfullyParsed should be 'true' and is. -
trunk/LayoutTests/http/tests/security/cross-frame-access-object-getPrototypeOf.html
r205297 r205301 19 19 shouldBeNull("Object.getPrototypeOf(targetWindow)"); 20 20 shouldBeNull("Object.getPrototypeOf(targetWindow.location)"); 21 protoGetter = Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').get;22 shouldBeNull("protoGetter.call(targetWindow)");23 shouldBeNull("protoGetter.call(targetWindow.location)");24 25 21 shouldThrowErrorName("targetWindow.history", "SecurityError"); 26 22 -
trunk/LayoutTests/http/tests/security/cross-frame-access-object-setPrototypeOf-expected.txt
r205297 r205301 1 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match.2 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match.3 1 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match. 4 2 CONSOLE MESSAGE: line 1: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a frame with origin "http://localhost:8000". Protocols, domains, and ports must match. … … 14 12 PASS Object.setPrototypeOf(targetWindow.location, Array.prototype) threw exception TypeError: Permission denied. 15 13 PASS: targetWindow.location instanceof Array should be 'false' and is. 16 PASS: targetWindow instanceof Array should be 'false' and is.17 PASS protoSetter.call(targetWindow, Array.prototype) threw exception TypeError: Permission denied.18 PASS: targetWindow instanceof Array should be 'false' and is.19 PASS: targetWindow.location instanceof Array should be 'false' and is.20 PASS protoSetter.call(targetWindow.location, Array.prototype) threw exception TypeError: Permission denied.21 PASS: targetWindow.location instanceof Array should be 'false' and is.22 14 PASS: successfullyParsed should be 'true' and is. 23 15 -
trunk/LayoutTests/http/tests/security/cross-frame-access-object-setPrototypeOf.html
r205297 r205301 25 25 shouldBeFalse("targetWindow.location instanceof Array"); 26 26 27 protoSetter = Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set;28 shouldBeFalse("targetWindow instanceof Array");29 shouldThrowErrorName("protoSetter.call(targetWindow, Array.prototype)", "TypeError");30 shouldBeFalse("targetWindow instanceof Array");31 32 shouldBeFalse("targetWindow.location instanceof Array");33 shouldThrowErrorName("protoSetter.call(targetWindow.location, Array.prototype)", "TypeError");34 shouldBeFalse("targetWindow.location instanceof Array");35 36 27 finishJSTest(); 37 28 } -
trunk/Source/JavaScriptCore/ChangeLog
r205297 r205301 1 2016-09-01 Chris Dumez <cdumez@apple.com> 2 3 Unreviewed, rolling out r205297. 4 5 Caused some JSC test failures 6 7 Reverted changeset: 8 9 "Align cross-origin proto getter / setter behavior with the 10 specification" 11 https://bugs.webkit.org/show_bug.cgi?id=161455 12 http://trac.webkit.org/changeset/205297 13 1 14 2016-09-01 Chris Dumez <cdumez@apple.com> 2 15 -
trunk/Source/JavaScriptCore/runtime/JSGlobalObjectFunctions.cpp
r205297 r205301 888 888 if (m_thisObject->allowsAccessFrom(visitor->callFrame())) 889 889 m_result = JSValue::encode(m_thisObject->getPrototype(m_exec->vm(), m_exec)); 890 else891 m_result = JSValue::encode(jsNull());892 890 893 891 return StackVisitor::Done; … … 977 975 return JSValue::encode(jsUndefined()); 978 976 979 if (!checkProtoSetterAccessAllowed(exec, thisObject)) { 980 throwTypeError(exec, scope, ASCIILiteral("Permission denied")); 977 if (!checkProtoSetterAccessAllowed(exec, thisObject)) 981 978 return JSValue::encode(jsUndefined()); 982 }983 979 984 980 // Setting __proto__ to a non-object, non-null value is silently ignored to match Mozilla.
Note: See TracChangeset
for help on using the changeset viewer.