Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ async-trait = "0.1.89"
axum = "0.8.9"
base64 = "0.22.1"
bytes = "1.12.1"
cap-std = "4.0.2"
cap-std = "4.0.3"
caps = "0.5.6"
chacha20poly1305 = { version = "0.11.0", features = ["zeroize"] }
clap = { version = "4.6.2", features = ["derive"] }
Expand All @@ -52,7 +52,7 @@ flate2 = "1.1.9"
fs2 = "0.4.3"
futures-util = "0.3.33"
getrandom = "0.4.3"
hickory-proto = "0.26.1"
hickory-proto = "0.26.2"
http = "1.4.0"
http-body-util = "0.1.4"
httparse = "1.10.1"
Expand All @@ -72,7 +72,7 @@ proptest = "1.11.0"
rcgen = "0.14.8"
reqwest = { version = "0.13.4", default-features = false, features = ["rustls", "socks", "stream"] }
rpassword = "7.5.4"
rustix = { version = "1.1.4", features = ["fs", "process", "std"] }
rustix = { version = "1.1.6", features = ["fs", "process", "std"] }
rlimit = "0.11.0"
roxmltree = "0.21.1"
rustls = { version = "0.23.46", default-features = false, features = ["ring", "std", "tls12"] }
Expand Down
11 changes: 8 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,10 @@ multi-repo workspaces, and nested agent sandbox settings.
### 1. Install SendBox and a runtime

**Central Homebrew automation is pending review and activation in the tap.**
It will use verified patched stable releases v0.2.3 or newer; older artifacts
predate the TLS fixes for RUSTSEC-2026-0382/0383. See
The v0.2.3 TLS-fix floor alone is no longer sufficient: v0.2.5 also predates
the dependency fixes identified by the November 11, 2026 audit. New reviewed
host/guest release artifacts are still required. See the
[dependency security status](docs/installation.md#dependency-security-status) and
[stable Homebrew updates](docs/installation.md#stable-homebrew-updates).

Install the CLI from the existing Homebrew tap:
Expand All @@ -99,13 +101,16 @@ need that bundle separately.

| Your host | Session runtime and prerequisites | Setup |
|---|---|---|
| macOS 26+ on Apple silicon | Apple Containerization, Xcode 26, and official `container` CLI **0.10.0** with its service registered and running | [Apple runtime](docs/apple-runtime.md) |
| macOS 26+ on Apple silicon | Apple Containerization, Xcode 26, and an exact matching official `container` CLI/service pair: **0.10.0** or **1.7.1**, with the service registered and running | [Apple runtime and qualification status](docs/apple-runtime.md) |
| Linux x86_64 or aarch64 with hardware or nested virtualization | Kata Containers **3.28+**, containerd **1.7+**, nerdctl, CNI plugins, and user access to `/dev/kvm` and containerd | [Kata runtime](docs/kata-containers.md) |

Linux host binaries also need libseccomp, libelf, zlib, and zstd runtime libraries
(on Debian/Ubuntu: `libseccomp2 libelf1 zlib1g libzstd1`). Rust is only required
when building from source.

Apple 1.7.1 compatibility is currently source-only, not part of released
SendBox v0.2.5. See the [release and physical qualification gates](docs/apple-runtime.md#qualification).

Run the installed `setup.sh` as your normal user for runtime preflight and
configuration assistance, not `sudo sendbox`. For macOS package/DMG installs,
the helper is `/usr/local/share/sendbox/setup.sh`; for tarballs it is in the
Expand Down
2 changes: 1 addition & 1 deletion Tests/qualification/inventory.v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
{"id":"module.rust-policy","category":"source_module","name":"Rust policy validation foundation","disposition":"preserve","rationale":"Retain structural policy validation without adding decisions in this PR.","evidence":["crates/sendbox-policy/src/lib.rs#PolicyConfiguration"],"target_crate":"sendbox-policy","target_phase":4,"conformance":{"status":"implemented","fixture_ids":["config.contracts"],"compatibility_note":null}},
{"id":"module.rust-mcp","category":"source_module","name":"Rust production MCP subsystem","disposition":"preserve","rationale":"Retain bounded framing, strict JSON-RPC validation, hierarchical deny-first tool policy, exact-command stdio brokering, trusted Streamable HTTP gateway enforcement, project validation, authenticated runtime policy, native observation records, deterministic observer descriptions, and Safe Outputs intent validation.","evidence":["crates/sendbox-mcp/src/artifact.rs#NativeObserverArtifact","crates/sendbox-mcp/src/audit.rs#BoundaryAuditEvent","crates/sendbox-mcp/src/broker.rs#StdioBroker","crates/sendbox-mcp/src/config.rs#ProjectConfigValidator","crates/sendbox-mcp/src/error.rs#errors","crates/sendbox-mcp/src/framing.rs#FrameDecoder","crates/sendbox-mcp/src/http_gateway.rs#HttpGateway","crates/sendbox-mcp/src/jsonrpc.rs#validate_message","crates/sendbox-mcp/src/lib.rs#public exports","crates/sendbox-mcp/src/observation.rs#ObservationParser","crates/sendbox-mcp/src/policy.rs#CompiledToolPolicy","crates/sendbox-mcp/src/runtime.rs#McpRuntimePolicy","crates/sendbox-mcp/src/safe_outputs.rs#Safe Outputs schemas sanitization artifact chain and seals"],"target_crate":"sendbox-mcp","target_phase":7,"conformance":{"status":"implemented","fixture_ids":["mcp.contracts","policy.decisions","persisted.formats","known-defects.negative"],"compatibility_note":null}},
{"id":"module.rust-runtime","category":"source_module","name":"Rust runtime foundation","disposition":"preserve","rationale":"Retain typed lifecycle, capability, process, cancellation, output, cleanup, and lifecycle-owned host/guest control-channel contracts.","evidence":["crates/sendbox-runtime/src/cancellation.rs#CancellationToken","crates/sendbox-runtime/src/capability.rs#RuntimeCapabilities","crates/sendbox-runtime/src/channel.rs#ControlChannelRequest and ProvisionedControlChannel","crates/sendbox-runtime/src/cleanup.rs#CleanupTransaction","crates/sendbox-runtime/src/clock.rs#Clock","crates/sendbox-runtime/src/error.rs#RuntimeError","crates/sendbox-runtime/src/id.rs#ContainerId and ImageReference","crates/sendbox-runtime/src/lib.rs#public exports","crates/sendbox-runtime/src/lifecycle.rs#LifecycleStateMachine","crates/sendbox-runtime/src/output.rs#OutputEvent","crates/sendbox-runtime/src/process.rs#ProcessRunner","crates/sendbox-runtime/src/provider.rs#RuntimeProvider","crates/sendbox-runtime/src/unavailable.rs#UnavailableRuntimeProvider"],"target_crate":"sendbox-runtime","target_phase":3,"conformance":{"status":"implemented","fixture_ids":["runtime.contracts"],"compatibility_note":"Transport endpoint mappings remain adapter-specific and are not claimed by this foundation."}},
{"id":"module.rust-apple-runtime","category":"source_module","name":"Rust production Apple runtime adapter","disposition":"redesign","rationale":"Implement the object-safe runtime contract through the official Apple container 0.10.0 CLI with trusted direct execution, signed guest bundles, non-mutating preflight, lifecycle-owned authenticated stdio transport, bounded streaming and idempotent cleanup.","evidence":["crates/sendbox-runtime-apple/src/lib.rs#public Apple runtime exports","crates/sendbox-runtime-apple/src/command.rs#exact Apple CLI argv and launch configuration","crates/sendbox-runtime-apple/src/executable.rs#trusted executable resolution","crates/sendbox-runtime-apple/src/provider.rs#AppleRuntime RuntimeProvider implementation","crates/sendbox-runtime-apple/src/channel.rs#lifecycle-owned inherited-stdio control channel"],"target_crate":"sendbox-runtime-apple","target_phase":8,"conformance":{"status":"implemented","fixture_ids":["runtime.contracts","persisted.formats","known-defects.negative"],"compatibility_note":"The unqualified Swift framework path and unproven --publish-socket mapping are replaced by an official-CLI inherited-stdio relay; unsupported service mutation and policy combinations fail explicitly."}},
{"id":"module.rust-apple-runtime","category":"source_module","name":"Rust production Apple runtime adapter","disposition":"redesign","rationale":"Implement the object-safe runtime contract through exact matched official Apple container 0.10.0 and 1.7.1 CLI/service pairs with trusted direct execution, signed guest bundles, non-mutating identity/schema preflight, lifecycle-owned authenticated stdio transport, bounded streaming and idempotent cleanup.","evidence":["crates/sendbox-runtime-apple/src/lib.rs#public Apple runtime exports","crates/sendbox-runtime-apple/src/command.rs#exact Apple CLI argv and launch configuration","crates/sendbox-runtime-apple/src/executable.rs#trusted executable resolution","crates/sendbox-runtime-apple/src/provider.rs#AppleRuntime RuntimeProvider implementation","crates/sendbox-runtime-apple/src/channel.rs#lifecycle-owned inherited-stdio control channel"],"target_crate":"sendbox-runtime-apple","target_phase":8,"conformance":{"status":"implemented","fixture_ids":["runtime.contracts","persisted.formats","known-defects.negative"],"compatibility_note":"The unqualified Swift framework path and unproven --publish-socket mapping are replaced by an official-CLI inherited-stdio relay; unsupported service mutation and policy combinations fail explicitly. Portable 1.7.1 conformance does not replace the prepared-host live gate, compatible release packaging or consumer exact-image qualification."}},
{"id":"module.rust-runtime-testkit","category":"source_module","name":"Rust runtime testkit","disposition":"preserve","rationale":"Retain deterministic runtime fakes, fixtures, and conformance scenarios.","evidence":["crates/sendbox-testkit/src/bin/process_fixture.rs#process fixture","crates/sendbox-testkit/src/lib.rs#RuntimeConformanceScenario"],"target_crate":"sendbox-testkit","target_phase":3,"conformance":{"status":"implemented","fixture_ids":["runtime.contracts"],"compatibility_note":null}},
{"id":"module.rust-project","category":"source_module","name":"Rust project analysis","disposition":"preserve","rationale":"Retain bounded native project analysis, optional refinement, and deterministic devcontainer generation.","evidence":["crates/sendbox-project/src/analysis.rs#Analyzer","crates/sendbox-project/src/devcontainer.rs#generate_devcontainer","crates/sendbox-project/src/error.rs#ProjectError","crates/sendbox-project/src/jsonc.rs#parse_jsonc","crates/sendbox-project/src/lib.rs#public exports","crates/sendbox-project/src/refinement.rs#RefinementProvider","crates/sendbox-project/src/scan.rs#ScanReport"],"target_crate":"sendbox-project","target_phase":10,"conformance":{"status":"implemented","fixture_ids":["setup.release"],"compatibility_note":null}},
{"id":"module.rust-bpf","category":"source_module","name":"Rust production BPF observation facade","disposition":"preserve","rationale":"Retain bounded versioned event decoding, Linux capability and BTF probes, cgroup-scoped libbpf lifecycle, typed diagnostics, and explicit event-loss accounting without enforcement claims.","evidence":["crates/sendbox-bpf/src/error.rs#BpfError and DiagnosticKind","crates/sendbox-bpf/src/event.rs#versioned bounded event ABI","crates/sendbox-bpf/src/lib.rs#public exports","crates/sendbox-bpf/src/loader.rs#EventStream and LossSnapshot","crates/sendbox-bpf/src/preflight.rs#kernel BTF tracepoint and capability probes","crates/sendbox-bpf/src/report.rs#bounded session-bound argument-free syscall reports"],"target_crate":"sendbox-bpf","target_phase":7,"conformance":{"status":"implemented","fixture_ids":["known-defects.negative","runtime.contracts"],"compatibility_note":"Exec and syscall hooks are cgroup-subtree audit observation with explicit sampling and loss accounting; the bounded MCP ABI is reserved and has no producer in this phase."}},
Expand Down
2 changes: 1 addition & 1 deletion crates/sendbox-exec/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ caps.workspace = true
libc.workspace = true
libseccomp.workspace = true
rlimit.workspace = true
rustix = { version = "1.1.4", features = ["event", "fs", "process", "pty", "termios", "std"] }
rustix = { version = "1.1.6", features = ["event", "fs", "process", "pty", "termios", "std"] }

[dev-dependencies]
tempfile.workspace = true
Expand Down
20 changes: 20 additions & 0 deletions crates/sendbox-runtime-apple/src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,13 +260,30 @@ impl AppleContainerCommands {
])
}

#[must_use]
pub(crate) fn builtin_network_inspect(&self) -> CommandSpec {
self.spec(["network", "inspect", "default"])
}

pub fn create(
&self,
id: &ContainerId,
image: &str,
launch: &AppleLaunchConfiguration,
bundle_root: &Path,
public_key: &Path,
) -> Result<CommandSpec, RuntimeError> {
self.create_with_capabilities(id, image, launch, bundle_root, public_key, &[])
}

pub(crate) fn create_with_capabilities(
&self,
id: &ContainerId,
image: &str,
launch: &AppleLaunchConfiguration,
bundle_root: &Path,
public_key: &Path,
capabilities: &[&str],
) -> Result<CommandSpec, RuntimeError> {
validate_image(image)?;
launch.validate()?;
Expand Down Expand Up @@ -298,6 +315,9 @@ impl AppleContainerCommands {
display_path(public_key_parent)
)),
];
for capability in capabilities {
arguments.extend([plain("--cap-add"), plain(*capability)]);
}
append_environment(&mut arguments, &launch.environment);
append_mounts(&mut arguments, &launch.mounts)?;
append_network(&mut arguments, &launch.network)?;
Expand Down
Loading
Loading