---
title: "CWE-56: Path Equivalence: 'filedir*' (Wildcard)"
url: https://radicalnotion.ai/cwe/cwe-56
type: cwe
description: "The product accepts path input in the form of asterisk wildcard ('filedir*') without appropriate validation, which can lead to ambiguous path resolution and allow an attacker to traverse the file system to unintended locations or access arbitrary files."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-56: Path Equivalence: 'filedir\*' (Wildcard)

- **Abstraction:** Variant
- **Structure:** Simple
- **Status:** Incomplete
- **CVEs with this as primary weakness:** 0
- **Of those, in CISA KEV:** 0
- **New in 2026:** 0
- **CWE catalog version:** 4.21

## Description

The product accepts path input in the form of asterisk wildcard ('filedir\*') without appropriate validation, which can lead to ambiguous path resolution and allow an attacker to traverse the file system to unintended locations or access arbitrary files.

## Modes of introduction

| Phase | Note |
| --- | --- |
| Implementation | - |

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Confidentiality, Integrity | Read Files or Directories, Modify Files or Directories | - |

## Potential mitigations

### Implementation (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

| CVE | Description |
| --- | --- |
| CVE-2004-0696 | List directories using desired path and "\*" |
| CVE-2002-0433 | List files in web server using "\*.ext" |

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-41](https://radicalnotion.ai/cwe/cwe-41) | Improper Resolution of Path Equivalence |
| Parent | [CWE-155](https://radicalnotion.ai/cwe/cwe-155) | Improper Neutralization of Wildcards or Matching Symbols |

## Taxonomy mappings

| Taxonomy | Entry | Id | Fit |
| --- | --- | --- | --- |
| PLOVER | filedir\* (asterisk / wildcard) | - | - |
| Software Fault Patterns | Path Traversal | SFP16 | - |

## Frequently asked questions

### What is CWE-56?

The product accepts path input in the form of asterisk wildcard ('filedir\*') without appropriate validation, which can lead to ambiguous path resolution and allow an attacker to traverse the file system to unintended locations or access arbitrary files.

### How do you prevent CWE-56?

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.

### What are the consequences of CWE-56?

Exploiting CWE-56 can lead to: Read Files or Directories, Modify Files or Directories.

Primary source: [MITRE CWE](https://cwe.mitre.org/data/definitions/56.html)

---

Source: [RadicalNotion.AI](https://radicalnotion.ai/cwe/cwe-56). Licensed CC BY-NC 4.0; attribute RadicalNotion.AI and link the source page when you reuse this data.
