Secure Host for Agentic AI Dynamic Instantiation (SHADI) is a secure host runtime for autonomous, multi-agent systems.
SHADI is designed for environments where agents are long-lived, hold real credentials, and run close to sensitive data. It combines identity verification, keychain-backed secrets, OS sandboxing, and encrypted local memory to reduce blast radius and make agent behavior auditable.
- Verified secret access gates (
agent_secrets) with OS keychain backends. - Deterministic human -> agent identity derivation (
did:key) and provenance verification. - Kernel-enforced sandbox execution policies (
shadi_sandbox) with portable profile defaults. - SQLCipher-backed encrypted local memory (
shadi_memory). - Python bindings (
shadi_py) for secrets, memory, and sandboxed execution. - SLIM transport integration for secure agent-to-agent messaging.
- Example agents and demos, including a practical SecOps workflow and launch scripts.
Recent updates in this branch of the project:
- SecOps now treats container CVEs as rebuild or base-image refresh work instead of mutating Dockerfiles with ad-hoc package upgrade lines.
- Dockerfile resolution for container findings is workflow-first, using
.github/workflows/*metadata before repo-wide scanning. - Demo launchers are hardened for the optional 1Password backend by reading required secrets before entering the sandbox.
- Avatar surfaces clearer SLIM handshake errors when the SecOps A2A side is unavailable or misconfigured.
crates/shadictl: main CLI (shadi) for policy, sandbox execution, key management, and identity derivation/verification.crates/shadi_sandbox: sandbox policy model and platform enforcement.crates/agent_secrets: keychain-backed secret storage + verification-gated access.crates/shadi_memory: SQLCipher memory library and CLI (shadi-memory).crates/shadi_py: Python extension moduleshadi.crates/agent_transport_slim+crates/slim_mas: secure transport and moderation helpers.agents/secops: example SecOps workload, A2A server, and skill implementation.docs: architecture, security, CLI, demos, and integration docs.scripts: local launch helpers for SLIM + agent demos.
SHADI runtime flow:
- Ingest human identity material (
gpgsecret material or generic seed). - Derive deterministic Ed25519 local keys and
did:keyidentities per agent. - Optionally bind agent identities to a stored human DID and verify provenance.
- Apply sandbox policy (filesystem/network/command controls).
- Gate secret access on verified sessions.
- Persist agent memory encrypted at rest.
For full details, see docs/architecture.md and docs/security.md.
- Rust toolchain (stable) with Cargo
- Python 3.12 (for
shadi_pyand Python demos) just(recommended task runner)- Optional for docs:
mkdocs(and related theme/plugins used by this repo)
Build all crates:
cargo build --workspaceRun all tests:
cargo test --workspaceIf you use just, common tasks are available:
just build
just test
just lintcargo run -p shadictl -- --profile balanced --print-policyAvailable built-in profiles:
strict: local-only policy with network blockedbalanced: practical local default with network blockedconnected: balanced + network enabled
cargo run -p shadictl -- \
--allow . \
--read / \
--net-block \
-- \
/usr/bin/env echo "hello from sandbox"cargo run -p shadictl -- \
derive-agent-identity \
--source gpg \
--human-secret human/gpg \
--name secops-a \
--name avatar-1 \
--prefix agents \
--out-dir ./agent-didscargo run -p shadictl -- \
verify-agent-identity \
--source gpg \
--human-secret human/gpg \
--name secops-a \
--prefix agentscargo run -p shadictl -- -- memory init \
--db "${SHADI_TMP_DIR:-./.tmp}/shadi-memory.db" \
--key-name shadi/memory/sqlcipher_keyBuild the Python extension crate:
cargo build -p shadi_pyThe module exposes bindings for:
- secret store operations and session verification hooks
- SQLCipher memory operations
- sandbox policy handles and sandboxed process execution
The repo includes runnable demo workloads under agents/secops and helper scripts in scripts/.
Common local flow:
./scripts/launch_slim.sh
./scripts/import_secops_secrets.sh
./scripts/launch_secops_a2a.sh
./scripts/launch_avatar.shFocused Python tests for the SecOps skill:
just secops-test-pythonSecurity scan for the SecOps skill package:
just secops-skill-scanSee scripts/README.md and docs/demo.md for full setup details.
Primary docs live in docs/:
docs/index.md: project overviewdocs/architecture.md: runtime and control planesdocs/security.md: threat model and security notesdocs/cli.md: complete CLI referencedocs/sandbox.md: policy model and profile behaviordocs/demo.md: demo walkthroughdocs/secops_agent.md: SecOps demo workload and remediation behavior
Build/serve docs locally:
mkdocs build
mkdocs serve- Keep changes focused and platform-safe (macOS, Windows, Linux where applicable).
- Prefer policy/profile-based secure defaults instead of ad-hoc shell wrappers.
- Use deterministic identity derivation and
verify-agent-identityfor provenance checks. - Run
cargo test --workspacebefore opening a PR.
See:
CONTRIBUTING.mdCODE_OF_CONDUCT.mdSECURITY.md
See LICENSE.md.