CWE-96—Improper Neutralization of Directives in Statically Saved Code ('Static Code Injection')
PUBLISHEDweakness record
released 2006-07-19 · last modified 2025-12-11
Metadata
- CWE ID:
- CWE-96
- 摘要:
- Base
- 结构:
- Simple
- 状态:
- Draft
- 发布日期:
- 2006-07-19
- 更新日期:
- 2025-12-11
名称
Improper Neutralization of Directives in Statically Saved Code ('Static Code Injection')
描述
The product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes code syntax before inserting the input into an executable resource, such as a library, configuration file, or template.
常见后果
- 范围:
- Confidentiality
- 影响:
- Read Files or Directories, Read Application Data
- 注释:
- The injected code could access restricted data / files.
- 范围:
- Access Control
- 影响:
- Bypass Protection Mechanism
- 注释:
- In some cases, injectable code controls authentication; this may lead to a remote vulnerability.
- 范围:
- Access Control
- 影响:
- Gain Privileges or Assume Identity
- 注释:
- Injected code can access resources that the attacker is directly prevented from accessing.
- 范围:
- Integrity, Confidentiality, Availability, Other
- 影响:
- Execute Unauthorized Code or Commands
- 注释:
- Code injection attacks can lead to loss of data integrity in nearly all cases as the control-plane data injected is always incidental to data recall or writing. Additionally, code injection can often result in the execution of arbitrary code.
- 范围:
- Non-Repudiation
- 影响:
- Hide Activities
- 注释:
- Often the actions performed by injected control code are unlogged.