Medium

CakePHP: View::element() is missing a path containment check

  • Disclosed: 26.06.2026
  • Updated: 11.10.2026 10:22

Impact

View::_getElementFileName() does not check that the resolved element path is within the application/plugin view template paths. When element names are created with specifically crafted user-supplied data this weakness can be leveraged to include other PHP files on the server.

Patches

Patched releases are available in 5.3.6, 5.2.13, 5.1.7, 4.6.4, and 4.5.11.

Workarounds

If developers are not using user-supplied data in element names, no action is required.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
Composer package cakephp/cakephp >= 5.3.0, < 5.3.6, >= 5.2.0, < 5.2.13, >= 5.0.0, < 5.1.7, >= 4.6.0, < 4.6.4, < 4.5.11 5.3.6, 5.2.13, 5.1.7, 4.6.4, 4.5.11

References

CVSS score -
CVSS vector
CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N
Weakness (CWE)
CWE-22
Platform
Composer
Package
cakephp/cakephp
Disclosed
26.06.2026
Updated
11.10.2026 10:22

Sources and licenses

OSV / GitHub Advisory Database - GHSA-wpvj-hjcr-h3p2 - CC BY 4.0

Vulnerability history: cakephp/cakephp

All published vulnerabilities of this package (Composer package), newest first. Shows whether this is a one-off slip or a package that needs watching.

All (22) in the archive
Total entries
22
First → latest
12.2019 09.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • Critical 3
  • High 8
  • Medium 11

Disclosures per year

  1. 2019: 1
  2. 2020: 0
  3. 2021: 0
  4. 2022: 9
  5. 2023: 7
  6. 2024: 0
  7. 2025: 0
  8. 2026: 5
Severity:
  1. Critical CVE-2026-79752 < 4.5.12, >= 4.6.0, < 4.6.5, >= 5.0.0, < 5.1.9, >= 5.2.0, < 5.2.14, >= 5.3.0, < 5.3.7 4.5.12, 4.6.5, 5.1.9, 5.2.14, 5.3.7
  2. Critical CVE-2026-77635 >= 5.3.0, < 5.3.7, >= 5.2.0, < 5.2.15, >= 5.1.0, < 5.1.10 5.3.7, 5.2.15, 5.1.10
  3. High CVE-2026-77634 >= 4.5.0, < 4.5.12, >= 4.6.0, < 4.6.5, >= 5.0.0, < 5.1.9, >= 5.2.0, < 5.2.14, >= 5.3.0, < 5.3.7 4.5.12, 4.6.5, 5.1.9, 5.2.14, 5.3.7
  4. CakePHP: View::element() is missing a path containment check this entry
    Medium CVE-2026-48820 >= 5.3.0, < 5.3.6, >= 5.2.0, < 5.2.13, >= 5.0.0, < 5.1.7, >= 4.6.0, < 4.6.4, < 4.5.11 5.3.6, 5.2.13, 5.1.7, 4.6.4, 4.5.11
  5. High ghsa-q79m-c546-2g63 >= 3.0.0, < 3.0.6, >= 2.0.0, < 2.0.99, >= 2.1.0, < 2.1.99, >= 2.2.0, < 2.2.99, >= 2.3.0, < 2.3.99, >= 2.4.0, < 2.4.99, >= 2.5.0, < 2.5.90, >= 2.6.0, < 2.6.6 3.0.6, 2.0.99, 2.1.99, 2.2.99, 2.3.99, 2.4.99, 2.5.90, 2.6.6
  6. Critical · 9.8 CVE-2023-22727 >= 4.2.0, < 4.2.12, >= 4.3.0, < 4.3.11, >= 4.4.0, < 4.4.10 4.2.12, 4.3.11, 4.4.10
  7. High · 8.8 CVE-2020-35239 >= 4.0.0, < 4.0.10, >= 4.1.0, < 4.1.4 4.0.10, 4.1.4
  8. High · 7.5 CVE-2012-4399 >= 2.1.0-alpha, < 2.1.5, >= 2.2.0-beta, < 2.2.1 2.1.5, 2.2.1
  9. High · 7.5 CVE-2016-4793 >= 1.2.0, < 2.6.13, >= 2.7.0-rc1, < 2.7.11, >= 2.8.0-rc1, < 2.8.2, >= 3.0.0-rc1, < 3.0.17, >= 3.1.0-beta1, < 3.1.12, >= 3.2.0-rc1, < 3.2.5 2.6.13, 2.7.11, 2.8.2, 3.0.17, 3.1.12, 3.2.5
  10. High · 7.5 CVE-2019-11458 >= 3.0.0, < 3.5.18, >= 3.6.0, < 3.6.15, >= 3.7.0, < 3.7.7 3.5.18, 3.6.15, 3.7.7

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.