CVE-2004-0235 in F-Secureinfo

Summary

by MITRE

Multiple directory traversal vulnerabilities in LHA 1.14 allow remote attackers or local users to create arbitrary files via an LHA archive containing filenames with (1) .. sequences or (2) absolute pathnames with double leading slashes ("//absolute/path").

Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Analysis

by VulDB Data Team • 06/30/2021

The vulnerability identified as CVE-2004-0235 represents a critical directory traversal flaw in LHA 1.14 archive utility software. This vulnerability exists within the file extraction mechanism of the LHA compression tool, which is widely used for handling compressed archives across various operating systems. The flaw manifests when processing specially crafted archive files that contain malicious filenames designed to exploit the underlying file system path resolution logic. Directory traversal vulnerabilities of this nature have been consistently categorized under CWE-22 by the Common Weakness Enumeration project, which specifically addresses improper limitation of a pathname to a restricted directory. The vulnerability affects both remote attackers who can exploit it through network-based archive delivery and local users who might manipulate archive files on the system.

The technical exploitation of this vulnerability occurs through two distinct but related attack vectors that leverage the way LHA handles filename parsing during archive extraction. The first vector involves the use of ".." sequences within filenames, which when processed by the archive utility can cause the extraction mechanism to navigate up the directory tree and create files in unintended locations outside the target extraction directory. The second vector exploits absolute pathnames that begin with double leading slashes "//absolute/path", which bypass normal path validation and allow attackers to specify arbitrary system paths for file creation. Both attack methods rely on the fundamental weakness in how the LHA utility resolves relative and absolute path references during the decompression process, effectively allowing privilege escalation and potential system compromise.

The operational impact of CVE-2004-0235 extends beyond simple file system manipulation and can lead to serious security consequences for affected systems. Attackers can leverage this vulnerability to overwrite critical system files, inject malicious code into system directories, or create backdoor access points within the file system. The vulnerability is particularly dangerous because it can be exploited through various attack surfaces including web-based file uploads, email attachments, or network file transfers where LHA archives are processed. The potential for privilege escalation exists when the archive extraction process runs with elevated permissions, and the ability to create arbitrary files in system directories can lead to complete system compromise. This vulnerability aligns with ATT&CK technique T1059.007 for execution through command-line interfaces and T1566 for initial access through spearphishing attachments, making it a significant threat vector in enterprise security environments.

Mitigation strategies for CVE-2004-0235 require both immediate and long-term approaches to address the root cause of the directory traversal vulnerability. Immediate remediation involves updating to a patched version of LHA software or implementing strict input validation on all archive files before processing. Organizations should implement network segmentation and access controls to limit the exposure of systems that process LHA archives, particularly those that handle untrusted input from external sources. The implementation of proper path validation routines that reject filenames containing ".." sequences or absolute paths with double leading slashes provides a robust defense against exploitation. Additionally, system administrators should conduct regular security audits to identify and remediate similar vulnerabilities in other archive handling utilities and ensure that file extraction processes run with minimal required privileges. The vulnerability demonstrates the importance of input sanitization and proper path resolution mechanisms, principles that are fundamental to secure coding practices and are reinforced by industry standards such as the OWASP Top Ten and NIST cybersecurity guidelines.

Reservation

03/17/2004

Disclosure

08/18/2004

Moderation

accepted

Entry

VDB-22119

CPE

ready

Exploit

Download

EPSS

0.04122

KEV

no

Activities

very low

Sources

Are you interested in using VulDB?

Download the whitepaper to learn more about our service!