Directory traversal is a security exploit within HTTP that enables an individual to access restricted files or directories and execute commands that are external to the Web server’s root directory. It is used to access restricted content or files on a Web server.
Directory traversal is also known as path traversal, . . / attack (dot dot slash attack), directory climbing and backtracking.
Techopedia explains Directory Traversal
Directory traversal is primarily a type of attack performed by a hacker or a cracker that induces the server to traverse to the parent directory or to expose server-specific controls. Directory traversal generally happens as a result of a lack of or insufficient validation within the code of the application hosted/executed on the Web server.
In a directory traversal, the hacker/cracker typically sends in an HTTP request with a series of ../, in order to traverse or climb to a parent directory. The application/server is unable to validate the input data from the Web browser and grants access to the internal and restricted directories and the data they contain. Once the cracker/hacker gains access to the parent directory, he or she can view, edit and delete files, or even execute specific commands.