मुख्य सामग्री पर जाएँ
Skillpedia
एजेंट35k · #7813

detecting-container-escape-attempts

यह क्या करती है

यह tool पहचानने में मदद करता है कि कोई व्यक्ति या program अलग-थलग container से बाहर निकलकर मुख्य system या दूसरे containers तक पहुँचने की कोशिश कर रहा है या नहीं। यह system में छेड़छाड़, permissions के गलत इस्तेमाल और संवेदनशील files तक पहुँच जैसी संदिग्ध गतिविधियों पर नज़र रखता है।

कब इस्तेमाल करें

  • ✓किसी संभावित container escape हमले की जाँच करते समय।
  • ✓escape प्रयासों पर नज़र रखने के लिए system सेट करते समय।
  • ✓यह देखने के लिए कि security में ज्ञात escape तकनीकें कवर हो रही हैं या नहीं।

Skill का लिंक

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-container-escape-attempts/SKILL.md

इसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।

कैसे इस्तेमाल करें

सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।

पेस्ट करने के लिए तैयार मैसेज

इस skill से मेरी मदद करो: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-container-escape-attempts/SKILL.md इस लिंक की SKILL.md फ़ाइल पढ़ो और मेरे काम में उसके निर्देशों का पालन करो।
क्या आप चाहते हैं कि आपका AI ऐसी skills खुद ढूँढे?मुफ़्त Skillpedia MCP इंस्टॉल करें: बस एक लाइन, और हर काम से पहले यह 15,000+ skills में खोजता है।1 मिनट में इंस्टॉल करें →

AI से क्या माँगें: उदाहरण

“पता लगाओ कि कोई container Docker socket तक पहुँचने की कोशिश तो नहीं कर रहा।”

हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।

यह कैसे काम करती है

यह containers के अंदर system calls और process गतिविधियों पर नज़र रखकर काम करता है। अगर कुछ असामान्य दिखता है, जैसे host system की files तक पहुँचने की कोशिश, तो alert जनरेट होता है।

तकनीकी सामग्री (मूल SKILL.md)

लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।

Detecting Container Escape Attempts

Overview

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.

When to Use

  • When investigating security incidents that require detecting container escape attempts
  • When building detection rules or threat hunting queries for this domain
  • When SOC analysts need structured procedures for this analysis type
  • When validating security monitoring coverage for related attack techniques

Prerequisites

  • Linux host with kernel 5.10+ (eBPF support)
  • Falco 0.37+ installed (kernel module or eBPF probe)
  • Docker Engine or containerd runtime
  • auditd configured
  • Root access for eBPF/kernel module loading

Core Concepts

Common Container Escape Vectors

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

Detection Layers

  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

Workflow

Step 1: Deploy Falco for Runtime Detection

# 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

Step 2: Custom Falco Rules for Escape Detection

# /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

…
अक्सर पूछे जाने वाले सवाल

Container escape क्या है?

जब कोई attacker container के अलग-थलग environment से बाहर निकलकर उस system या दूसरे containers तक पहुँच जाता है, जिस पर container चल रहा है।

इसमें कौन से tools इस्तेमाल होते हैं?

Falco, Sysdig, auditd और EDRs (Endpoint Detection and Response) जैसे tools ज़रूरी डेटा इकट्ठा करने में इस्तेमाल हो सकते हैं।

क्या इसे इस्तेमाल करने के लिए advanced technical knowledge चाहिए?

यह tool इन घटनाओं को समझने और जाँचने में मदद के लिए बनाया गया है, लेकिन monitoring tools को शुरू में सेट अप करने के लिए तकनीकी जानकारी की ज़रूरत पड़ सकती है।

जानकारी

लेखक का मूल विवरण

Detects container escape at runtime across tooling - namespace manipulation, capability abuse, kernel exploits, sensitive host mounts, and anomalous syscalls - and explains which signals matter regardless of whether Falco, Sysdig, auditd, or an EDR is doing the collection. Use when deciding what breakout behaviour to monitor, investigating a suspected Docker or Kubernetes breakout, or comparing es

repo: mukul975/Anthropic-Cybersecurity-Skills

लोकप्रियता

GitHub स्टार
35k
रैंकिंग में स्थान
#7813
लाइसेंस
Apache-2.0
अपडेट की गई
31/8/2026

क्या यह skill काम की है?

0

लॉग इन करें वोट करने के लिए।

कमेंट

  • …

इस repository की और skills

मिलती-जुलती skills