commit | 715e8eb247a58cf7b30459fba5bb3ff048b72a06 | [log] [tgz] |
---|---|---|
author | Xiaohan Wang <xhwang@chromium.org> | Wed Jan 12 00:19:28 2022 |
committer | Copybara-Service <copybara-worker@google.com> | Wed Jan 12 00:36:52 2022 |
tree | 93f7bf1bc036cbd5e9e05f646877123483413ad7 | |
parent | 3e7369b9c68a63fce4c248a660991d80c85302e3 [diff] |
sandbox: Use BUILDFLAG for OS checking Use BUILDFLAG(IS_XXX) instead of defined(OS_XXX). Generated by `os_buildflag_migration.py` (https://crrev.com/c/3311983). R=thakis@chromium.org Bug: 1234043 Test: No functionality change Change-Id: Ia62a8cf93a245ac4e20de6fa7c1ee0a9823ebe99 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3373987 Reviewed-by: Nico Weber <thakis@chromium.org> Reviewed-by: Robert Sesek <rsesek@chromium.org> Owners-Override: Nico Weber <thakis@chromium.org> Commit-Queue: Xiaohan Wang <xhwang@chromium.org> Cr-Commit-Position: refs/heads/main@{#957824} NOKEYCHECK=True GitOrigin-RevId: c67d9954482723e16d0abc8ca2a648b1c44207d5
This directory contains platform-specific sandboxing libraries. Sandboxing is a technique that can improve the security of an application by separating untrustworthy code (or code that handles untrustworthy data) and restricting its privileges and capabilities.
Each platform relies on the operating system's process primitive to isolate code into distinct security principals, and platform-specific technologies are used to implement the privilege reduction. At a high-level:
mac/
uses the Seatbelt sandbox. See the detailed design for more.linux/
uses namespaces and Seccomp-BPF. See the detailed design for more.win/
uses a combination of restricted tokens, distinct job objects, alternate desktops, and integrity levels. See the detailed design for more.Built on top of the low-level sandboxing library is the //sandbox/policy
component, which provides concrete policies and helper utilities for sandboxing specific Chromium processes and services. The core sandbox library cannot depend on the policy component.