security vulnerability_error ai_generated true

Path traversal: ../../../etc/passwd

ID: security/path-traversal

Also available as: JSON · Markdown
85%Fix Rate
88%Confidence
3Evidence
2023-01-01First Seen

Version Compatibility

VersionStatusIntroducedDeprecatedNotes
any active

Root Cause

User input used in file path without sanitization.

generic

Workarounds

  1. 92% success Use path canonicalization and verify resolved path is within allowed directory
  2. 90% success Use allowlist of permitted file paths

Dead Ends

Common approaches that don't work:

  1. Filter ../ only 82% fail

    Bypassed with URL encoding or double encoding

  2. Use blocklist of sensitive files 78% fail

    Attacker targets unlisted files