CVE-2026-77635: CakePHP SQL Injection Vulnerability
CRITICALCVE-2026-77635 is a CRITICAL sql injection vulnerability (CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')) affecting CakePHP libraries in the Packagist ecosystem. The issue involves functionsbuilder::jsonvalue() vulerable to sql injection with postgresdriver. Remediation is available by upgrading affected packages to version 5.3.7, 5.2.15, 5.1.10.
CVE-2026-77635 at a Glance
How to Fix CVE-2026-77635
To remediate this vulnerability, upgrade all affected 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 5.3.7
Upgrade cakephp/cakephp to 5.2.15
Upgrade cakephp/cakephp to 5.1.10
Upgrade cakephp/database to 5.3.7
Upgrade cakephp/database to 5.2.15
Upgrade cakephp/database to 5.1.10
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 CVE-2026-77635, inspect your project dependencies for CakePHP:
inspect dependencies for cakephp/cakephp
Analyze the terminal output to locate any version of CakePHP in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 5.3.7), 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-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection'), where the product constructs all or part of an sql command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended sql command when it is sent to a downstream component. without sufficient removal or quoting of sql syntax in user-controllable inputs, the generated sql query can cause those inputs to be interpreted as sql instead of ordinary user data. In 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
CVE-2026-77635 Affected CakePHP Versions
6 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
cakephp/cakephp
|
Packagist |
≥ 5.3.0
< 5.3.7
|
5.3.7
|
|
cakephp/cakephp
|
Packagist |
≥ 5.2.0
< 5.2.15
|
5.2.15
|
|
cakephp/cakephp
|
Packagist |
≥ 5.1.0
< 5.1.10
|
5.1.10
|
|
cakephp/database
|
Packagist |
≥ 5.3.0
< 5.3.7
|
5.3.7
|
|
cakephp/database
|
Packagist |
≥ 5.2.0
< 5.2.15
|
5.2.15
|
|
cakephp/database
|
Packagist |
≥ 5.1.0
< 5.1.10
|
5.1.10
|
References
Frequently Asked Questions
What is CVE-2026-77635?
Which CakePHP versions are affected?
What version fixes CVE-2026-77635?
Is cakephp/cakephp affected?
Is cakephp/database affected?
What CWE is associated with CVE-2026-77635?
How can I check Packagist dependencies for CVE-2026-77635?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-fxf7-vhh8-7vpq",
"modified" : "2026-09-08T20:56:41Z",
"published" : "2026-09-08T20:56:41Z",
"aliases" : [ "CVE-2026-77635" ],
"summary" : "CakePHP: FunctionsBuilder::jsonValue() vulerable to SQL injection with PostgresDriver",
"details" : "### Impact\nThe `FunctionsBuilder::jsonValue($field, $jsonPath)` methods with the Postgres driver is vulnerable to SQL injection if user controlled data is supplied to the `$jsonPath` parameter.\n\n### Patches\n5.1.10, 5.2.15, 5.3.7 \n\n### Workarounds\nDon't provide user controlled data to these functions/parameters.",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/cakephp"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.3.0"
}, {
"fixed" : "5.3.7"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/cakephp"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.2.0"
}, {
"fixed" : "5.2.15"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/cakephp"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.1.0"
}, {
"fixed" : "5.1.10"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/database"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.3.0"
}, {
"fixed" : "5.3.7"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/database"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.2.0"
}, {
"fixed" : "5.2.15"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "cakephp/database"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "5.1.0"
}, {
"fixed" : "5.1.10"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/security/advisories/GHSA-fxf7-vhh8-7vpq"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-77635"
}, {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/commit/138f2f61486532c29ee4d106da2a9848c1ff1ab3"
}, {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/commit/489a40fb7c6e597af33fe0f7264047afccb90d55"
}, {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/commit/9f1ad970a3b72293d4a37e694276645f804e819f"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/cakephp/cakephp"
}, {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/releases/tag/5.1.10"
}, {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/releases/tag/5.2.15"
}, {
"type" : "WEB",
"url" : "https://github.com/cakephp/cakephp/releases/tag/5.3.7"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-89" ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2026-09-08T20:56:41Z",
"nvd_published_at" : "2026-08-24T21:17:48Z"
}
}