CVE-2024-2756: __Host-/__Secure- cookie bypass due to partial CVE-2022-31629 fix

Published Apr 11, 2024
·
Updated

Host-/Secure- cookie bypass due to partial CVE-2022-31629 fix

Other sources

Due to an incomplete fix to CVE-2022-31629 https://github.com/advisories/GHSA-c43m-486j-j32p , network and same-site attackers can set a standard insecure cookie in the victim's browser which is treated as a Host- or Secure- cookie by PHP applications.

— NVD

Due to an incomplete fix to CVE-2022-31629, network and same-site attackers can set a standard insecure cookie in the victim's browser which is treated as a Host- or Secure- cookie by PHP applications.

The vulnerability is identical to one previously described in https://bugs.php.net/bug.php?id=81727. Unfortunatly, since CVE-2022-31629 got only partially fixed in PHP >8.1.11, cookies starting with [Host- are parsed by PHP applications as Host-.

— Red Hat

Affected Software

39 affected componentsFixes available
ubuntu/php7.0<7.0.33-0ubuntu0.16.04.16+
7.0.33-0ubuntu0.16.04.16+
ubuntu/php7.2<7.2.24-0ubuntu0.18.04.17+
7.2.24-0ubuntu0.18.04.17+
ubuntu/php7.4<7.4.3-4ubuntu2.22
7.4.3-4ubuntu2.22
ubuntu/php8.1<8.1.2-1ubuntu2.17
8.1.2-1ubuntu2.17
ubuntu/php8.1<8.1.28
8.1.28
ubuntu/php8.2<8.2.10-2ubuntu2.1
8.2.10-2ubuntu2.1
ubuntu/php8.2<8.2.18
8.2.18
ubuntu/php8.3<8.3.6-0
8.3.6-0
ubuntu/php8.3<8.3.6
8.3.6
PHP PHP<8.1.28
8.1.28
redhat/php<8.1.28
8.1.28
redhat/php<8.2.18
8.2.18
redhat/php<8.3.6
8.3.6
debian/php8.2<8.2.18-1~deb12u1
8.2.18-1~deb12u1
All of the following
azurelinux/php<0:8.4.18-2.azl4
0:8.4.18-2.azl4
Microsoft Azure Linux=4.0
All of the following
azurelinux/php<8.1.28-1
8.1.28-1
Microsoft CBL-Mariner=2.0
debian/php8.2
8.2.18-1~deb12u18.2.18-1
debian/php7.3
7.3.31-1~deb10u6
debian/php7.4
7.4.33-1+deb11u5
ubuntu/php5*
ubuntu/php7.0<7.0.33-0ubuntu0.16.04.16+esm9
7.0.33-0ubuntu0.16.04.16+esm9
ubuntu/php7.2<7.2.24-0ubuntu0.18.04.17+esm3
7.2.24-0ubuntu0.18.04.17+esm3
ubuntu/php7.4<7.4.3-4ubuntu2.22
7.4.3-4ubuntu2.22
ubuntu/php8.1<8.1.2-1ubuntu2.17
8.1.2-1ubuntu2.17
ubuntu/php8.3<8.3.6-0maysync1
8.3.6-0maysync1
alpine/php81<8.1.28-r0
8.1.28-r0
alpine/php82<8.2.18-r0
8.2.18-r0
alpine/php82<8.2.18-r0
8.2.18-r0
alpine/php82<8.2.18-r0
8.2.18-r0
alpine/php82<8.2.18-r0
8.2.18-r0
alpine/php83<8.3.6-r0
8.3.6-r0
alpine/php83<8.3.5-r0
8.3.5-r0
alpine/php83<8.3.5-r0
8.3.5-r0
alpine/php83<8.3.5-r0
8.3.5-r0
alpine/php83<8.3.5-r0
8.3.5-r0
alpine/php83<8.3.5-r0
8.3.5-r0
alpine/php83<8.3.5-r0
8.3.5-r0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade ubuntu/php7.0 to a version that resolves this vulnerability.

    Fixed in 7.0.33-0ubuntu0.16.04.16+
  2. Upgrade

    Upgrade ubuntu/php7.2 to a version that resolves this vulnerability.

    Fixed in 7.2.24-0ubuntu0.18.04.17+
  3. Upgrade

    Upgrade ubuntu/php7.4 to a version that resolves this vulnerability.

    Fixed in 7.4.3-4ubuntu2.22
  4. Upgrade

    Upgrade ubuntu/php8.1 to a version that resolves this vulnerability.

    Fixed in 8.1.2-1ubuntu2.17
  5. Upgrade

    Upgrade ubuntu/php8.1 to a version that resolves this vulnerability.

    Fixed in 8.1.28
  6. Upgrade

    Upgrade ubuntu/php8.2 to a version that resolves this vulnerability.

    Fixed in 8.2.10-2ubuntu2.1
  7. Upgrade

    Upgrade ubuntu/php8.2 to a version that resolves this vulnerability.

    Fixed in 8.2.18
  8. Upgrade

    Upgrade ubuntu/php8.3 to a version that resolves this vulnerability.

    Fixed in 8.3.6-0
  9. Upgrade

    Upgrade ubuntu/php8.3 to a version that resolves this vulnerability.

    Fixed in 8.3.6
  10. Upgrade

    Upgrade PHP to a version that resolves this vulnerability.

    Fixed in 8.1.28
  11. Upgrade

    Upgrade redhat/php to a version that resolves this vulnerability.

    Fixed in 8.1.28
  12. Upgrade

    Upgrade redhat/php to a version that resolves this vulnerability.

    Fixed in 8.2.18
  13. Upgrade

    Upgrade redhat/php to a version that resolves this vulnerability.

    Fixed in 8.3.6
  14. Upgrade

    Upgrade debian/php8.2 to a version that resolves this vulnerability.

    Fixed in 8.2.18-1~deb12u1
  15. Upgrade

    Upgrade alpine/php81 to a version that resolves this vulnerability.

    Fixed in 8.1.28-r0
  16. Upgrade

    Upgrade alpine/php82 to a version that resolves this vulnerability.

    Fixed in 8.2.18-r0
  17. Upgrade

    Upgrade alpine/php83 to a version that resolves this vulnerability.

    Fixed in 8.3.6-r0
  18. Upgrade

    Upgrade alpine/php83 to a version that resolves this vulnerability.

    Fixed in 8.3.5-r0
  19. Upgrade

    Upgrade azurelinux/php to a version that resolves this vulnerability.

    Fixed in 0:8.4.18-2.azl4
  20. Upgrade

    Upgrade azurelinux/php to a version that resolves this vulnerability.

    Fixed in 8.1.28-1
  21. Upgrade

    Upgrade debian/php8.2 to a version that resolves this vulnerability.

    Fixed in 8.2.18-1~deb12u1Fixed in 8.2.18-1
  22. Upgrade

    Upgrade debian/php7.3 to a version that resolves this vulnerability.

    Fixed in 7.3.31-1~deb10u6
  23. Upgrade

    Upgrade debian/php7.4 to a version that resolves this vulnerability.

    Fixed in 7.4.33-1+deb11u5
  24. Upgrade

    Upgrade ubuntu/php7.0 to a version that resolves this vulnerability.

    Fixed in 7.0.33-0ubuntu0.16.04.16+esm9
  25. Upgrade

    Upgrade ubuntu/php7.2 to a version that resolves this vulnerability.

    Fixed in 7.2.24-0ubuntu0.18.04.17+esm3
  26. Upgrade

    Upgrade ubuntu/php8.3 to a version that resolves this vulnerability.

    Fixed in 8.3.6-0maysync1
  27. Upgrade

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

    Patch GHSA-wpj3-hf5j-x4v4

Event History

Sep 29, 2022
CVE Published
12:00 AM
Data Sourced
12:00 AM
DescriptionAffected Software
Updated
12:00 AM
Affected Software
Apr 11, 2024
Updated
via PHP·12:00 AM
DescriptionAffected Software
Updated
via PHP·12:00 AM
Affected Software
Apr 15, 2024
Data Sourced
via Red Hat·07:29 AM
DescriptionSeverityAffected Software
Apr 16, 2024
Data Sourced
via Ubuntu·12:00 AM
RemedyDescriptionSeverityAffected Software
Data Sourced
via OSV·12:00 AM
DescriptionSeverityAffected Software
Updated
via Ubuntu·12:00 AM
Affected Software
Updated
via Ubuntu·12:00 AM
Description
Apr 29, 2024
CVE Published
via MITRE·03:34 AM
Data Sourced
via MITRE·03:34 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·04:15 AM
DescriptionSeverityWeakness
Data Sourced
via Microsoft·07:00 AM
DescriptionSeverityWeakness
Data Sourced
via Microsoft·07:00 AM
Affected Software
Updated
via Microsoft·07:00 AM
WeaknessAffected Software
Updated
via Microsoft·07:00 AM
Affected Software
Feb 13, 2025
Updated
via NVD·06:17 PM
Description
Nov 4, 2025
Updated
via MITRE·05:18 PM
Description
Jun 17, 2026
Updated
via NVD·07:25 AM
Description
Aug 13, 2026
Updated
via Microsoft·05:40 AM
Weakness
Dec 3, 2026
Updated
via OSV·11:32 PM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Peer vulnerabilities

Found alongside the following vulnerabilities.

Frequently Asked Questions

1

What is the severity of CVE-2024-2756?

CVE-2024-2756 has been classified as a high severity vulnerability due to the potential for attackers to manipulate cookie handling in PHP applications.

2

How do I fix CVE-2024-2756?

To fix CVE-2024-2756, upgrade PHP to the latest available version that addresses this vulnerability, such as 8.1.28 or higher.

3

What versions of PHP are affected by CVE-2024-2756?

CVE-2024-2756 affects multiple PHP versions including 7.0.x, 7.2.x, 7.4.x, 8.1.x, and 8.2.x prior to the respective patched releases.

4

Is CVE-2024-2756 a result of a previous vulnerability?

Yes, CVE-2024-2756 is an incomplete fix to the previously reported CVE-2022-31629.

5

Can CVE-2024-2756 be exploited remotely?

Yes, CVE-2024-2756 can potentially be exploited by remote attackers, making it a significant security concern.

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