CVE-2002-1628

MEDIUM5.0/ 10.0
Share:
Published: December 31, 2002 at 05:00 AM
Modified: April 3, 2025 at 01:03 AM
Source: cve@mitre.org

Vulnerability Description

Directory traversal vulnerability in vote.cgi for Mike Spice Mike's Vote CGI before 1.3 allows remote attackers to write arbitrary files via .. (dot dot) sequences in the type parameter.

CVSS Metrics

Base Score
5.0
Severity
MEDIUM
Vector String
AV:N/AC:L/Au:N/C:N/I:P/A:N

Weaknesses (CWE)

NVD-CWE-Other
Source: nvd@nist.gov

AI Security Analysis

01 // Technical Summary

Mike's Vote CGI versions prior to 1.3 are vulnerable to a critical directory traversal attack, allowing remote attackers to overwrite arbitrary files on the server. This vulnerability could lead to complete system compromise and data exfiltration. Successful exploitation grants attackers the ability to execute arbitrary code with the privileges of the webserver process.

02 // Vulnerability Mechanism

Step 1: Payload Delivery: The attacker crafts a malicious HTTP request to vote.cgi, including a crafted type parameter. The type parameter is designed to contain .. sequences to traverse the directory structure. Step 2: Parameter Manipulation: The attacker sets the type parameter to a value like ../../../../etc/passwd or a path to a web shell file. Step 3: File Write: The vote.cgi script, due to the lack of input validation, uses the attacker-controlled type parameter to construct the file path. The script then attempts to write data (e.g., vote data or a malicious payload) to the specified path. Step 4: File Overwrite/Code Execution: If the attacker specifies a path to a critical system file (e.g., /etc/passwd) or a web shell file within the web server's document root, the attacker can overwrite the file. Overwriting /etc/passwd allows for user account creation and privilege escalation. Overwriting a web shell allows for arbitrary code execution.

03 // Deep Technical Analysis

The vulnerability stems from insufficient input validation within the vote.cgi script. Specifically, the script fails to properly sanitize the type parameter, which is used to determine the file path for writing vote data. By injecting .. (dot-dot) sequences into the type parameter, an attacker can manipulate the file path, escaping the intended directory and writing files to arbitrary locations on the server's filesystem. This lack of proper input validation allows for path traversal, leading to file overwrite and potential code execution. The root cause is a missing or inadequate check on the user-supplied input, allowing the attacker to control the file path. This is a classic example of a path traversal vulnerability.

CVE-2002-1628 - MEDIUM Severity (5) | Free CVE Database | 4nuxd