Avoid treating unsandboxed processes as brokers when initializing sandbox_info.
In the past, we've checked for the presence of the kNoSandbox switch when initializing sandbox_info, and if a child process was unsandboxed we would avoid initializing sandbox_info at all. However, the kNoSandbox switch is only meant to be used as a browser level flag for testing purposes only. There exist other ways to denote an unsandboxed process too, as in the case of the unsandboxed utility process which uses the switch service-sandbox-type=none instead of --no-sandbox. Similarly, there's also an unsandboxed GPU process which makes use of the --disable-gpu-sandbox switch instead of the --no-sandbox switch. This has resulted in having unsandboxed processes initializing their sandbox_info as if they were brokers, and as a consequence, having the same process mitigations applied to them. This last behavior is certainly an unintended side-effect that could manifest as a bug eventually. In this CL, we're updating the way in which we check whether a process is unsandboxed to ensure that no unsandboxed processes have their sandbox_info initialized as brokers, and to prevent applying the same process mitigations accidentally. Bug: 1066258 Change-Id: Ifdc14b0e29f9505edeec93417bd9cc7ab73e94c9 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2208189 Auto-Submit: Andres Pico <anpico@microsoft.com> Reviewed-by:Lei Zhang <thestig@chromium.org> Reviewed-by:
Will Harris <wfh@chromium.org> Reviewed-by:
Alex Gough <ajgo@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org> Cr-Commit-Position: refs/heads/master@{#772048}
Showing
Please register or sign in to comment