109
The product contains protection mechanisms to restrict access to 'realdir/filename', but it constructs
pathnames using external input in the form of 'fakedir/../realdir/filename' that are not handled by
those mechanisms. This allows attackers to perform unauthorized actions against the targeted file.
Relationships
The table(s) below shows the weaknesses and high level categories that are related to this
weakness. These relationships are defined as ChildOf, ParentOf, MemberOr and give insight to
similar items that may exist at higher and lower levels of abstraction. In addition, relationships such
as PeerOf and CanAlsoBe are defined to show similar weaknesses that may want to be explored.
Relevant to the view "Research Concepts" (CWE-1000)
Nature Type ID Name Page
ChildOf 41 Improper Resolution of Path Equivalence 86
Applicable Platforms
Language : Not Language-Specific (Prevalence = Undetermined)
Common Consequences
Scope Impact Likelihood
Confidentiality
Integrity
Read Files or Directories
Modify Files or Directories
Potential Mitigations
Phase: Implementation
Strategy = Input Validation
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.
Observed Examples
Reference Description
CVE-2001-1152 Proxy allows remote attackers to bypass denylist restrictions and connect to
unauthorized web servers by modifying the requested URL, including (1) a //
(double slash), (2) a /SUBDIR/.. where the desired file is in the parentdir, (3)
a /./, or (4) URL-encoded characters.
https://www.cve.org/CVERecord?id=CVE-2001-1152
CVE-2000-0191 application check access for restricted URL before canonicalization
https://www.cve.org/CVERecord?id=CVE-2000-0191
CVE-2005-1366 CGI source disclosure using "dirname/../cgi-bin"
https://www.cve.org/CVERecord?id=CVE-2005-1366
MemberOf Relationships
This MemberOf relationships table shows additional CWE Catgeories and Views that reference this
weakness as a member. This information is often useful in understanding where a weakness fits
within the context of external information sources.
Nature Type ID Name Page
MemberOf 981 SFP Secondary Cluster: Path Traversal 888 2409
MemberOf 1404 Comprehensive Categorization: File Handling 1400 2529
Notes
Theoretical
This is a manipulation that uses an injection for one consequence (containment violation using
relative path) to achieve a different consequence (equivalence by alternate name).
CWE Version 4.14
CWE-58: Path Equivalence: Windows 8.3 Filename
CWE-58: Path Equivalence: Windows 8.3 Filename