CVE-2026-79752

CakePHP: Multiple methods in FunctionsBuilder vulnerable to SQL injection

State
Published
Severity
9.2 Critical
Published
Sep 17, 2026
Updated
Sep 17, 2026
Reserved
Aug 25, 2026

Read the record on cve.org

Description

CakePHP is a rapid development framework for PHP. Prior to 4.5.12, 4.6.5, 5.1.9, 5.2.14, and 5.3.7, FunctionsBuilder::cast, FunctionsBuilder::extract, FunctionsBuilder::datePart, and FunctionsBuilder::dateAdd in src/Database/FunctionsBuilder.php accept user-controlled dataType, part, or unit values and incorporate them into generated SQL as unescaped structural fragments. An application that passes untrusted input to these parameters can permit SQL injection with confidentiality, integrity, and availability impact according to the database connection's privileges. This issue is fixed in versions 4.5.12, 4.6.5, 5.1.9, 5.2.14, and 5.3.7.

Scores

CVSSScoreVectorSource
4.09.2 CriticalCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:NGitHub_M

Weaknesses

  • CWE-89 Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')

Affected Products

ProductVersions
cakephpcakephp
  • < 4.5.12Affected
  • >= 4.6.0, < 4.6.5Affected
  • >= 5.0.0, < 5.1.9Affected
  • >= 5.2.0, < 5.2.14Affected
  • >= 5.3.0, < 5.3.7Affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.