Bug 1213998 - Apply chroot() to sandboxed content processes on Linux. r=gcp
MozReview-Commit-ID: DGepECmw3pq
--- a/security/sandbox/linux/launch/SandboxLaunch.cpp
+++ b/security/sandbox/linux/launch/SandboxLaunch.cpp
@@ -215,16 +215,17 @@ SandboxLaunchPrepare(GeckoProcessType aT
break;
#endif
#ifdef MOZ_CONTENT_SANDBOX
case GeckoProcessType_Content:
// TODO: CLONE_NEWIPC (bug 1376910) if not fglrx and level >= 1,
// once the XShm detection shim is fixed.
if (level >= 4) {
+ canChroot = true;
// Unshare network namespace if allowed by graphics; see
// function definition above for details. (The display
// local-ness is cached because it won't change.)
static const bool isDisplayLocal = IsDisplayLocal();
if (isDisplayLocal) {
flags |= CLONE_NEWNET;
}
}