Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CWE-23 (相对路径遍历) — Vulnerability Class 345

345 vulnerabilities classified as CWE-23 (相对路径遍历). AI Chinese analysis included.

CWE-23, Relative Path Traversal, is a critical input validation weakness where applications fail to properly sanitize user-supplied data before constructing file system paths. Attackers typically exploit this vulnerability by injecting directory traversal sequences, such as “../”, into input fields to manipulate the resulting pathname. This manipulation allows them to escape the intended restricted directory and access sensitive files located elsewhere on the server, potentially leading to unauthorized data disclosure or remote code execution. To mitigate this risk, developers must rigorously validate and neutralize all external inputs, ensuring they do not contain relative path components. Implementing strict allowlists for permitted characters, using canonicalization functions to resolve paths before access checks, and employing chroot jails or containerization to isolate file system access are essential defensive strategies that effectively prevent attackers from traversing outside the designated directory boundaries.

MITRE CWE Description
The product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize sequences such as ".." that can resolve to a location that is outside of that directory.
Common Consequences (4)
Integrity, Confidentiality, AvailabilityExecute Unauthorized Code or Commands
The attacker may be able to create or overwrite critical files that are used to execute code, such as programs or libraries.
IntegrityModify Files or Directories
The attacker may be able to overwrite or create critical files, such as programs, libraries, or important data. If the targeted file is used for a security mechanism, then the attacker may be able to bypass that mechanism. For example, appending a new account at the end of a password file may allow …
ConfidentialityRead Files or Directories
The attacker may be able read the contents of unexpected files and expose sensitive data by traversing the file system to access files or directories that are outside of the restricted directory. If the targeted file is used for a security mechanism, then the attacker may be able to bypass that mech…
AvailabilityDoS: Crash, Exit, or Restart
The attacker may be able to overwrite, delete, or corrupt unexpected critical files such as programs, libraries, or important data. This may prevent the product from working at all and in the case of a protection mechanisms such as authentication, it has the potential to lockout every user of the pr…
Mitigations (3)
ImplementationAssume all input is malicious. Use an "accept known good" input validation strategy, i.e., use a list of acceptable inputs that strictly conform to specifications. Reject any input that does not strictly conform to specifications, or transform it into something that does. When performing input validation, consider all potentially relevant properties, including length, type of input, the full range…
ImplementationInputs should be decoded and canonicalized to the application's current internal representation before being validated (CWE-180). Make sure that the application does not decode the same input twice (CWE-174). Such errors could be used to bypass allowlist validation schemes by introducing dangerous inputs after they have been checked. Use a built-in path canonicalization function (such as realpath(…
OperationUse an application firewall that can detect attacks against this weakness. It can be beneficial in cases in which the code cannot be fixed (because it is controlled by a third party), as an emergency prevention measure while more comprehensive software assurance measures are applied, or to provide defense in depth [REF-1481].
Effectiveness: Moderate
Examples (2)
The following URLs are vulnerable to this attack:
http://example.com/get-files.jsp?file=report.pdf http://example.com/get-page.php?home=aaa.html http://example.com/some-page.asp?page=index.html
Bad · Other
http://example.com/get-files?file=../../../../somedir/somefile http://example.com/../../../../etc/shadow http://example.com/get-files?file=../../../../etc/passwd
Attack · Other
The following code could be for a social networking application in which each user's profile information is stored in a separate file. All files are stored in a single directory.
my $dataPath = "/users/cwe/profiles"; my $username = param("user"); my $profilePath = $dataPath . "/" . $username; open(my $fh, "<", $profilePath) || ExitError("profile read error: $profilePath"); print "<ul>\n"; while (<$fh>) { print "<li>$_</li>\n"; } print "</ul>\n";
Bad · Perl
../../../etc/passwd
Attack
CVE IDTitleCVSSSeverityPublished
CVE-2024-11067 D-Link DSL6740C - Arbitrary File Reading through Path Traversal — DSL6740C 7.5 High2024-11-11
CVE-2024-50453 WordPress The Pack Elementor addons plugin <= 2.0.9 - Local File Inclusion vulnerability — The Pack Elementor addons 7.5 High2024-10-28
CVE-2024-10200 Wellchoose Administrative Management System - Arbitrary File Read through Path Traversal — Administrative Management System 7.5 High2024-10-21
CVE-2024-47637 WordPress LiteSpeed Cache plugin <= 6.4.1 - Path Traversal vulnerability — LiteSpeed Cache 8.8 High2024-10-16
CVE-2024-49253 WordPress Analyse Uploads plugin <= 0.5 - Arbitrary File Deletion vulnerability — Analyse Uploads 8.6 High2024-10-16
CVE-2024-9983 Ragic Enterprise Cloud Database - Arbitrary File Read through Path Traversal — Enterprise Cloud Database 7.5 High2024-10-15
CVE-2024-45731 Potential Remote Command Execution (RCE) through arbitrary file write to Windows system root directory when Splunk Enterprise for Windows is installed on a separate disk — Splunk Enterprise 8.0 High2024-10-14
CVE-2024-9923 TEAMPLUS TECHNOLOGY Team+ - Arbitrary File Move through Path Traversal — team+ 4.9 Medium2024-10-14
CVE-2024-9922 TEAMPLUS TECHNOLOGY Team+ - Arbitrary File Read through Path Traversal — team+ 7.5 High2024-10-14
CVE-2024-6985 Path Traversal in api open_personality_folder in parisneo/lollms-webui — parisneo/lollms 7.5AIHighAI2024-10-11
CVE-2024-43614 Microsoft Defender for Endpoint for Linux Spoofing Vulnerability — Microsoft Defender for Endpoint for Linux 5.5 Medium2024-10-08
CVE-2024-47948 JetBrains TeamCity 安全漏洞 — TeamCity 4.9 Medium2024-10-08
CVE-2024-47949 JetBrains TeamCity 安全漏洞 — TeamCity 4.9 Medium2024-10-08
CVE-2024-20449 Cisco Nexus Dashboard Fabric Controller Remote Code Execution Vulnerability — Cisco Data Center Network Manager 8.8 High2024-10-02
CVE-2024-9405 Pluck 安全漏洞 — Pluck CMS 5.3 Medium2024-10-01
CVE-2024-45816 Storage bucket Directory Traversal in @backstage/plugin-techdocs-backend — backstage 6.5 Medium2024-09-17
CVE-2024-43454 Windows Remote Desktop Licensing Service Remote Code Execution Vulnerability — Windows Server 2019 7.1 High2024-09-10
CVE-2024-38258 Windows Remote Desktop Licensing Service Information Disclosure Vulnerability — Windows Server 2019 6.5 Medium2024-09-10
CVE-2024-43399 Mobile Security Framework (MobSF) has a Zip Slip Vulnerability in .a Static Library Files — Mobile-Security-Framework-MobSF 8.0 High2024-08-19
CVE-2024-7693 Team Johnlong software Raiden MAILD Remote Management System - Arbitrary File Reading through Path Traversal — Raiden MAILD Remote Management System 7.5 High2024-08-12
CVE-2024-6433 Local File Inclusion in stitionai/devika — stitionai/devika 7.5AIHighAI2024-07-10
CVE-2024-3122 CHANGING Mobile One Time Password - Arbitrary File Reading — Mobile One Time Password 4.9 Medium2024-07-01
CVE-2024-5547 Directory Traversal in stitionai/devika — stitionai/devika 7.5AIHighAI2024-06-27
CVE-2024-37138 Dell PowerProtect Data Domain 安全漏洞 — PowerProtect DD 4.1 Medium2024-06-26
CVE-2024-3497 Directory Traversal Remote Code Execution Vulnerability — Toshiba Tec e-Studio multi-function peripheral (MFP) 8.8 High2024-06-14
CVE-2024-2461 Hitachi XMC20 安全漏洞 — FOX61x 7.5AIHighAI2024-06-11
CVE-2024-4330 Path Traversal in parisneo/lollms-webui — parisneo/lollms-webui 7.5AIHighAI2024-05-30
CVE-2024-36362 JetBrains TeamCity 安全漏洞 — TeamCity 6.5 Medium2024-05-29
CVE-2024-35186 gix traversal outside working tree enables arbitrary code execution — gitoxide 8.8 High2024-05-23
CVE-2023-3941 Multiple arbitrary file writes in ZkTeco-based OEM devices — ZkTeco-based OEM devices with firmware ZAM170-NF-1.8.25-7354-Ver1.0.0 10.0 Critical2024-05-21

Vulnerabilities classified as CWE-23 (相对路径遍历) represent 345 CVEs. The CWE taxonomy describes the weakness; review individual CVEs for product-specific impact.