Scan profiles

Path Traversal vulnerability

A path traversal attack (also known as directory traversal) aims to access files and directories stored outside the web root folder. By manipulating variables that reference files with “dot-dot-slash (../)” sequences and their variations or by using absolute file paths, it may be possible to access arbitrary files and directories stored on the file system, including application source code or configuration and critical system files.
It should be noted that access to files is limited by system operational access control (such as in the case of locked or in-use files on the Microsoft Windows operating system).
This attack is also known as “dot-dot-slash”, “directory traversal”, “directory climbing” and “backtracking”.

By default, the web application scan profile will include HID-3-5-10133, which provides two methods to find Path Traversal vulnerabilities.

Basic Method

  • Small Payload List of well-known files
  • Detection based on string matches in responses
  • If our plugin finds a Path Traversal vulnerability, it also tries to check if it could
    escalate that into a Local File Inclusion RCE (via Log Poisoning)

Advanced Method

Add the HID-3-0-10230 Directory traversal (Advanced Payloads) to the Web app scan profile, or import the Web scan - Advanced config.
The scan will first run the basic method and then run the advanced method

  • Big Payload List (increase in total scan duration)
  • Detection Based on response lengths (Possible False positives)

How do we combine Directory Traversal + Local File Inclusion?

  • Local File inclusion vulnerability: the resource is Loaded and Executed in the context of the current application.
    Impact: Possible Remote Code Execution
  • Directory traversal vulnerability: Only gives you the ability to read the resource.
    Impact: Information Disclosure
    We cover Remote File Inclusion vulnerability in a separate HID and replace the HID here