acquiring-disk-image-w…
Create forensically sound bit-for-bit disk images using dd and dcfldd while preserving evidence integrity through
Container escape is a critical attack technique where an adversary breaks out of container isolation to access
$ npx -y skills add Mikaru0Mystic/sectinel --skill detecting-container-escape-attempts --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/detecting-container-escape-attemptsContext preview
The summary Claude sees to decide when to auto-load this skill.
Container escape is a critical attack technique where an adversary breaks out of container isolation to access
name: detecting-container-escape-attempts description: Container escape is a critical attack technique where an adversary breaks out of container isolation to access the host system or other containers. Detection involves monitoring for escape indicators domain: cybersecurity subdomain: container-security tags: - containers - kubernetes - docker - security - runtime-security - escape-detection version: '1.0' author: mahipal license: Apache-2.0 d3fend_techniques: - Platform Monitoring - Process Code Segment Verification - Stack Frame Canary Validation - Segment Address Offset Randomization - Process Analysis nist_csf: - PR.PS-01 - PR.IR-01 - ID.AM-08 - DE.CM-01
Container escape is a critical attack technique where an adversary breaks out of container isolation to access the host system or other containers. Detection involves monitoring for escape indicators such as namespace manipulation, capability abuse, kernel exploits, mounted sensitive paths, and anomalous syscall patterns using runtime security tools like Falco, Sysdig, and custom seccomp/audit rules.
| Vector | Technique | MITRE ID | |--------|-----------|----------| | Privileged containers | Mount host filesystem, load kernel modules | T1611 | | Docker socket mount | Create privileged container from within | T1610 | | Kernel exploits | CVE-2022-0185 (fsconfig), Dirty Pipe, runc CVEs | T1068 | | Capability abuse | CAP_SYS_ADMIN, CAP_SYS_PTRACE, CAP_NET_ADMIN | T1548 | | Sensitive mounts | /proc/sysrq-trigger, /proc/kcore, cgroup release_agent | T1611 | | Namespace escape | nsenter, unshare to host namespaces | T1611 | | Symlink/bind mount | Escape through /proc/self/root | T1611 |
1. **Syscall monitoring** - eBPF/kernel module captures syscalls in real-time 2. **File integrity** - Detect modification of escape-enabling paths 3. **Process monitoring** - Track process creation, namespace changes 4. **Network monitoring** - Detect container-to-host connections 5. **Audit logging** - Linux auditd for capability and mount operations
# falco-values.yaml for Helm deployment
falco:
driver:
kind: ebpf # or modern_ebpf for kernel 5.8+
rules_files:
- /etc/falco/falco_rules.yaml
- /etc/falco/falco_rules.local.yaml
- /etc/falco/rules.d
json_output: true
json_include_output_property: true
http_output:
enabled: true
url: "http://falcosidekick:2801"
grpc:
enabled: true
priority: warning# Install Falco via Helm helm repo add falcosecurity https://falcosecurity.github.io/charts helm install falco falcosecurity/falco \ --namespace falco-system --create-namespace \ -f falco-values.yaml
# /etc/falco/rules.d/container_escape.yaml
# Detect container escape via privileged container
- rule: Container Escape via Privileged Mode
desc: Detect attempts to escape container using privileged capabilities
condition: >
spawned_process and container and
(proc.name in (nsenter, unshare, mount, umount, modprobe, insmod) or
(proc.name = chroot and proc.args contains "/host"))
output: >
Container escape attempt via privileged operation
(user=%user.name container=%container.name image=%container.image.repository
command=%proc.cmdline pid=%proc.pid %container.info)
priority: CRITICAL
tags: [container, escape, T1611]
# Detect Docker socket access from container
- rule: Container Access to Docker Socket
desc: Detect container reading/writing to Docker socket
condition: >
(open_read or open_write) and container and
fd.name = /var/run/docker.sock
output: >
Docker socket accessed from container
(user=%user.name container=%container.name image=%container.image.repository
fd=%fd.name command=%proc.cmdline %container.info)
priority: CRITICAL
tags: [container, escape, docker_socket]
# Detect sensitive proc filesystem access
- rule: Container Access to Sensitive Proc Paths
desc: Detect container accessing host-sensitive proc paths
condition: >
open_read and container and
(fd.name startswith /proc/sysrq-trigger or
fd.name startswith /proc/kcore or
fd.name startswith /proc/kmsg or
fd.name startswith /proc/kallsyms or
fd.name startswith /sys/kernel)
output: >
Sensitive proc/sys access from container
(user=%user.name container=%container.name path=%fd.name
command=%proc.cmdline %container.info)
priority: CRITICAL
tags: [container, escape, proc_access]
# Detect cgroup escape technique
- rule: Container Cgroup Escape Attempt
desc: Detect writing to cgroup release_agent (escape technique)
condition: >
open_write and container and
(fd.name contains release_agent or
fd.name contains notify_on_release)
output: >
Cgroup escape attempt detected
(user=%user.name container=%container.name path=%fd.name
command=%proc.cmdline %container.info)
priority: CRITICAL
tags: [container, escape, cgroup]
# Detect kernel module loading from container
- rule: Container Loading Kernel Module
desc: Detect container attempting to load kernel modules
condition: >
spawned_process and container and
(proc.name in (modprobe, insmod, rmmod) or
(evt.type = init_module or evtOpen-source security arsenal for AI coding agents: 784 cybersecurity skills, scanner integrations, and a security MCP for Claude Code, Cursor, opencode, Gemini CLI, Cline, and any agentskills.io agent. Mapped to OWASP, MITRE ATT&CK, NIST CSF, D3FEND, ATLAS.
Repo: Mikaru0Mystic/sectinel
Create forensically sound bit-for-bit disk images using dd and dcfldd while preserving evidence integrity through
Detect dangerous ACL misconfigurations in Active Directory using ldap3 to identify GenericAll, WriteDACL, and
Perform static analysis of Android APK malware samples using apktool for decompilation, jadx for Java source
Parses API Gateway access logs (AWS API Gateway, Kong, Nginx) to detect BOLA/IDOR attacks, rate limit bypass,
Analyze advanced persistent threat (APT) group techniques using MITRE ATT&CK Navigator to create layered heatmaps
Queries Azure Monitor activity logs and sign-in logs via azure-monitor-query to detect suspicious administrative