Commit 6e2348f2 authored by Aaron Colwell's avatar Aaron Colwell Committed by Commit Bot

Temporarily restore about:blank commit exception.

This is a minimal fix to avoid renderer kills for about:blank URLs
being committed in the wrong process. This restores M78 about:blank
behavior in a very narrow case and is intended to be easily merged to
the M79 branch.

Bug: 931895
Change-Id: Ie958b667f6879afbcebfe18e3f3f80f8cd88884b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1922693
Commit-Queue: Aaron Colwell <acolwell@chromium.org>
Commit-Queue: Alex Moshchuk <alexmos@chromium.org>
Auto-Submit: Aaron Colwell <acolwell@chromium.org>
Reviewed-by: default avatarAlex Moshchuk <alexmos@chromium.org>
Cr-Commit-Position: refs/heads/master@{#716422}
parent 029d835a
...@@ -1270,6 +1270,15 @@ CanCommitStatus ChildProcessSecurityPolicyImpl::CanCommitOriginAndUrl( ...@@ -1270,6 +1270,15 @@ CanCommitStatus ChildProcessSecurityPolicyImpl::CanCommitOriginAndUrl(
if (actual_origin_lock == expected_origin_lock) if (actual_origin_lock == expected_origin_lock)
return CanCommitStatus::CAN_COMMIT_ORIGIN_AND_URL; return CanCommitStatus::CAN_COMMIT_ORIGIN_AND_URL;
// Allow about: pages to commit in a process that does not match the opaque
// origin's precursor information.
// TODO(acolwell): Remove this once process selection for about: URLs has
// been fixed to always match the precursor info.
if (url_origin.opaque() && url.IsAboutBlank() &&
!actual_origin_lock.is_empty()) {
return CanCommitStatus::CAN_COMMIT_ORIGIN_AND_URL;
}
return CanCommitStatus::CANNOT_COMMIT_URL; return CanCommitStatus::CANNOT_COMMIT_URL;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment