# google/sandboxed-api

Generate sandboxes for C/C++ libraries automatically

Repository: https://github.com/google/sandboxed-api
Canonical: https://ross.abutalabs.com/products/sandboxed-api
Homepage: https://developers.google.com/sandboxed-api/
Language: C++
License: Apache-2.0
License Family: permissive
Topics: sandboxing, sandbox, security, security-hardening, cplusplus-17, cplusplus, apache-license-2, sapi
Last push: 2026-08-26T18:49:09+00:00

## Health v2 (maintenance only)
Score: 67/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 8, longevity 100
- inputs: {"age_days": 2736, "days_push": 7, "days_rel": 694, "gap_med": null, "n_releases_24m": 1}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1758, forks 199 (observed 2026-08-28T04:05:32.377277+00:00)

## What it is
Google's Sandboxed API (SAPI) automatically generates sandboxes for individual C/C++ libraries, isolating them from the host program using the underlying Sandbox2 technology. It lets developers sandbox a library once and reuse it anywhere with tightly scoped security policies.

## Use cases
- sandbox a C/C++ library to contain code execution vulnerabilities
- isolate untrusted third-party libraries without modifying their source code
- apply tightly scoped seccomp-bpf syscall policies per library
- reuse sandbox policies across multiple projects that use the same library
- run untrusted code in a Linux sandbox with namespaces and resource limits
- sandbox individual components of a larger program instead of the whole program

## When to choose
- you need fine-grained sandboxing of specific C/C++ libraries on Linux
- you want to isolate code execution vulnerabilities in third-party libraries
- you want reusable sandbox policies instead of reimplementing them per project
- you need a security boundary for your own C/C++ code in production

## When to avoid
- you need to sandbox whole programs or CLI tools rather than libraries (use Sandbox2, NSJail, or Minijail directly)
- your project is not on Linux
- you need sandboxing for non-C/C++ languages or managed runtimes
- you need a general-purpose container or VM-level isolation solution

## Facets
- artifact type: library
- maturity: active
- function: security, developer-tools
- domain: security, developer-tools, backend
- platform: cpp
- tags: sandboxing, seccomp-bpf, sandbox2, c-cpp-libraries, security-hardening, google, linux, bazel

## Member repositories
- google/sandboxed-api (main) score 67

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:32.377277+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:27:34.534747+00:00, confidence not recorded.
  - readme: https://github.com/google/sandboxed-api (fetched 2026-08-28T04:05:32.377277+00:00, sha 52759ad0b934)
  - homepage: https://developers.google.com/sandboxed-api/ (fetched 2026-08-29T11:05:40.867875+00:00, sha 2dfe8b83e0b0)
- Data as of 2026-08-30T08:39:29.467469+00:00.
