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

Unified Diff: content/common/sandbox_win.cc

Issue 1720643002: [Win10 sandbox mitigations] MITIGATION_NONSYSTEM_FONT_DISABLE adjustment. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: <sigh> Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/sandbox_win.cc
diff --git a/content/common/sandbox_win.cc b/content/common/sandbox_win.cc
index 29fb55713db92c563a4ca2a723682e108769efdf..ebbbc2250867bddc9df8b26357e9ef77b2a13f8c 100644
--- a/content/common/sandbox_win.cc
+++ b/content/common/sandbox_win.cc
@@ -739,6 +739,15 @@ base::Process StartSandboxedProcess(
sandbox::TargetPolicy::FILES_ALLOW_READONLY,
policy);
+ // Turn off the MITIGATION_NONSYSTEM_FONT_DISABLE mitigation
+ // when Direct Write is enabled.
jschuh 2016/02/22 22:30:24 I think this is backward. Don't you want to enable
penny 2016/02/23 05:30:37 Done.
+ sandbox::MitigationFlags temp =
+ ~sandbox::MITIGATION_NONSYSTEM_FONT_DISABLE;
+ mitigations = policy->GetProcessMitigations();
+ mitigations &= temp;
+ if (policy->SetProcessMitigations(mitigations) != sandbox::SBOX_ALL_OK)
+ return base::Process();
+
if (!ShouldUseDirectWriteFontProxyFieldTrial()) {
// If DirectWrite is enabled for font rendering then open the font
// cache section which is created by the browser and pass the handle to
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698