CWE•Compound•Stable•20 recent CVEs
CWE-352Cross-Site Request Forgery (CSRF)
Description
The web application does not, or cannot, sufficiently verify whether a request was intentionally provided by the user who sent the request, which could have originated from an unauthorized actor.
Common consequences
- Confidentiality,Integrity,Availability,Non-Repudiation,Access Control→Gain Privileges or Assume Identity,Bypass Protection Mechanism,Read Application Data,Modify Application Data,DoS: Crash,The consequences will vary depending on the nature of the functionality that is vulnerable to CSRF. An attacker could trick a client into making an unintentional request to the web server via a URL, image load, XMLHttpRequest, etc., which w
Potential mitigations
- Architecture and Design[object Object]
- ImplementationEnsure that the application is free of cross-site scripting issues (CWE-79), because most CSRF defenses can be bypassed using attacker-controlled script.
- Architecture and DesignGenerate a unique nonce for each form, place the nonce into the form, and verify the nonce upon receipt of the form. Be sure that the nonce is not predictable (CWE-330). [REF-332]
- Architecture and DesignIdentify especially dangerous operations. When the user performs a dangerous operation, send a separate confirmation request to ensure that the user intended to perform that operation.
- Architecture and Design[object Object]
- Architecture and DesignDo not use the GET method for any request that triggers a state change.
- ImplementationCheck the HTTP Referer header to see if the request originated from an expected page. This could break legitimate functionality, because users or proxies may have disabled sending the Referer for privacy reasons.
Related CWEs
Recent CVEs classified under this CWE
CVE-2026-97194.32026-06-06CVE-2026-70474.32026-06-06CVE-2026-112706.52026-06-05CVE-2026-112657.52026-06-05CVE-2026-112146.52026-06-04CVE-2026-112006.52026-06-04CVE-2026-111956.52026-06-04CVE-2026-111946.52026-06-04CVE-2026-111564.32026-06-04CVE-2026-111554.32026-06-04CVE-2026-111486.52026-06-04CVE-2026-111396.52026-06-04CVE-2026-111346.52026-06-04CVE-2026-111296.52026-06-04CVE-2026-111066.52026-06-04CVE-2026-110846.52026-06-04CVE-2026-110836.52026-06-04CVE-2026-110206.52026-06-04CVE-2026-439858.82026-06-04CVE-2019-257299.82026-06-04