Add owner-mediated bwrap execution boundary

Assistant: codex
Assistant-Model: gpt-5.6-sol
Assistant-Session: 01a06def-6490-7033-8448-2eab2d12ed44
This commit is contained in:
tegwick 2026-09-04 22:12:19 +02:00
parent 877676d1f1
commit d79e3fe358
23 changed files with 1321 additions and 86 deletions

View file

@ -147,6 +147,36 @@ class SandboxCreateRequest(BaseModel):
ttl: str | None = None
class SandboxExecRequest(BaseModel):
"""A command grant bound to the consumer recorded at sandbox creation."""
command: list[str] = Field(min_length=1, max_length=256)
consumer: Consumer
credential_route_refs: list[str] = Field(default_factory=list, max_length=32)
timeout_seconds: int = Field(default=900, ge=1, le=3600)
max_output_bytes: int = Field(default=262_144, ge=1, le=1_048_576)
class SandboxExecResult(BaseModel):
sandbox_id: str
profile_id: str
extension_id: str
consumer: Consumer
command_name: str
exit_code: int
timed_out: bool = False
stdout: str = ""
stderr: str = ""
output_truncated: bool = False
duration_seconds: float
workspace_dir: str
network_default: Literal["deny", "allow"]
network_egress: list[str] = Field(default_factory=list)
credential_route_refs: list[str] = Field(default_factory=list)
started_at: datetime
completed_at: datetime
class Reachability(BaseModel):
ssh: str | None = None
remote_dir: str | None = None
@ -211,4 +241,4 @@ class SnapshotRecord(BaseModel):
consumer: Consumer | None = None
name: str | None = None
size_bytes: int | None = None
created_at: datetime
created_at: datetime