Skip to content
OpenAdvisories

Weakness (CWE)

CWE-23: Relative Path Traversal

Base Draft

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.

How to prevent it (3 mitigations)
  1. Implementation

    Assume 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 of acceptable values, missing or extra inputs, syntax, consistency across related fields, and conformance to business rules. As an example of business rule logic, "boat" may be syntactically valid because it only contains alphanumeric characters, but it is not valid if the input is only expected to contain colors such as "red" or "blue."

    Do not rely exclusively on looking for malicious or malformed inputs. This is likely to miss at least one undesirable input, especially if the code's environment changes. This can give attackers enough room to bypass the intended validation. However, denylists can be useful for detecting potential attacks or determining which inputs are so malformed that they should be rejected outright.

    When validating filenames, use stringent allowlists that limit the character set to be used. If feasible, only allow a single "." character in the filename to avoid weaknesses such as CWE-23, and exclude directory separators such as "/" to avoid CWE-36. Use a list of allowable file extensions, which will help to avoid CWE-434.

    Do not rely exclusively on a filtering mechanism that removes potentially dangerous characters. This is equivalent to a denylist, which may be incomplete (CWE-184). For example, filtering "/" is insufficient protection if the filesystem also supports the use of "\" as a directory separator. Another possible error could occur when the filtering is applied in a way that still produces dangerous data (CWE-182). For example, if "../" sequences are removed from the ".../...//" string in a sequential fashion, two instances of "../" would be removed from the original string, but the remaining characters would still form the "../" string.

  2. Implementation

    Inputs 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() in C) that produces the canonical version of the pathname, which effectively removes ".." sequences and symbolic links (CWE-23, CWE-59). This includes:

    - realpath() in C

    - getCanonicalPath() in Java

    - GetFullPath() in ASP.NET

    - realpath() or abs_path() in Perl

    - realpath() in PHP

  3. Operation

    Use 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].

Source: MITRE CWE-23

199 results · Clear filters · Feed

  • Medium 5.0

    SharePoint Products CopyMove before 2026-11-06 allows traversal. An authenticated SharePoint user with the necessary pe…

  • Medium 4.4

    FreeScout: Path Traversal in App Logs Viewer Exposes Arbitrary Local Files

    FreeScout is a self-hosted help desk and shared mailbox. Prior to 1.8.225, the administrator-only App Logs viewer accepts Laravel-encrypted folder and file parameters whose constructed path is checked only as a raw string. An administrator who also knows the …

  • Medium 6.9

    zt-zip: ZipUtil.unpack can change file permissions of output directory

    zt-zip is a Java library that provides convenience methods for ZIP archive manipulation. Prior to 1.18.1, ZipUtil.unpack(...) can apply stored ZIP-entry permissions to the extraction output directory when an entry name such as / or ./ resolves to that directo…

  • Medium 6.1

    Improper limitation of a pathname to a restricted directory in the deployment status component of the AWS Serverless MCP Server

    Improper limitation of a pathname to a restricted directory in the deployment status component of the AWS Serverless MCP Server (aws-serverless-mcp-server) before v0.2.1 might allow an actor who can influence the MCP agent to read the contents of JSON files o…

  • Medium 6.1

    sevenz-rust2: unchecked 7z entry paths permit traversal and absolute-path file overwrites

    sevenz-rust2 is a Rust-native 7z compressor and `decompress`or. Prior to 0.21.1, extracting an attacker-supplied 7z archive can write or overwrite files outside the destination directory. In `src/util/decompress.rs`, `decompress_impl` computes each destinatio…

  • Medium 6.5

    Moodle through 5.3.0, 5.2.4, 5.1.8, 5.0.11 and 4.5.15 Blackboard Import Path Traversal

    Moodle 5.3.0, 5.2.0 through 5.2.4, 5.1.0 through 5.1.8, 5.0.0 through 5.0.11, and through 4.5.15 contains a path traversal vulnerability in the Blackboard question import format. Teachers with question import or lesson edit rights can upload a crafted zip wit…

  • Medium 6.5

    PowerProtect Data Domain, Feature Release versions 7.7.1.0 through 8.7, LTS2024 release versions 7.13.1.0 through 7.13.…

  • Medium 5.3

    Roundcube Webmail before 1.6.20 and 1.7.x before 1.7.5 is affected by a path traversal vulnerability in the squirrelmai…

  • Medium 5.3

    Astral uv before 0.11.6 Arbitrary File Deletion via Wheel RECORD Entries

    Astral uv before 0.11.6 contains a path traversal vulnerability that allows attackers to delete arbitrary files by supplying wheels with relative traversal paths in RECORD entries. Attackers can craft a malicious wheel whose RECORD references files outside th…

  • Medium 4.7

    Windows Internet (wininet.dll) Tampering Vulnerability

    Relative path traversal in Windows Internet (wininet.dll) allows an authorized attacker to perform tampering locally.

  • Medium 6.5

    Windows libarchive Tampering Vulnerability

    Relative path traversal in Windows Libarchive allows an unauthorized attacker to perform tampering over a network.

  • Medium 4.3

    Satel Netco Design Relative Path Traversal

    Satel Netco Design versions prior to v2.1.7 contains a relative path traversal vulnerability in its data import functionality. An authenticated user with Viewer privileges could access file paths outside the intended directory and use observable application r…

  • Medium 6.5

    Apache Impala: Path traversal executes JARs outside trusted paths

    Path traversal of 'trusted_jar_paths' in Impala 4.5.2 allows an attacker-controlled JAR to be loaded via a relative path where the prefix matches a path specified in 'trusted_jar_paths'. The startup flag 'trusted_jar_paths' references URIs for loading files f…

  • Medium 6.5

    Backstage: Improper input validation in TechDocs static content requests

    Backstage is an open framework for building developer portals. Prior to 2.2.4, the @backstage/plugin-techdocs-backend package is affected by improper input validation in techdocs static content requests. When using the Azure Blob Storage provider, an authenti…

  • Medium 4.2

    In sftp in OpenSSH before 10.6, a server can trigger directory traversal (causing files to be written to unintended loc…

  • Medium 6.9

    Path Traversal in VMDK Extractor in OSV-SCALIBR

    A path traversal vulnerability (CWE-22) in the embedded VMDK filesystem extractor in Google OSV-SCALIBR versions 0.3.6 through 0.5.0 allows an attacker who controls the scan target to write arbitrary files to the host system. When scanning crafted VMDK images…

  • Medium 6.5

    Path traversal in Fleet Helm valuesFiles allows disclosure of files outside the bundle directory

    A user who can supply bundle content to a repository referenced by a GitRepo resource, for example through Git push access, or through permission to create or modify a GitRepo, can cause SUSE Rancher Fleet to read files from the filesystem of the environment …

  • Medium 5.3

    GitHacker: Path traversal in ref/hash parsing enables existence oracle and hex-fragment exfiltration via a malicious .git server

    GitHacker is a tool that restores Git repositories from exposed .git directories. In 1.1.7 and earlier, add_head_file_tasks parses an attacker-controlled ref path from .git/HEAD and joins unvalidated path segments onto temp_dst/.git/logs/, allowing a maliciou…

  • Medium 6.6

    An issue was discovered in Softing OPC UA C++ SDK through 6.20 and Softing Secure Integration Server through 1.22. By u…

  • Medium 4.3

    A directory Traversal vulnerability in DataEase before 1.18.10 allows a remote attacker to obtain sensitive information…

  • Medium 6.5

    Dell SCG 5.0 Appliance versions prior to 5.36.00.16 and Dell SCG 5.0 Application versions prior to 5.36.00.00, contains…

  • Medium 4.9

    Ragic|Enterprise Cloud Database - Arbitrary File Read

    The Enterprise Cloud Database developed by Ragic has an Arbitrary File Read vulnerability. Privileged remote attackers can exploit Relative Path Traversal to download arbitrary system files.

  • Medium 5.3

    Source controller: Improper path handling allows traversal

    The source-controller is a Kubernetes operator, specialised in artifacts acquisition from external sources such as Git, OCI, Helm repositories and S3-compatible buckets. In versions 0.0.17 through 1.8.4, an actor with the ability to influence the contents of …

  • Medium 6.7

    Windows DNS Elevation of Privilege Vulnerability

    Relative path traversal in Windows DNS allows an authorized attacker to elevate privileges locally.

  • Medium 5.5
    CVE-2026-60093 Public exploit

    Apache Camel: Camel-Azure-Storage-DataLake: the downloadToFile operation built the local download target from the remote path name without constraining it to the configured fileDir

    Relative path traversal vulnerability in Apache Camel Azure-Storage Datalake component This issue affects Apache Camel: from 4.0.0 before 4.14.9, from 4.15.0 before 4.18.4, from 4.19.0 before 4.22.0. The camel-azure-storage-datalake component can download an …

  • Medium 6.7
    CVE-2026-77113 Public exploit

    Path Traversal Vulnerability in apport-unpack

    Path traversal in apport-unpack in Canonical Apport before 2.36.0, 2.34.2, and 2.28.4 on Linux allows an attacker to create or overwrite arbitrary files with the privileges of the executing user via an attacker controlled key names in crash report files.

  • Medium 6.5

    Microsoft SharePoint Server Information Disclosure Vulnerability

    Relative path traversal in Microsoft Office SharePoint allows an authorized attacker to disclose information over a network.

  • Medium 6.9

    Relative path traversal in Samsung Health prior to version 7.0.0 allows local attackers to access sensitive information.

  • Medium 6.5
  • Medium 6.5

    Vacron|IP Camera - Arbitrary File Read

    VIN-DS783E-E6 developed by Vacron has an Arbitrary File Read vulnerability, allowing authenticated remote attackers to exploit Relative Path Traversal to download arbitrary system files.

  • Medium 5.1

    Path Traversal in Quick.CMS

    A Path Traversal vulnerability exists in Quick.CMS through the URI path component of HTTP requests, where the server fails to normalize dot-dot-slash (../) sequences before resolving and serving the requested file. An authenticated attacker with admin privile…

  • Medium 4.8

    Relative path traversal in zip:unzip/zip:extract via check_dir_level depth-counter bypass

    Relative Path Traversal vulnerability in Erlang OTP (stdlib zip module) allows writing files outside the intended extraction directory via a crafted zip archive. zip:unzip/1,2 and zip:extract/1,2 validate entry paths using zip:check_dir_level/2, which tracks …

  • Medium 6.5

    Network-AI: AgentRuntime sandbox path-prefix checks allow file access outside the configured base directory

    Network-AI is a TypeScript/Node.js multi-agent orchestrator. Prior to version 5.12.2, `AgentRuntime` promises scoped file access under a configured sandbox `basePath`, but its path containment checks use raw string prefix tests. A sandbox base such as `/tmp/n…

  • Medium 6.1

    EnvironmentManager.restore() backup ID path traversal copies arbitrary directories into environment data

    Network-AI is a TypeScript/Node.js multi-agent orchestrator. Prior to version 5.12.2, `EnvironmentManager.restore(env, backupId)` computes the backup path with `join(envDir, '.backups', backupId)` and only checks that this path exists. It does not resolve the…

  • Medium 6.5

    Directory Traversal vulnerability in FileThingie v.2.5.7 allows a remote attacker to obtain sensitive information via a…

  • Medium 5.5

    Path traversal and arbitrary file write in the workflow linters of aws-healthomics-mcp-server

    AWS HealthOmics is a HIPAA-eligible service that fully manages the compute, storage, and workflow engine infrastructure required to run bioinformatics analyses at scale for clinical diagnostics, drug discovery, and agricultural research. Improper limitation o…

  • Medium 6.8

    File Browser: Archive builder turns backslash filenames into path traversal (zip-slip)

    File Browser is a file managing interface for uploading, deleting, previewing, renaming, and editing files within a specified directory. From 2.63.6 to 2.63.16, File Browser's archive builder uses strings.ReplaceAll(nameInArchive, "\", "/"), which turns a POS…

  • Medium 6.8

    Windows DNS Server Remote Code Execution Vulnerability

    Relative path traversal in DNS Server allows an authorized attacker to execute code over an adjacent network.

  • Medium 6.5

    Mockoon: Path traversal in templated `filePath` lets a request escape the served directory (prefix-only base check)

    Mockoon provides way to design and run mock APIs. Prior to 9.7.0, a FILE response whose filePath embeds request data is confined by getSafeFilePath in packages/commons-server/src/libs/server/server.ts with resolvedPath.startsWith(staticBaseDir). That prefix t…

  • Medium 4.5

    Authenticated Path Traversal allows MOVEit admins to view arbitrary system files

    Relative path traversal vulnerability in Progress MOVEit Transfer (Admin Settings module). This issue affects MOVEit Transfer: before 2025.0.7, from 2025.1.0 before 2025.1.3.