To simplify API, WebFrames should be created in the following scenarios: - On HTTP main frames - on iOS10 main frames This WebFrames will execute JavaScript on main frame without encryption.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb commit a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb Author: Mike Dougherty <michaeldo@chromium.org> Date: Tue Sep 11 04:21:48 2018 Add support for WebFrames without an encryption key. Bug: 881816 Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs Change-Id: I695dac7e9aa0b2c6e08d5e661d56afda12d140b8 Reviewed-on: https://chromium-review.googlesource.com/1215042 Commit-Queue: Mike Dougherty <michaeldo@chromium.org> Reviewed-by: Eugene But <eugenebut@chromium.org> Cr-Commit-Position: refs/heads/master@{#590197} [modify] https://crrev.com/a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb/ios/web/web_state/ui/crw_web_controller.mm [modify] https://crrev.com/a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb/ios/web/web_state/web_frame_impl.h [modify] https://crrev.com/a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb/ios/web/web_state/web_frame_impl.mm [modify] https://crrev.com/a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb/ios/web/web_state/web_frame_impl_unittest.mm [modify] https://crrev.com/a3609ba7d85efe0c8ff9b1337d1db72b0a85d6bb/ios/web/web_state/web_frames_manager_impl_unittest.mm
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/dfd65a633b1fd0616491eb7644f4d1be1a55cd96 commit dfd65a633b1fd0616491eb7644f4d1be1a55cd96 Author: Mike Dougherty <michaeldo@chromium.org> Date: Fri Sep 14 18:54:12 2018 Always create a WebFrame for all frames even without an encryption key. JavaScript can only be executed on a WebFrame which represents a main frame or an iframe with an encryption key as signified by |CanCallJavaScriptFunction|. Bug: 881816 Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs Change-Id: I3831f353b664f8ec8ce80fb47b55660ec6868daa Reviewed-on: https://chromium-review.googlesource.com/1214803 Reviewed-by: Moe Ahmadi <mahmadi@chromium.org> Reviewed-by: Eugene But <eugenebut@chromium.org> Commit-Queue: Mike Dougherty <michaeldo@chromium.org> Cr-Commit-Position: refs/heads/master@{#591417} [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/components/autofill/ios/form_util/form_activity_tab_helper_unittest.mm [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/public/test/fakes/fake_web_frame.cc [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/public/test/fakes/fake_web_frame.h [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/public/web_state/web_frame.h [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/ui/crw_web_controller.mm [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/web_frame_impl.h [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/web_frame_impl.mm [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/web_frame_impl_inttest.mm [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/web_frame_impl_unittest.mm [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/web_frame_web_state_observer_inttest.mm [modify] https://crrev.com/dfd65a633b1fd0616491eb7644f4d1be1a55cd96/ios/web/web_state/web_frames_manager_inttest.mm
Comment 1 by michaeldo@chromium.org
, Sep 8Cc: eugene...@chromium.org