Weakness ID: 942
Vulnerability Mapping: ALLOWED This CWE ID may be used to map to real-world vulnerabilitiesAbstraction: Variant Variant - a weakness that is linked to a certain type of product, typically involving a specific language or technology. More specific than a Base weakness. Variant level weaknesses typically describe issues in terms of 3 to 5 of the following dimensions: behavior, property, technology, language, and resource.
Description
The product uses a web-client protection mechanism such as a Content Security Policy (CSP) or cross-domain policy file, but the policy includes untrusted domains with which the web client is allowed to communicate.
Extended Description
If a cross-domain policy file includes domains that should not be trusted, such as when using wildcards under a high-level domain, then the application could be attacked by these untrusted domains. In many cases, the attack can be launched without the victim even being aware of it.
Common Consequences
This table specifies different individual consequences
associated with the weakness. The Scope identifies the application security area that is
violated, while the Impact describes the negative technical impact that arises if an
adversary succeeds in exploiting this weakness. The Likelihood provides information about
how likely the specific consequence is expected to be seen relative to the other
consequences in the list. For example, there may be high likelihood that a weakness will be
exploited to achieve a certain impact, but a low likelihood that it will be exploited to
achieve a different impact.
| Impact | Details |
|---|---|
|
Execute Unauthorized Code or Commands; Bypass Protection Mechanism; Read Application Data; Varies by Context |
Scope: Confidentiality, Integrity, Availability, Access Control
With an overly permissive policy file, an attacker may be able to bypass the web browser's same-origin policy and conduct many of the same attacks seen in Cross-Site Scripting (CWE-79). An attacker can exploit the weakness to transfer private information from the victim's machine to the attacker, manipulate or steal cookies that may include session information, create malicious requests to a web site on behalf of the victim, or execute malicious code on the end user systems. Other damaging attacks include the disclosure of end user files, installation of Trojan horse programs, redirecting the user to some other page or site, running ActiveX controls (under Microsoft Internet Explorer) from sites that a user perceives as trustworthy, and modifying presentation of content. |
Potential Mitigations
| Phase(s) | Mitigation |
|---|---|
|
Architecture and Design; Operation |
Strategy: Attack Surface Reduction Define a restrictive Content Security Policy [REF-1486] or cross-domain policy file. |
|
Architecture and Design; Operation |
Strategy: Attack Surface Reduction Avoid using wildcards in the CSP / cross-domain policy file. Any domain matching the wildcard expression will be implicitly trusted, and can perform two-way interaction with the target server. |
|
Architecture and Design; Operation |
Strategy: Environment Hardening For Flash, modify crossdomain.xml to use meta-policy options such as 'master-only' or 'none' to reduce the possibility of an attacker planting extraneous cross-domain policy files on a server. |
Relationships
This table shows the weaknesses and high level categories that are related to this
weakness. These relationships are defined as ChildOf, ParentOf, MemberOf and give insight to
similar items that may exist at higher and lower levels of abstraction. In addition,
relationships such as PeerOf and CanAlsoBe are defined to show similar weaknesses that the user
may want to explore.
Relevant to the view "Research Concepts" (View-1000)
| Nature | Type | ID | Name |
|---|---|---|---|
| ChildOf |
|
183 | Permissive List of Allowed Inputs |
| ChildOf |
|
863 | Incorrect Authorization |
| ChildOf |
|
923 | Improper Restriction of Communication Channel to Intended Endpoints |
| CanPrecede |
|
668 | Exposure of Resource to Wrong Sphere |
Relevant to the view "Architectural Concepts" (View-1008)
| Nature | Type | ID | Name |
|---|---|---|---|
| MemberOf |
|
1011 | Authorize Actors |
Background Details
Modes
Of Introduction
The different Modes of Introduction provide information
about how and when this
weakness may be introduced. The Phase identifies a point in the life cycle at which
introduction
may occur, while the Note provides a typical scenario related to introduction during the
given
phase.
| Phase | Note |
|---|---|
| Implementation | |
| Architecture and Design | COMMISSION: This weakness refers to an incorrect design related to an architectural security tactic. |
Applicable Platforms
This listing shows possible areas for which the given
weakness could appear. These
may be for specific named Languages, Operating Systems, Architectures, Paradigms,
Technologies,
or a class of such platforms. The platform is listed along with how frequently the given
weakness appears for that instance.
| Languages |
Class: Not Language-Specific (Undetermined Prevalence) |
| Technologies |
Class: Web Based (Undetermined Prevalence) Web Server (Undetermined Prevalence) |
Demonstrative Examples
Example 1
These cross-domain policy files mean to allow Flash and Silverlight applications hosted on other domains to access its data:
Flash crossdomain.xml :
(bad code)
Example Language: XML
<cross-domain-policy xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://www.adobe.com/xml/schemas/PolicyFile.xsd">
<allow-access-from domain="*.example.com"/>
<allow-access-from domain="*"/>
</cross-domain-policy>
Silverlight clientaccesspolicy.xml :
(bad code)
Example Language: XML
<?xml version="1.0" encoding="utf-8"?>
<access-policy>
<cross-domain-access>
<policy>
<allow-from http-request-headers="SOAPAction">
<domain uri="*"/>
</allow-from>
<grant-to>
<resource path="/" include-subpaths="true"/>
</grant-to>
</policy>
</cross-domain-access>
</access-policy>
These entries are far too permissive, allowing any Flash or Silverlight application to send requests. A malicious application hosted on any other web site will be able to send requests on behalf of any user tricked into executing it.
Selected Observed
Examples
Note: this is a curated list of examples for users to understand the variety of ways in which this weakness can be introduced. It is not a complete list of all CVEs that are related to this CWE entry.
| Reference | Description |
|---|---|
|
Product has a Silverlight cross-domain policy that does not restrict access to another application, which allows remote attackers to bypass the Same Origin Policy. |
|
|
The default Flash Cross Domain policies in a product allows remote attackers to access user files. |
|
|
Chain: Adobe Flash Player does not sufficiently restrict the interpretation and usage of cross-domain policy files, which makes it easier for remote attackers to conduct cross-domain and cross-site scripting (XSS) attacks. |
|
|
Chain: Adobe Flash Player and earlier does not properly interpret policy files, which allows remote attackers to bypass a non-root domain policy. |
|
|
Chain: Adobe Flash Player does not properly handle unspecified encodings during the parsing of a cross-domain policy file, which allows remote web servers to bypass intended access restrictions via unknown vectors. |
Weakness Ordinalities
| Ordinality | Description |
|---|---|
|
Primary |
(where the weakness exists independent of other weaknesses) |
Detection
Methods
| Method | Details |
|---|---|
|
Automated Static Analysis |
Automated static analysis, commonly referred to as Static Application Security Testing (SAST), can find some instances of this weakness by analyzing source code (or binary/compiled code) without having to execute it. Typically, this is done by building a model of data flow and control flow, then searching for potentially-vulnerable patterns that connect "sources" (origins of input) with "sinks" (destinations where the data interacts with external components, a lower layer such as the OS, etc.) Effectiveness: High |
Memberships
This MemberOf Relationships table shows additional CWE Categories and Views that
reference this weakness as a member. This information is often useful in understanding where a
weakness fits within the context of external information sources.
| Nature | Type | ID | Name |
|---|---|---|---|
| MemberOf | 1349 | OWASP Top Ten 2021 Category A05:2021 - Security Misconfiguration | |
| MemberOf | 1396 | Comprehensive Categorization: Access Control | |
| MemberOf | 1437 | OWASP Top Ten 2025 Category A02:2025 - Security Misconfiguration |
Vulnerability Mapping Notes
| Usage |
ALLOWED
(this CWE ID may be used to map to real-world vulnerabilities) |
| Reason | Acceptable-Use |
|
Rationale |
This CWE entry is at the Variant level of abstraction, which is a preferred level of abstraction for mapping to the root causes of vulnerabilities. |
|
Comments |
Carefully read both the name and description to ensure that this mapping is an appropriate fit. Do not try to 'force' a mapping to a lower-level Base/Variant simply to comply with this preferred level of abstraction. |
References
| [REF-1486] |
OWASP. "Content Security Policy Cheat Sheet".
<https://cheatsheetseries.owasp.org/cheatsheets/Content_Security_Policy_Cheat_Sheet.html>. (URL validated: 2025-09-08) |
| [REF-943] |
Apurva Udaykumar. "Setting a crossdomain.xml file for HTTP streaming". Adobe. 2012-11-19.
<https://web.archive.org/web/20121124184922/http://www.adobe.com/devnet/adobe-media-server/articles/cross-domain-xml-for-streaming.html>. (URL validated: 2023-04-07) |
| [REF-944] |
Adobe. "Cross-domain policy for Flash movies". Adobe.
<http://kb2.adobe.com/cps/142/tn_14213.html>. |
| [REF-945] |
Microsoft Corporation. "HTTP Communication and Security with Silverlight".
<https://learn.microsoft.com/en-us/previous-versions/windows/silverlight/dotnet-windows-silverlight/cc838250(v=vs.95)?redirectedfrom=MSDN>. (URL validated: 2023-04-07) |
| [REF-946] |
Microsoft Corporation. "Network Security Access Restrictions in Silverlight".
<https://learn.microsoft.com/en-us/previous-versions/windows/silverlight/dotnet-windows-silverlight/cc645032(v=vs.95)>. (URL validated: 2023-04-07) |
| [REF-947] |
Dongseok Jang, Aishwarya Venkataraman, G. Michael Sawka and Hovav Shacham. "Analyzing the Crossdomain Policies of Flash Applications". 2011-05.
<http://cseweb.ucsd.edu/~hovav/dist/crossdomain.pdf>. |
Content
History
Submissions |
|||
|---|---|---|---|
| Submission Date | Submitter | Organization | |
|
2014-06-05
(CWE 2.7, 2014-06-23) |
CWE Content Team | MITRE | |
| Created by MITRE with input from members of the CWE-Research mailing list. | |||
Contributions |
|||
| Contribution Date | Contributor | Organization | |
|
2022-08-23
(CWE 4.18, 2025-09-09) |
Jagjeet Singh | Rakuten Kobo Inc. | |
| Suggested new entry for misconfigured CSP allowing JavaScript, leading to changes in CWE-942 to make it more general | |||
Modifications |
|||
| Modification Date | Modifier | Organization | |
|
2025-12-11
(CWE 4.19, 2025-12-11) |
CWE Content Team | MITRE | |
| updated Applicable_Platforms, Relationships, Weakness_Ordinalities | |||
|
2025-09-09
(CWE 4.18, 2025-09-09) |
CWE Content Team | MITRE | |
| updated Background_Details, Common_Consequences, Description, Name, Potential_Mitigations, References | |||
|
2024-02-29
(CWE 4.14, 2024-02-29) |
CWE Content Team | MITRE | |
| updated Demonstrative_Examples | |||
|
2023-06-29
(CWE 4.12, 2023-06-29) |
CWE Content Team | MITRE | |
| updated Mapping_Notes, Relationships | |||
|
2023-04-27
(CWE 4.11, 2023-04-27) |
CWE Content Team | MITRE | |
| updated Detection_Factors, References, Relationships | |||
|
2023-01-31
(CWE 4.10, 2023-01-31) |
CWE Content Team | MITRE | |
| updated Description, Relationships | |||
|
2021-10-28
(CWE 4.6, 2021-10-28) |
CWE Content Team | MITRE | |
| updated Relationships | |||
|
2020-06-25
(CWE 4.1, 2020-06-25) |
CWE Content Team | MITRE | |
| updated Description, Name | |||
|
2020-02-24
(CWE 4.0, 2020-02-24) |
CWE Content Team | MITRE | |
| updated Applicable_Platforms, Relationships | |||
|
2019-06-20
(CWE 3.3, 2019-06-20) |
CWE Content Team | MITRE | |
| updated Relationships | |||
|
2017-11-08
(CWE 3.0, 2017-11-08) |
CWE Content Team | MITRE | |
| updated Modes_of_Introduction, References, Relationships | |||
Previous Entry Names |
|||
| Change Date | Previous Entry Name | ||
| 2025-09-09 | Permissive Cross-domain Policy with Untrusted Domains | ||
| 2020-02-26 | Overly Permissive Cross-domain Whitelist | ||
