CWE-1474

Class Abstraction Level
Pillar — Highest-level weakness category
Class — Abstract, language-independent
Base — Specific enough to detect
Variant — Tied to specific technology
Compound — Requires multiple weaknesses
Incomplete MITRE CWE Status
Stable — Fully reviewed and complete
Draft — Under development, may change
Incomplete — Partially defined by MITRE
Deprecated — No longer recommended
Obsolete — Replaced by another CWE
Non-Equivalent Data Transformation

Description

The product parses or transforms data into another format, structure, or representation, but the newly-produced data is not semantically equivalent to the original data.

Consequences

Integrity, Other — Bypass Protection Mechanism, Unexpected State, Varies by Context

Mitigations

Phase: Architecture and Design, Implementation

Validate the transformed data against what was expected to be produced. If the data is complex and free-form with some "special elements" in them, consider re-parsing the output to ensure that it matches expectations.

Detection

Manual Analysis

Examine inputs that will be saved or otherwise processed, then look at how they are produced in output. Analyze outputs that are expected to be (1) unchanged from the inputs, or (2) changed in a controlled way. Consider analyzing the data to extract key elements, such as e-mail addresses or domain names, to ensure that they are consistent with the original input.

Automated Dynamic Analysis

Examine inputs that will be saved or otherwise processed, then look at how they are produced in output. Analyze outputs that are expected to be (1) unchanged from the inputs, or (2) changed in a controlled way. Consider analyzing the data to extract key elements, such as e-mail addresses or domain names, to ensure that they are consistent with the original input.