GHSA-2qh5-382h-3jpc: CRLF Injection

Published Sep 8, 2026
·
Updated

Impact

Custom mail headers added with Message::setHeaders() or addHeaders() do not have CRLF replaced allowing header injection if user controlled data is added to message headers without stripping CRLF bytes.

Patches 5.3.7, 5.2.14, 5.1.9, 4.6.5, 4.5.12 contain fixes for this issue.

Workarounds You can strip CRLF bytes from email header values before setting header values.

Affected Software

5 affected componentsFixes available
composer/cakephp/cakephp>=5.3.0<5.3.7
5.3.7
composer/cakephp/cakephp>=5.2.0<5.2.14
5.2.14
composer/cakephp/cakephp>=5.0.0<5.1.8
5.1.9
composer/cakephp/cakephp>=4.6.0<4.6.5
4.6.5
composer/cakephp/cakephp>=4.5.0<4.5.12
4.5.12

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade composer/cakephp/cakephp to a version that resolves this vulnerability.

    Fixed in 5.3.7
  2. Upgrade

    Upgrade composer/cakephp/cakephp to a version that resolves this vulnerability.

    Fixed in 5.2.14
  3. Upgrade

    Upgrade composer/cakephp/cakephp to a version that resolves this vulnerability.

    Fixed in 5.1.9
  4. Upgrade

    Upgrade composer/cakephp/cakephp to a version that resolves this vulnerability.

    Fixed in 4.6.5
  5. Upgrade

    Upgrade composer/cakephp/cakephp to a version that resolves this vulnerability.

    Fixed in 4.5.12
  6. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 5.3.7
  7. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 5.2.14
  8. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 5.1.9
  9. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 4.6.5
  10. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 4.5.12
  11. Configuration

    Before calling Message::setHeaders() or addHeaders(), remove/strip any CRLF bytes from the email header value(s) (including those built from user-controlled data) to prevent CRLF-based header injection.

    Email headers set via Message::setHeaders()/addHeaders() Strip CRLF bytes from header values = Strip CRLF (carriage return \r and newline \n) from any user-controlled data before setting header values

Event History

Sep 8, 2026
Advisory Published
via GitHub·08:56 PM
Data Sourced
via GitHub·08:56 PM
DescriptionWeaknessAffected Software

Frequently Asked Questions

1

What conditions are required for exploitation?

An application must pass user-controlled data into custom mail headers through Message::setHeaders() or addHeaders() without first removing CRLF bytes. The issue is limited to those custom header values.

2

Which releases contain a fix?

Fixed releases are 5.3.7, 5.2.14, 5.1.9, 4.6.5, and 4.5.12.

3

What can be done if updating is not immediately possible?

Strip CRLF bytes from all email header values before setting them. Apply this validation wherever values are passed to Message::setHeaders() or addHeaders().

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203