Path Traversal

Hunt directory traversal and archive traversal (ZipSlip/TarSlip) from user input to filesystem operations.

purpleailab 2f46cef 715 B Updated

File contents

Path Traversal Playbook

Find sinks

  • open(user_path), send_file(user_path), file download endpoints, archive extraction APIs.

Probe payload classes

  • Relative traversal: ../../../../etc/passwd
  • Encoded traversal: %2e%2e%2f
  • Mixed separators: ..\\..\\windows\\win.ini
  • Archive traversal: entries like ../../app/config.py

Verify controls

  • Canonicalization done before allowlist check.
  • Path confinement to intended root.

Validation

Confirm unauthorized file read/write outside allowed directory with positive and negative controls.

purpleailab/decepticon/tree/main/packages/decepticon/decepticon/skills/standard/analyst/path-traversal commit 2f46cef0d1

Frequently asked questions

npx skillmds@latest add purpleailab/path-traversal