CWE-829: Inclusion of Functionality from Untrusted Control Sphere

BaseIncomplete

The product imports, requires, or includes executable functionality (such as a library) from a source that is outside of the intended control sphere.

View on MITRE
Back to CWE Lookup

Extended Description

When including third-party functionality, such as a web widget, library, or other source of functionality, the product must effectively trust that functionality. Without sufficient protection mechanisms, the functionality could be malicious in nature (either by coming from an untrusted source, being spoofed, or being modified in transit from a trusted source). The functionality might also contain its own weaknesses, or grant access to additional functionality and state information that should be kept private to the base system, such as system state information, sensitive application data, or the DOM of a web application. This might lead to many different consequences depending on the included functionality, but some examples include injection of malware, information exposure by granting excessive privileges or permissions to the untrusted functionality, DOM-based XSS vulnerabilities, stealing user's cookies, or open redirect to malware (CWE-601).

Technical Details

Structure
Simple

Applicable To

Languages
Platforms

Frequently Asked Questions

What is CWE-829: Inclusion of Functionality from Untrusted Control Sphere?+

CWE-829: Inclusion of Functionality from Untrusted Control Sphere is a Common Weakness Enumeration (CWE) entry maintained by MITRE. The product imports, requires, or includes executable functionality (such as a library) from a source that is outside of the intended control sphere. When including third-party functionality, such as a web widget, library, or other source of functionality, the product must effectively trust that functionality. Without sufficient protection mechanisms, the functionality could be malicious in nature (either by coming from an untrusted source, being spoofed, or being modified in transit from a trusted source). The functionality might also contain its own weaknesses, or grant access to additional functionality and state information that should be kept private to the base system, such as system state information, sensitive application data, or the DOM of a web application. This might lead to many different consequences depending on the included functionality, but some examples include injection of malware, information exposure by granting excessive privileges or permissions to the untrusted functionality, DOM-based XSS vulnerabilities, stealing user's cookies, or open redirect to malware (CWE-601).

What are the security consequences of Inclusion of Functionality from Untrusted Control Sphere?+

If exploited, CWE-829 (Inclusion of Functionality from Untrusted Control Sphere) it can compromise Confidentiality, Integrity and Availability, leading to outcomes such as Execute Unauthorized Code or Commands.

How is Inclusion of Functionality from Untrusted Control Sphere detected?+

CWE-829 can be detected using Manual Static Analysis - Source Code and Architecture or Design Review. Combining automated tooling with manual review typically yields the best coverage.

What are real-world examples of Inclusion of Functionality from Untrusted Control Sphere?+

MITRE documents real CVEs mapped to CWE-829, including CVE-2010-2076, CVE-2004-0285, CVE-2004-0030, CVE-2004-0068 and CVE-2005-2157. You can look up the full details of each CVE, including CVSS scores and remediation guidance, on our CVE Lookup tool.

What is the difference between a CWE and a CVE?+

A CWE (Common Weakness Enumeration) like CWE-829 describes a category of software weakness — the underlying flaw type. A CVE (Common Vulnerabilities and Exposures) identifies a specific, real-world vulnerability in a particular product. In short, a CWE is the kind of mistake, and a CVE is an instance of that mistake being found in software.

Learn More