Bug 1325227 - Part 3: Allow child process to share mutex handles with the parent/gpu processes. r=bobowen

This commit is contained in:
Matt Woodrow 2017-01-12 15:23:27 +13:00
parent 1538ccfee9
commit fd5448843e

View File

@ -222,6 +222,19 @@ SandboxBroker::SetSecurityLevelForContentProcess(int32_t aSandboxLevel,
L"Section");
MOZ_RELEASE_ASSERT(sandbox::SBOX_ALL_OK == result,
"With these static arguments AddRule should never fail, what happened?");
// The content process needs to be able to duplicate mutex handles,
// which are Mutant handles, to the broker process and other child processes.
result = mPolicy->AddRule(sandbox::TargetPolicy::SUBSYS_HANDLES,
sandbox::TargetPolicy::HANDLES_DUP_BROKER,
L"Mutant");
MOZ_RELEASE_ASSERT(sandbox::SBOX_ALL_OK == result,
"With these static arguments AddRule should never fail, what happened?");
result = mPolicy->AddRule(sandbox::TargetPolicy::SUBSYS_HANDLES,
sandbox::TargetPolicy::HANDLES_DUP_ANY,
L"Mutant");
MOZ_RELEASE_ASSERT(sandbox::SBOX_ALL_OK == result,
"With these static arguments AddRule should never fail, what happened?");
}
#endif