Skip to main content

PicoDome โ€” deterministic runtime sandbox and behavioral analysis for supply-chain security

Project description

Iron Dome ๐Ÿ›ก๏ธ

Deterministic runtime sandbox and behavioral analysis for supply-chain security.

CI PyPI Python Tests Deterministic SLSA L3 License: BUSL-1.1

IronDome

Iron Dome is a two-layer defense system for npm/Python supply chains. Companion to PicoSentry โ€” static scan โ†’ runtime sandbox.

  • L3 Execution Sandbox โ€” Run any command under kernel-level policy. Real seccomp-bpf (Linux), Seatbelt/sandbox-exec (macOS), or universal subprocess backend.
  • L4 Behavioral Analysis โ€” Post-execution profiling. Detect exfiltration, timing anomalies, honeypot touches, entropy spikes, and baseline drift.

Why Iron Dome?

Static scanners (PicoSentry, Socket.dev, Snyk) inspect code. Iron Dome executes it safely, catching what static analysis misses: dependency confusion with dynamic payloads, post-install data exfiltration, obfuscated eval chains, and supply-chain worms.

Quick Start

pip install irondome

# L3: Sandbox a command
irondome sandbox python3 -c "print('hello')"

# L3+L4: Full pipeline
irondome pipeline npm install some-package

# Analyze existing sandbox output
irondome sandbox --format json npm test > sandbox.json
irondome analyze --input sandbox.json

# List detector rules
irondome rules

# Verify determinism (run twice, compare SHA-256)
irondome sandbox --verify-determinism echo test

# Compare two saved results
irondome diff result_a.json result_b.json

# Workspace scanning (monorepos)
irondome pipeline --workspace /path/to/monorepo

L3 Backends

Iron Dome auto-detects the best available backend:

Backend Platform Mechanism Isolation Level Enforcement
seccomp-bpf Linux Kernel syscall filtering via libseccomp (ctypes), fork+exec syscall_policy moderate
seatbelt macOS sandbox-exec with generated profile DSL os_policy_enforced hard
subprocess Universal Process isolation with post-hoc pattern analysis observational_only best_effort

Important: The subprocess backend is observational only โ€” it detects suspicious patterns in output but does not prevent syscalls. It is not a true sandbox.

Important: The seccomp-bpf backend is a syscall policy harness, not a full containment boundary. It filters syscalls at the kernel level (real enforcement), but does not provide namespace/mount/filesystem isolation, prctl(PR_SET_NO_NEW_PRIVS), privilege dropping, or setrlimit. For safe execution of untrusted packages, compose with user namespaces, bubblewrap, or gVisor. Default-deny policies will kill processes on missing syscalls (e.g. clone3, wait4) โ€” use --allow-runtime node or the per-runtime profiles for common package managers, or use default-allow with explicit deny rules.

Use --backend seccomp-bpf (or IRONDOME_SANDBOX_BACKEND=seccomp-bpf) to require a specific backend. If the requested backend is unavailable, Iron Dome fails closed by default. Use --allow-degraded (or IRONDOME_ALLOW_DEGRADED=1) to opt into subprocess fallback explicitly.

L3 Suspicious Pattern Detectors

Rule Detects
L3-SUS-001 Dynamic code execution (eval, exec, compile)
L3-SUS-002 Shell execution (subprocess, os.system, os.popen)
L3-SUS-003 Sensitive file access (/etc/passwd, /etc/shadow)
L3-SUS-004 Network tool usage (curl, wget, nc, telnet)
L3-SUS-005 Permission escalation (chmod +x, chmod 777)
L3-SUS-006 Base64 decoding
L3-SUS-007 Destructive commands (rm -rf /, dd if=/dev)
L3-SUS-008 Process introspection (/proc/self, ptrace)
L3-SUS-009 SSH key access (.ssh/, id_rsa, id_ed25519)
L3-SUS-010 Dotfile access (/root/, /home/*/.)

L4 Behavioral Detector Rules

Rule Detects Severity
L4-TIME Anomalous timing, no-op, busy-wait MEDIUM/HIGH
L4-EXFIL Data exfiltration, suspicious DNS, credential theft CRITICAL/HIGH/MEDIUM
L4-ENTROPY High-entropy filenames, DGA domains MEDIUM/HIGH
L4-HONEY Honeypot path access, priv-esc binaries CRITICAL
L4-BASE Baseline drift from known-good profiles CRITICAL/MEDIUM/INFO

Shipped Baselines

  • npm-install โ€” npm install/publish behavior
  • python-pip-install โ€” pip install behavior
  • node-script โ€” Node.js script execution
  • python-script โ€” Python script execution
  • curl-wget โ€” Download utilities

Custom baselines can be loaded from JSON files.

Output Formats

Format Use Case
Table Human-readable terminal output with verdict icons
JSON Machine-readable, deterministic (sha256 repeatable)
SARIF 2.1.0 GitHub code scanning, VS Code, CI integration
ML Context Token-budgeted context for LLM pipelines
GitHub GitHub Actions annotation format
CycloneDX SBOM and vulnerability format for compliance

Determinism Guarantee

sha256(scan_a) == sha256(scan_b) on identical inputs. No random IDs in findings, no timestamps in evidence, frozen dataclasses throughout. Enforced by a 4-layer guard stack:

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  Layer 4: CI Gate                       โ”‚
โ”‚  --verify-determinism (CLI)             โ”‚
โ”‚  Runs scan twice, asserts SHA-256 match โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Layer 3: Diff                          โ”‚
โ”‚  irondome diff a.json b.json            โ”‚
โ”‚  Compare two saved scans field-by-field โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Layer 2: Guard (runtime)               โ”‚
โ”‚  Validates invariants after each scan:  โ”‚
โ”‚  - No uuid4/random in findings          โ”‚
โ”‚  - No timestamps in findings            โ”‚
โ”‚  - Findings sorted by sort_key()        โ”‚
โ”‚  - run_id is deterministic (empty)      โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Layer 1: Models (structural)           โ”‚
โ”‚  Finding(frozen=True), sorted keys,     โ”‚
โ”‚  no random IDs, no prose in output      โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Configuration

Iron Dome reads .irondome.yml or .irondome.yaml from the target directory:

version: 1
format: json
fail_on: high
deterministic_output: true
timeout: 30.0
severity_overrides:
  L4-TIME: low
  L4-ENTROPY: info

Environment variables (IRONDOME_*) override config, and CLI flags override everything.

Security

  • Determinism vulnerability reporting: See SECURITY.md
  • Threat model: See docs/security/threat-model.md
  • Release integrity: Sigstore-signed releases with SLSA L3 provenance. See SLSA.md
  • Zero hard runtime dependencies: Only pyyaml (optional) and libseccomp (optional, system library)

Documentation

Development

pip install -e ".[dev]"
python -m pytest -v              # 295 tests
irondome sandbox echo ci-test   # Quick self-test
bash scripts/ci.sh              # Full CI: mypy, ruff, pytest, determinism

See CONTRIBUTING.md for the full development guide.

License

Business Source License 1.1 (BUSL-1.1) โ€” source-available; production use allowed except for competitive offerings. Commercial use that competes with KirkForge's paid products requires a separate commercial license. After 3 years, converts to Apache-2.0. See LICENSE, LICENSE-SUMMARY.md, and COMMERCIAL-LICENSE.md.

Related

  • PicoSentry โ€” Deterministic npm/pnpm supply-chain scanner (L2, 21 rules, 1390+ tests)
  • 55NDeep โ€” Codex verification and delegation plugin

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

picodome-0.5.0.tar.gz (295.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

picodome-0.5.0-py3-none-any.whl (218.9 kB view details)

Uploaded Python 3

File details

Details for the file picodome-0.5.0.tar.gz.

File metadata

  • Download URL: picodome-0.5.0.tar.gz
  • Upload date:
  • Size: 295.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for picodome-0.5.0.tar.gz
Algorithm Hash digest
SHA256 58cb5cf755913fda32daa5598f129126696495b89bae21a422eee27ee585cb11
MD5 e9cd45741e5f30900a64ff1b6d032993
BLAKE2b-256 e150af11fae726cc7ce853dbd997a253fa3a32b2922ee1cd753496bfecf7b729

See more details on using hashes here.

File details

Details for the file picodome-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: picodome-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 218.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for picodome-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7f3195b959d16a26ffe7a84d59cd7787cdaaa5fdd358f70afd475bbe97011513
MD5 b0082ba07ccbac080b6cbe159e2a5466
BLAKE2b-256 05dba99ae21761fc34305801149aac8ad15e839865e58a44b848789ed5e44c92

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page