blob: 7e03c432e81b15829987f74eaaf6315f3d9ed524 [file] [log] [blame]
diff --git content/browser/renderer_host/ipc_utils.cc content/browser/renderer_host/ipc_utils.cc
index 5cb6e6463767d..84a9de1dfc6f0 100644
--- content/browser/renderer_host/ipc_utils.cc
+++ content/browser/renderer_host/ipc_utils.cc
@@ -73,7 +73,7 @@ bool VerifyInitiatorOrigin(
navigation_url_key,
navigation_url->DeprecatedGetOriginAsURL().spec());
}
- if (initiator_frame_token) {
+ if (initiator_frame_token && initiator_frame_token->has_value()) {
if (RenderFrameHostImpl* initiator_render_frame_host =
RenderFrameHostImpl::FromFrameToken(
process_id, initiator_frame_token->value())) {
diff --git content/browser/renderer_host/render_frame_host_impl.cc content/browser/renderer_host/render_frame_host_impl.cc
index 44ab3ea5a90eb..9962e033ab103 100644
--- content/browser/renderer_host/render_frame_host_impl.cc
+++ content/browser/renderer_host/render_frame_host_impl.cc
@@ -10100,6 +10100,7 @@ void RenderFrameHostImpl::CommitNavigation(
auto browser_calc_origin_to_commit =
navigation_request->GetOriginToCommitWithDebugInfo();
if (!process_lock.is_error_page() && !is_mhtml_subframe &&
+ common_params->url.IsStandard() &&
!policy->CanAccessDataForOrigin(
GetProcess()->GetID(), browser_calc_origin_to_commit.first.value())) {
SCOPED_CRASH_KEY_STRING64("CommitNavigation", "lock_url",