CWE-22: Improper Limitation of a Pathname to a Restricted Directory (Path traversal), published in 2021, page 2
Filter
The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.
What the weakness is: CWE-22 at MITRE. OWASP Top 10: A01:2025 Broken Access Control. All weaknesses
Related attack patterns (CAPEC): 5
- CAPEC-64 Using Slashes and URL Encoding Combined to Bypass Validation Logic Likelihood: High · Severity: High
- CAPEC-76 Manipulating Web Input to File System Calls Likelihood: High · Severity: Very High
- CAPEC-78 Using Escaped Slashes in Alternate Encoding Likelihood: High · Severity: High
- CAPEC-79 Using Slashes in Alternate Encoding Likelihood: High · Severity: High
- CAPEC-126 Path Traversal Likelihood: High · Severity: Very High
The attack patterns MITRE's CAPEC relates to CWE-22, as MITRE names them. Credits.
Ask an AI about CWE-22
Show the prompt
Explain CWE-22: Improper Limitation of a Pathname to a Restricted Directory and how to prevent and detect it in code. Use https://cwe.mitre.org/data/definitions/22.html and https://cve.bz/cve/cwe/22?via=ask-ai-copy for recent CVEs with this weakness. Cite the sources.Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this weakness's id and public links.
By year: all 2026 2025 2024 2023 2022 2021
- 7.5CVE-2021-43800requarks wiki.jsEPSS 1.8%
Wiki.js is a wiki app built on Node.js. Prior to version 2.5.254, directory traversal outside of Wiki.js context is possible when a storage module with local asset cache fetching is enabled on a Windows host. A malicious user can potential…
- 9.8CVE-2021-43676swoole php frameworkEPSS 1.4%
matyhtf framework v3.0.5 is affected by a path manipulation vulnerability in Smarty.class.php.
- 9.8CVE-2021-44278librenmsEPSS 1.5%
Librenms 21.11.0 is affected by a path manipulation vulnerability in includes/html/pages/device/showconfig.inc.php.
- 9.8CVE-2021-43674thinkupapp thinkupEPSS 1.4%
ThinkUp 2.0-beta.10 is affected by a path manipulation vulnerability in Smarty.class.php. NOTE: This vulnerability only affects products that are no longer supported by the maintainer
- 7.5CVE-2021-43795linecorp armeriaEPSS 1.7%
Armeria is an open source microservice framework. In affected versions an attacker can access an Armeria server's local file system beyond its restricted directory by sending an HTTP request whose path contains `%2F` (encoded `/`), such as…
- 7.5CVE-2021-43358sun ehrdEPSS 2.4%
Sunnet eHRD has inadequate filtering for special characters in URLs, which allows a remote attacker to perform path traversal attacks without authentication, access restricted paths and download system files.
- 5.0CVE-2021-43788nodebbEPSS 26%
Nodebb is an open source Node.js based forum software. Prior to v1.18.5, a path traversal vulnerability was present that allowed users to access JSON files outside of the expected `languages/` directory. The vulnerability has been patched …
- 8.5CVE-2021-43783linuxfoundation backstageEPSS 1.2%
@backstage/plugin-scaffolder-backend is the backend for the default Backstage software templates. In affected versions a malicious actor with write access to a registered scaffolder template is able to manipulate the template in a way that…
- 9.8CVE-2021-43691tripexpress project tripexpressEPSS 1.6%
tripexpress v1.1 is affected by a path manipulation vulnerability in file system/helpers/dompdf/load_font.php. The variable src is coming from $_SERVER["argv"] then there is a path manipulation vulnerability.
- 5.3CVE-2021-32061s3scanner project s3scannerEPSS 1.6%
S3Scanner before 2.0.2 allows Directory Traversal via a crafted bucket, as demonstrated by a <Key>../ substring in a ListBucketResult element.
- 8.8CVE-2021-41279basercmsEPSS 1.6%
BaserCMS is an open source content management system with a focus on Japanese language support. In affected versions users with upload privilege may upload crafted zip files capable of path traversal on the host operating system. This is a…
- 7.5CVE-2021-43778glpi-project barcodeEPSS 52%
Barcode is a GLPI plugin for printing barcodes and QR codes. GLPI instances version 2.x prior to version 2.6.1 with the barcode plugin installed are vulnerable to a path traversal vulnerability. This issue was patched in version 2.6.1. As …
- 8.6CVE-2021-43775aimstack aimEPSS 1.9%
Aim is an open-source, self-hosted machine learning experiment tracking tool. Versions of Aim prior to 3.1.0 are vulnerable to a path traversal attack. By manipulating variables that reference files with “dot-dot-slash (../)” sequences and…
- 7.5CVE-2021-41281EPSS 1.6%
Synapse is a package for Matrix homeservers written in Python 3/Twisted. Prior to version 1.47.1, Synapse instances with the media repository enabled can be tricked into downloading a file from a remote server into an arbitrary directory. …
- 7.5CVE-2021-24644imagestowebp project images to webpEPSS 5.9%
The Images to WebP WordPress plugin before 1.9 does not validate or sanitise the tab parameter before passing it to the include() function, which could lead to a Local File Inclusion issue
- 6.5CVE-2021-37023huawei harmonyosEPSS 0.6%
There is a Improper Access Control vulnerability in Huawei Smartphone.Successful exploitation of this vulnerability will cause media files which can be reads and writes in non-distributed directories on any device on the network..
- 9.1CVE-2020-7882hancom anysign4pcEPSS 1.3%
Using the parameter of getPFXFolderList function, attackers can see the information of authorization certification and delete the files. It occurs because the parameter contains path traversal characters(ie. '../../../')
- 7.5CVE-2021-38146wipro holmesEPSS 12%
The File Download API in Wipro Holmes Orchestrator 20.4.1 (20.4.1_02_11_2020) allows remote attackers to read arbitrary files via absolute path traversal in the SearchString JSON field in /home/download POST data.
- 6.5CVE-2021-33491open-xchange ox app suiteEPSS 2.5%
OX App Suite through 7.10.5 allows Directory Traversal via ../ in an OOXML or ODF ZIP archive, because of the mishandling of relative paths in mail addresses in conjunction with auto-configuration DNS records.
- 7.8CVE-2021-43555myscada mydesignerEPSS 38%
mySCADA myDESIGNER Versions 8.20.0 and prior fails to properly validate contents of an imported project file, which may make the product vulnerable to a path traversal payload. This vulnerability may allow an attacker to plant files on the…
- 9.1CVE-2021-22028greenplumEPSS 2.4%
In versions of Greenplum database prior to 5.28.6 and 6.14.0, greenplum database contains a file path traversal vulnerability leading to information disclosure from the file system. A malicious user can read/write information from the file…
- 4.3CVE-2021-37938elastic kibanaEPSS 0.7%
It was discovered that on Windows operating systems specifically, Kibana was not validating a user supplied path, which would load .pbf files. Because of this, a malicious user could arbitrarily traverse the Kibana host to load internal fi…
- 7.5CVE-2021-41277metabaseKEVEPSS 97%
Metabase is an open source data analytics platform. In affected versions a security issue has been discovered with the custom GeoJSON map (`admin->settings->maps->custom maps->add a map`) support and potential local file inclusion (includi…
- 7.5CVE-2021-40745adobe campaignEPSS 3.7%
Adobe Campaign version 21.2.1 (and earlier) is affected by a Path Traversal vulnerability that could lead to reading arbitrary server files. By leveraging an exposed XML file, an unauthenticated attacker can enumerate other files on the se…
- 9.1CVE-2021-41950montala resourcespaceEPSS 75%
A directory traversal issue in ResourceSpace 9.6 before 9.6 rev 18277 allows remote unauthenticated attackers to delete arbitrary files on the ResourceSpace server via the provider and variant parameters in pages/ajax/tiles.php. Attackers …
- 7.5CVE-2021-43495alquistai alquistEPSS 9.2%
AlquistManager branch as of commit 280d99f43b11378212652e75f6f3159cde9c1d36 is affected by a directory traversal vulnerability in alquist/IO/input.py. This attack can cause the disclosure of critical secrets stored anywhere on the system a…
- 7.5CVE-2021-43493servermanagement project servermanagementEPSS 2.5%
ServerManagement master branch as of commit 49491cc6f94980e6be7791d17be947c27071eb56 is affected by a directory traversal vulnerability. This vulnerability can be used to extract credentials which can in turn be used to execute code.
- 7.5CVE-2021-43492alquistai alquistEPSS 4.2%
AlquistManager branch as of commit 280d99f43b11378212652e75f6f3159cde9c1d36 is affected by a directory traversal vulnerability. This attack can cause the disclosure of critical secrets stored anywhere on the system andcan significantly aid…
- 7.5CVE-2021-43496clustering project clusteringEPSS 16%
Clustering master branch as of commit 53e663e259bcfc8cdecb56c0bb255bd70bfcaa70 is affected by a directory traversal vulnerability. This attack can cause the disclosure of critical secrets stored anywhere on the system and can significantly…
- 7.5CVE-2021-43494codingforentrepreneurs opencv rest apiEPSS 3.3%
OpenCV-REST-API master branch as of commit 69be158c05d4dd5a4aff38fdc680a162dd6b9e49 is affected by a directory traversal vulnerability. This attack can cause the disclosure of critical secrets stored anywhere on the system and can signific…
- 9.0CVE-2021-34422keybaseEPSS 1.4%
The Keybase Client for Windows before version 5.7.0 contains a path traversal vulnerability when checking the name of a file uploaded to a team folder. A malicious user could upload a file to a shared folder with a specially crafted file n…
- 9.8CVE-2021-3907EPSS 4.1%
OctoRPKI does not escape a URI with a filename containing "..", this allows a repository to create a file, (ex. rsync://example.org/repo/../../etc/cron.daily/evil.roa), which would then be written to disk outside the base cache folder. Thi…
- 6.5CVE-2021-22870github enterprise serverEPSS 1.1%
A path traversal vulnerability was identified in GitHub Pages builds on GitHub Enterprise Server that could allow an attacker to read system files. To exploit this vulnerability, an attacker would need permission to create and build a GitH…
- 7.5CVE-2021-42021siemensEPSS 1.7%
A vulnerability has been identified in Siveillance Video DLNA Server (2019 R1), Siveillance Video DLNA Server (2019 R2), Siveillance Video DLNA Server (2019 R3), Siveillance Video DLNA Server (2020 R1), Siveillance Video DLNA Server (2020 …
- 7.7CVE-2021-40359siemensEPSS 1.2%
A vulnerability has been identified in OpenPCS 7 V8.2 (All versions), OpenPCS 7 V9.0 (All versions < V9.0 Upd4), OpenPCS 7 V9.1 (All versions), SIMATIC BATCH V8.2 (All versions), SIMATIC BATCH V9.0 (All versions), SIMATIC BATCH V9.1 (All v…
- 9.9CVE-2021-40358siemensEPSS 1.3%
A vulnerability has been identified in SIMATIC PCS 7 V8.2 (All versions), SIMATIC PCS 7 V9.0 (All versions < V9.0 SP3 UC04), SIMATIC PCS 7 V9.1 (All versions < V9.1 SP1), SIMATIC WinCC V15 and earlier (All versions < V15 SP1 Update 7), SIM…
- 7.5CVE-2021-3924getgrav gravEPSS 4.4%
grav is vulnerable to Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
- 6.5CVE-2021-3916bookstackapp bookstackEPSS 1.2%
bookstack is vulnerable to Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
- 7.5CVE-2021-21698jenkins subversionEPSS 2.1%
Jenkins Subversion Plugin 2.15.0 and earlier does not restrict the name of a file when looking up a subversion key file on the controller from an agent.
- 9.8CVE-2021-21692jenkinsEPSS 2.1%
FilePath#renameTo and FilePath#moveAllChildrenTo in Jenkins 2.318 and earlier, LTS 2.303.2 and earlier only check 'read' agent-to-controller access permission on the source path, instead of 'delete'.
- 9.8CVE-2021-21690jenkinsEPSS 2.5%
Agent processes are able to completely bypass file path filtering by wrapping the file operation in an agent file path in Jenkins 2.318 and earlier, LTS 2.303.2 and earlier.
- 4.3CVE-2021-34701ciscoEPSS 1.6%
A vulnerability in the web-based management interface of Cisco Unified Communications Manager (Unified CM), Cisco Unified Communications Manager Session Management Edition (Unified CM SME), Cisco Unified Communications Manager IM & Pre…
- 6.5CVE-2021-34594beckhoffEPSS 1.1%
TwinCAT OPC UA Server in TF6100 and TS6100 in product versions before 4.3.48.0 or with TcOpcUaServer versions below 3.2.0.194 are prone to a relative path traversal that allow administrators to create or delete any files on the system.
- 7.5CVE-2021-33800alibaba druidEPSS 1.5%
In Druid 1.2.3, visiting the path with parameter in a certain function can lead to directory traversal.
- 3.3CVE-2021-43264maharaEPSS 0.6%
In Mahara before 20.04.5, 20.10.3, 21.04.2, and 21.10.0, adjusting the path component for the page help file allows attackers to bypass the intended access control for HTML files via directory traversal. It replaces the - character with th…
- 7.5CVE-2020-18438phpokEPSS 1.7%
Directory traversal vulnerability in qinggan phpok 5.1, allows attackers to disclose sensitive information, via the title parameter to admin.php.
- 9.8CVE-2021-29212hp ilo amplifier packEPSS 7.3%
A remote unauthenticated directory traversal security vulnerability has been identified in HPE iLO Amplifier Pack versions 1.80, 1.81, 1.90 and 1.95. The vulnerability could be remotely exploited to allow an unauthenticated user to run arb…
- 5.5CVE-2020-25881ranko rkcmsEPSS 1.2%
A vulnerability was discovered in the filename parameter in pathindex.php?r=cms-backend/attachment/delete&sub=&filename=../../../../111.txt&filetype=image/jpeg of the master version of RKCMS. This vulnerability allows for an attacker to pe…
- 6.5CVE-2020-25873baijiacms project baijiacmsEPSS 1.2%
A directory traversal vulnerability in the component system/manager/class/web/database.php was discovered in Baijiacms V4 which allows attackers to arbitrarily delete folders on the server via the "id" parameter.
- 4.9CVE-2020-25872frogcms project frogcmsEPSS 1.2%
A vulnerability exists within the FileManagerController.php function in FrogCMS 0.9.5 which allows an attacker to perform a directory traversal attack via a GET request urlencode parameter.