Skip to content
uencoder

Directory Traversal

Directory traversal is a synonym for path traversal, using ../ to escape a restricted directory and access unintended files.

Purpose

To understand directory traversal attacks and their defenses; synonymous with path traversal.

Mechanism

../ sequences walk up the directory tree to reach restricted files. Defenses are the same as for path traversal: normalize the path then validate the prefix, use basename, chroot.

Use cases

  • File access control
  • Path security audit
  • Directory restriction

Related tools

References