CWE
Home > CWE List > CWE-150 Individual Dictionary Definition (Draft 9)   View the CWE List

CWE-150 Individual Dictionary Definition (Draft 9)

Failure to Sanitize Escape, Meta, or Control Sequences
Weakness ID
Status: Incomplete

150 (Weakness Variant)

Description

Summary

Escape, meta, or control character/sequence injected into an application through input can be used to compromise a system. as data is parsed, injected/absent/malformed escape, meta, or control characters/sequences may cause the process to take unexpected actions that result in an attack.

Potential Mitigations

Developers should anticipate that escape, meta and control characters/sequences will be injected/removed/manipulated in the input vectors of their software system. Use an appropriate combination of black lists and white lists to ensure only valid, expected and appropriate input is processed by the system.

Observed Examples
ReferenceDescription
CVE-2002-0542Mail program handles special "~" escape sequence even when not in interactive mode.
CVE-2000-0703Setuid program does not filter escape sequences before calling mail program.
CVE-2002-0986Mail function does not filter control characters from arguments, allowing mail message content to be modified.
CVE-2003-0020Multi-channel issue. Terminal escape sequences not filtered from log files.
CVE-2003-0083Multi-channel issue. Terminal escape sequences not filtered from log files.
CVE-2003-0021Terminal escape sequences not filtered by terminals when displaying files.
CVE-2003-0022Terminal escape sequences not filtered by terminals when displaying files.
CVE-2003-0023Terminal escape sequences not filtered by terminals when displaying files.
CVE-2003-0063Terminal escape sequences not filtered by terminals when displaying files.
CVE-2000-0476Terminal escape sequences not filtered by terminals when displaying files.
CVE-2001-1556MFV. (multi-channel). Injection of control characters into log files that allow information hiding when using raw Unix programs to read the files.
Relationships
NatureTypeIDName
ChildOfWeakness ClassWeakness ClassWeakness Class138Failure to Sanitize Special Elements
Source Taxonomies

PLOVER - Escape, Meta, or Control Character / Sequence

Applicable Platforms

All

Related Attack Patterns
CAPEC-IDAttack Pattern Name
81Web Logs Tampering
93Log Injection-Tampering-Forging
41Using Meta-characters in E-mail Headers to Inject Malicious Payloads
Page Last Updated: April 21, 2008