Unintended Content Interpretation
V3.2.1
Verify that security controls are in place to prevent browsers from rendering content or functionality in HTTP responses in an incorrect context (e.g., when an API, a user-uploaded file or other resource is requested directly). Possible controls could include: not serving the content unless HTTP request header fields (such as Sec-Fetch-) indicate it is the correct context, using the sandbox directive of the Content-Security-Policy header field or using the attachment disposition type in the Content-Disposition header field.
Required for Level 1, 2 and 3
Related CAPEC™ Requirements
CAPEC™ (3.9): 103, 152, 160, 165, 19, 242, 569, 63
V3.2.2
Verify that content intended to be displayed as text, rather than rendered as HTML, is handled using safe rendering functions (such as createTextNode or textContent) to prevent unintended execution of content such as HTML or JavaScript.
Required for Level 1, 2 and 3
Related CAPEC™ Requirements
CAPEC™ (3.9): 152, 160, 19, 242, 267, 28, 43, 63
V3.2.3
Verify that the application avoids DOM clobbering when using client-side JavaScript by employing explicit variable declarations, performing strict type checking, avoiding storing global variables on the document object, and implementing namespace isolation.
Required for Level 3
Related CAPEC™ Requirements
CAPEC™ (3.9): 152, 160, 19, 242, 267, 63
Disclaimer
Credit via OWASP ASVS.For more information visit: The OWASP ASVS Project or Github respository.. OWASP ASVS is under the Creative Commons Attribution-Share Alike v4.0 license.