Skip to content

Archive

Path Traversal

1 articles
Cybersecurity 04 Sep 2026 11 min read

Keep File Access Inside an Intended Directory

Applications often let a caller identify a file: download an invoice, open an exported report, read a template, or retrieve an uploaded document. The dangerous version of this design treats a caller-controlled path as if it were already a permitted file. A path can describe movement through a filesystem, not just a filename. If untrusted input is combined with an application directory without a reliable containment check, the resulting path may resolve somewhere outside that directory. A read operation can expose configuration or private data; a write or delete operation can have more serious consequences.