GHSA-829q-v5g8-hhxc: Cakephp/cakephp CakePHP Has Incorrect Cross-Site Request Vulnerability
MODERATEGHSA-829q-v5g8-hhxc is a MODERATE cakephp has incorrect cross-site request vulnerability (CWE-352: Cross-Site Request Forgery (CSRF)) affecting Cakephp/cakephp libraries in the Packagist ecosystem. The issue involves cakephp has incorrect cross-site request forgery validation. Remediation is available by upgrading affected packages to version 3.0.4.
GHSA-829q-v5g8-hhxc at a Glance
How to Fix GHSA-829q-v5g8-hhxc
To remediate this vulnerability, upgrade all affected Cakephp/cakephp dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade cakephp/cakephp to 3.0.4
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for cakephp/cakephp
How to Check if You Are Affected
To determine whether your application is affected by GHSA-829q-v5g8-hhxc, inspect your project dependencies for Cakephp/cakephp:
inspect dependencies for cakephp/cakephp
Analyze the terminal output to locate any version of Cakephp/cakephp in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.0.4), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-352: Cross-Site Request Forgery (CSRF), where 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. In Cakephp/cakephp, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-829q-v5g8-hhxc Affected Cakephp/cakephp Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
cakephp/cakephp
|
Packagist |
≥ 3.0.0
< 3.0.4
|
3.0.4
|
References
Frequently Asked Questions
What is GHSA-829q-v5g8-hhxc?
Which Cakephp/cakephp versions are affected?
What version fixes GHSA-829q-v5g8-hhxc?
Is cakephp/cakephp affected?
What CWE is associated with GHSA-829q-v5g8-hhxc?
How can I check Packagist dependencies for GHSA-829q-v5g8-hhxc?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-829q-v5g8-hhxc",
"modified" : "2023-01-20T23:02:02Z",
"published" : "2023-01-20T23:02:02Z",
"aliases" : [ ],
"summary" : "CakePHP has incorrect Cross-Site Request Forgery validation",
"details" : "CsrfComponent fails to invalidate requests that are missing both the CSRF token, and CSRF post data.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/cakephp"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "3.0.0"
}, {
"fixed" : "3.0.4"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/commit/522ed2f1fb49b00001c1ef8815a6feda790d61dd"
}, {
"type" : "WEB",
"url" : "https://bakery.cakephp.org/2015/05/07/cakephp_3_0_4_released.html"
}, {
"type" : "WEB",
"url" : "https://github.com/FriendsOfPHP/security-advisories/blob/master/cakephp/cakephp/2015-05-07.yaml"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/cakephp/cakephp"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-352" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-01-20T23:02:02Z",
"nvd_published_at" : null
}
}