Skip to main content
Glama

엔터프라이즈 AI 에이전트 샌드박스

에이전트형 AI 워크플로우에 샌드박스 실행을 연결하기 위한 보안 프레임워크입니다. Claude Code, Codex, Cursor 또는 기타 AI 에이전트가 실행되는 모든 폴더에 커넥터를 설치하세요. 모든 권한 있는 명령은 인간 승인자에게 에스컬레이션되고, 에이전트의 컨텍스트 외부에서 실행되며, 출력은 모델에 다시 전달되어 계속 진행할 수 있습니다.

아키텍처

폴더 커넥터는 샌드박스를 프로젝트에 연결합니다:

  • Claude Code 훅은 도구 호출을 가로채고, 권한 있는 작업을 인간 승인자에게 에스컬레이션하며, 캡처된 출력을 deny 결정 내부에 반환하여 도구가 에이전트 권한으로 실행되지 않도록 합니다

  • MCP 서버 (run_privileged, check_request, sandbox_status)는 Model Context Protocol을 통해 동일한 루프를 제공합니다 — Claude Code, Codex, Cursor, Windsurf와 호환됩니다

  • 폴더 큐 (.sandbox/escalations/)는 버스 역할을 합니다: 원자적 파일 작업 (os.replace, os.rename)이 네 개의 독립적인 프로세스(훅 서브프로세스, MCP 서버, 승인자 터미널, 대시보드) 간의 승인을 조정합니다

  • 정책 엔진은 셸 명령, 파일 쓰기, 네트워크 요청, 읽기를 분류합니다 — 최상위 계층에 인간 개입이 있는 네 가지 에스컬레이션 트리거가 있습니다

Related MCP server: @looppause/mcp

빠른 시작

# Install the connector
python -m pip install -e ".[dev]"

# Initialize a folder
sandbox init . --claude --mcp

# In one terminal: watch for escalations
sandbox watch .

# In another: use Claude Code or the MCP tools as normal
# Privileged commands will appear in the `watch` terminal for approval

작동 방식

  1. 에이전트가 명령을 실행하려고 시도합니다 — Claude Code의 PreToolUse 훅이 이를 가로챕니다

  2. 훅이 분류하고 에스컬레이션합니다 — 허용 목록에 없는 셸 명령은 폴더 큐로 이동합니다

  3. 인간이 sandbox watch에서 승인합니다 — 승인자가 에이전트 외부에서 명령을 실행합니다

  4. 출력이 모델로 반환됩니다 — stdout이 reason 문자열에 포함된 permissionDecision:"deny"로 래핑됩니다

  5. 에이전트가 계속 진행합니다 — 결과를 받았지만, 그 자체로는 권한을 가진 적이 없습니다

MCP 채널도 동일하게 작동합니다: run_privileged는 캡처된 출력이 포함된 도구 결과를 반환합니다.

마일스톤

  • ✅ 마일스톤 0 — 기반 (버그 수정, 경로 격리, 감사 재수화)

  • ✅ 마일스톤 1 — 루프 (PreToolUse 훅, 폴더 큐, CLI 승인)

  • ✅ 마일스톤 2 — MCP 채널 (run_privileged, check_request, sandbox_status)

  • ✅ 마일스톤 3 — 폴더 레코드 (복원 가능한 원본, 연결된 감사, PostToolUse)

  • ✅ 마일스톤 4 — 기타 트리거 (전체 분류기, 기억된 결정, SessionStart 컨텍스트)

  • ✅ 마일스톤 5 — 표면 (REST 라우트, 제거, 문서)

모든 마일스톤 완료. 전체 기술 참조는 docs/CONNECTOR.md를 참조하세요.

테스트

# Run all tests (117 passing)
python -m pytest -q

# Test the loop with a real hook subprocess and background approver
python -m pytest tests/integration/test_connector_loop.py -v

# Test the MCP channel
python -m pytest tests/integration/test_mcp_tools.py -v

프로젝트 구조

src/sandbox/
├── connector/           # Folder connector (queue, hooks, policy, MCP)
├── launcher/            # M1 jailed launcher (job objects, jail, shims)
├── audit/               # Chained audit log with tamper detection
├── broker/              # Non-AI privilege executor
├── fs/                  # Path containment and validation
├── agents/              # Multi-agent sandbox orchestrator
├── api/                 # FastAPI routes and WebSocket
└── ...

주요 설계 결정

  • 폴더가 버스입니다: NTFS의 원자적 파일 작업이 네 개의 독립적인 프로세스를 조정합니다 (인메모리 상태 없음, 개방 포트 없음, 재시작에도 유지됨)

  • deny가 출력을 전달합니다: 도구는 에이전트에서 실행되지 않으며, 출력은 reason 문자열에 붙여넣어 반환됩니다

  • CLI 우선 승인: 헤드리스, SSH를 통한 원격 작업 가능, 브라우저 의존성 없음

  • 실패 시 폐쇄: 내부 오류는 조용히 허용하는 대신 차단합니다

  • 제거 불가능한 자체 보호: .sandbox/**는 쓰기 거부에, \.sandbox는 셸 거부에 모든 정책 로드 시 재주입됩니다 — 에이전트는 자신의 제약을 제거할 수 없습니다

라이선스

[미정]

Available Tools

5 tools
check_requestA

Retrieve the outcome of an escalation (from MCP OR the hook).

Use this after run_privileged returns 'pending', or to pick up a request the Claude Code hook raised.

NameRequiredDescriptionDefault
request_idYes
wait_secondsNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

A3.5/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. Yet it never explains the polling semantics implied by wait_seconds — what happens on timeout, whether it blocks, what states the outcome can be in, or the return shape. For a polling-type tool this is a notable gap given there is no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tight sentences with the purpose front-loaded ahead of the usage trigger. No filler. It only loses a point because the second clause ('or to pick up a request the Claude Code hook raised') could arguably have been folded into the first, though it does add the sibling/hook context.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given it has an output schema and only two parameters (one with a meaningful default), the description covers the core purpose and when to call it competently. But it leaves out the wait_seconds timeout/blocking behavior and the possible outcome states — information an agent polling after a pending escalation would reasonably need before calling.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, but it adds no parameter meaning at all. request_id and wait_seconds are never explained beyond their raw schema definition (an ID string and a defaulted integer). The description's mention of 'the request' hints at request_id but provides no semantics like what a valid ID looks like or what wait_seconds controls.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource — 'Retrieve the outcome of an escalation' — with an explicit scope qualifier ('from MCP OR the hook'). It differentiates itself from its sibling run_privileged by the triggering mechanism it responds to, so an agent can tell exactly what this tool is for.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives explicit when-to-use context: 'after run_privileged returns pending, or to pick up a request the Claude Code hook raised.' This is clear and actionable, though it stops short of stating when-not-to-use or naming an alternative for older/unresolved requests.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

fetch_urlA

Fetch a URL through the sandbox. A human approves; you get the body.

Network access is gated — the sandbox performs the fetch outside your context so you never make the request directly.

NameRequiredDescriptionDefault
urlYes
reasonNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

A3.8/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden. It discloses that a human approves each request and that the sandbox performs the fetch outside the agent's context, providing key behavioral context. However, it does not cover all potential behaviors like failure scenarios or rejection handling.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise, with two short paragraphs that front-load the primary purpose and add key behavioral context without unnecessary words. Every sentence contributes value, making it well-structured and efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is simple with only two parameters, and the description covers the main flow (fetch, approval, body). However, it omits the purpose of the 'reason' parameter, which is significant given zero schema descriptions. The output schema likely covers return format, but the missing parameter explanation creates a gap.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, but it fails to explain the 'reason' parameter or any URL constraints. It implicitly mentions the URL but adds no meaningful detail beyond what the schema already shows (just types). The optional reason parameter is left unexplained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool fetches a URL through the sandbox, specifying both the verb and resource. It is distinct from siblings like run_privileged and request_path_access, making its purpose unambiguous and easy to differentiate.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage when needing to fetch a URL and mentions human approval, but it does not explicitly state when to use this tool versus alternatives or specify exclusions. The guidance is implied rather than explicit, leaving some ambiguity.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

request_path_accessA

Request a file operation OUTSIDE the sandbox folder.

A human approves; the sandbox performs the read or write on your behalf (you never receive the capability). mode is "read" or "write"; for "write", pass the file content in content.

NameRequiredDescriptionDefault
modeNoread
pathYes
reasonNo
contentNo

Output Schema

NameRequiredDescription

No output parameters

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It discloses critical behavioral traits: a human must approve, the sandbox performs the read/write on the agent's behalf, and the agent never receives the capability. This covers the most important asynchronous and security implications. It does not mention whether the operation is blocking or how to check approval status, but the core behavior is transparent.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences with no redundancy. The first sentence states the purpose upfront, and the second explains the approval process and parameter usage. Every word earns its place, and the structure is optimized for quick comprehension.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite having an output schema, the description is fairly complete for a tool that requires human approval. It covers the main flow (request, approval, sandbox performs) and key parameters (mode, content). It does not mention that the operation is asynchronous or that the agent should poll check_request for status, but given the sibling tools and the output schema, this is a moderate gap. Overall, it's adequate but not exhaustive.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for parameter meaning. It does explain 'mode' (valid values 'read' or 'write') and 'content' (used with write mode), which adds value. However, it does not clarify 'path' (though it's implied as the target file) or 'reason' (its purpose), leaving those parameters ambiguous. While partial compensation, the coverage gaps prevent a higher score.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: requesting a file operation outside the sandbox folder. It specifies the verb 'Request' and the resource 'a file operation', and the scope 'OUTSIDE the sandbox folder' differentiates it from siblings like run_privileged, fetch_url, check_request, and sandbox_status, which have distinct purposes. The distinction is explicit and leaves no ambiguity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context: this tool is for file operations that need to happen outside the sandbox. It implies that for operations inside the sandbox, this tool is not needed. However, it does not explicitly name alternatives or state when not to use it; rather, it relies on the reader to infer that other tools like run_privileged or fetch_url are for different resource types. This is clear context but no exclusions are stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

run_privilegedA

Request a privileged shell command. A human approves; you get the output.

The command runs OUTSIDE the sandbox on your behalf — you never receive root yourself. Returns the captured stdout/stderr on approval.

NameRequiredDescriptionDefault
reasonNo
commandYes

Output Schema

NameRequiredDescription

No output parameters

TDQS

A3.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full responsibility. It discloses critical behaviors: human approval is required, the command runs outside the sandbox, the agent never receives root, and output is captured on approval. This is substantial transparency, though it omits what happens on rejection, timeouts, or any safety caveats—more than enough to earn a 4 but not a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences with no filler. The core action is front-loaded ('Request a privileged shell command'), and the second sentence adds essential behavioral context. Every clause earns its place; it is a model of conciseness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite having an output schema, the description misses critical operational details an agent needs: what happens if approval is denied, is the request asynchronous (the term 'Request' implies a wait, but it is not stated), what is the expected latency, and how does the 'reason' parameter factor into approval. It also does not mention safety or restrictions on the command. These gaps are significant for a privileged, human-in-the-loop tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% and the description does not shed any light on the parameters. It never mentions 'command' or 'reason' by name, nor explains expected syntax, purpose of reason, or any parameter-specific guidance. With zero schema coverage, the description must compensate but fails entirely.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('Request') and resource ('a privileged shell command'), and the second sentence adds the key differentiator: it runs outside the sandbox. This distinguishes it from siblings like fetch_url (network) and request_path_access (file access), so an agent can tell it apart without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It is clear the tool is for running privileged shell commands that require human approval, but it does not explicitly state when to prefer it over alternatives or when not to use it. There is no mention of 'use this when sandbox is insufficient' or 'instead of sandbox_status'. The context is implied but not made explicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

sandbox_statusA

Show the sandbox root, triggers, and any pending escalations.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription

No output parameters

TDQS

A3.5/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full behavioral burden. The verb 'Show' implies a non-mutating, read-only operation, which is useful implicit disclosure. However, it doesn't explicitly state that it has no side effects, requires no auth, or how escalations are represented. For a status tool this is acceptable but leaves room for more explicit guarantees.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single, front-loaded sentence with zero waste. The verb leads, and each listed item (root, triggers, pending escalations) earns its place by describing distinct output facets. Nothing is redundant.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a zero-parameter status tool with an output schema present, the description is largely complete — it states exactly what the status covers. Minor gaps exist (e.g., no mention of when status is current or whether it reflects a snapshot), but these are not material for an agent deciding to invoke it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has zero parameters and an empty input schema with 100% coverage, so there is nothing for the description to add. Per the baseline for a 0-param tool, a 4 is appropriate — no parameter documentation burden exists.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource — 'Show the sandbox root, triggers, and any pending escalations.' The verb 'Show' signals a read-only status operation, and the listed content (root, triggers, escalations) is concrete. It does not explicitly contrast with siblings, but the domain is distinct enough from run_privileged, request_path_access, fetch_url, and check_request that an agent can infer the purpose.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is given on when to use this tool versus the siblings. It does not state prerequisites, conditions, or exclusions. For example, it doesn't clarify that this should be called before requesting access or that it's the safe inspection entry point. The agent must infer usage purely from the name and the sibling list.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 5 tool updatesv1.0.0
    • First observedcheck_request
    • First observedfetch_url
    • First observedrequest_path_access
    • First observedrun_privileged
    • First observedsandbox_status

TDQS

A4/5.0

Scored across 5 tools

Disambiguation5/5

Each tool targets a distinct capability: shell execution, file access, network fetch, request status, and sandbox overview. There is no overlap in purpose, and descriptions clearly delineate boundaries.

Naming Consistency4/5

Most tools follow a verb_noun pattern (run_privileged, request_path_access, fetch_url, check_request), but sandbox_status breaks the pattern by being noun_noun. The deviation is minor and the intent remains clear.

Tool Count5/5

With 5 tools, the server is well-scoped for its purpose of gated external operations. Each tool earns its place without redundancy or excess.

Completeness5/5

The surface covers all core operations (run, file, fetch) and provides status retrieval via check_request and sandbox_status. No obvious dead ends or missing lifecycle steps for the stated escalation workflow.

Maintenance

ActivityActive
ResponsivenessNo recent community issues

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Provides a human approval gate for AI agents, enabling interactive inline cards for approving, editing, or rejecting actions before they are executed.
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Pauses AI agent execution and routes approval requests to humans via Slack or email, with cryptographically signed proof of the human's decision.
    44 npm
    MIT
  • A
    license
    A
    quality
    D
    maintenance
    Enables AI agents to securely use real secrets (API keys, database passwords) by requiring human approval for each release, ensuring secrets never enter the model's context.
    2
    Apache 2.0
  • A
    license
    Not graded
    quality
    C
    maintenance
    Gates agent tool execution with human approval, audit trails, and replay-resistant permits, enabling safe use of tools in agent loops.
    14 PyPI
    MIT