본문으로 건너뛰기
Skillpedia
에이전트35k · #7813

detecting-container-escape-attempts

하는 일

이 도구는 누군가 격리된 컨테이너를 벗어나 주 시스템이나 다른 컨테이너에 접근하려 할 때를 식별하도록 돕습니다. 시스템 조작, 권한 오용, 민감한 파일 접근 같은 의심스러운 활동을 모니터링합니다.

사용하는 경우

  • ✓잠재적인 컨테이너 탈출 공격을 조사할 때.
  • ✓탈출 시도를 모니터링하는 시스템을 설정할 때.
  • ✓보안이 알려진 탈출 기법을 막고 있는지 확인하는 경우.

스킬 링크

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

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-container-escape-attempts/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“컨테이너가 Docker 소켓에 접근하려 하는지 탐지해 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

도구는 컨테이너 안의 시스템 호출과 프로세스 활동을 모니터링해 작동합니다. 호스트 시스템 파일에 접근하려는 것처럼 특이한 것이 탐지되면 경고가 생성됩니다.

기술 내용 (원본 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)'이란 무엇인가요?

공격자가 컨테이너의 격리된 환경을 벗어나, 컨테이너가 실행되는 시스템이나 다른 컨테이너에 접근하는 것입니다.

어떤 도구가 사용되나요?

Falco, Sysdig, auditd, EDR(Endpoint Detection and Response) 같은 도구를 사용해 필요한 데이터를 수집할 수 있습니다.

이것을 사용하려면 고급 기술 지식이 필요한가요?

이 도구는 이런 이벤트를 이해하고 조사하도록 설계되었지만, 모니터링 도구의 초기 설정에는 기술 전문성이 필요할 수 있습니다.

상세 정보

작성자의 원본 설명

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
업데이트
2026. 8. 31.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬