CVE-2024-21627: Some attribute not escaped in Validate::isCleanHTML method

Published Jan 2, 2024
·
Updated

Description Some event attributes are not detected by the isCleanHTML method

Impact Some modules using the isCleanHTML method could be vulnerable to xss

Patches 8.1.3, 1.7.8.11

Workarounds The best workaround is to use the HTMLPurifier library to sanitize html input coming from users. The library is already available as a dependency in the PrestaShop project. Beware though that in legacy object models, fields of HTML type will call isCleanHTML.

Reporters

Reported by Antonio Russo (@Antonio-R1 on GitHub) and Antonio Rocco Spataro (@antoniospataro on GitHub).

Other sources

PrestaShop is an open-source e-commerce platform. Prior to versions 8.1.3 and 1.7.8.11, some event attributes are not detected by the isCleanHTML method. Some modules using the isCleanHTML method could be vulnerable to cross-site scripting. Versions 8.1.3 and 1.7.8.11 contain a patch for this issue. The best workaround is to use the HTMLPurifier library to sanitize html input coming from users. The library is already available as a dependency in the PrestaShop project. Beware though that in legacy object models, fields of HTML type will call isCleanHTML.

NVD

Affected Software

4 affected componentsFixes available
composer/prestashop/prestashop<1.7.8.11
1.7.8.11
composer/prestashop/prestashop>=8.0.0-beta.1<8.1.3
8.1.3
Prestashop PrestaShop<1.7.8.11
Prestashop PrestaShop>=8.0.0<8.1.3

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

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

    Fixed in 1.7.8.11
  2. Upgrade

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

    Fixed in 8.1.3
  3. Upgrade

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

    Fixed in 8.1.3
  4. Upgrade

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

    Fixed in 1.7.8.11
  5. Compensating control

    As a workaround, sanitize any user-supplied HTML input using the `HTMLPurifier` library (available as a dependency in the PrestaShop project), especially when modules use `Validate::isCleanHTML` for event attributes.

Event History

Jan 2, 2024
CVE Published
via MITRE·09:03 PM
Data Sourced
via MITRE·09:03 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·09:15 PM
RemedyDescriptionSeverityWeaknessAffected Software
Jan 3, 2024
Advisory Published
09:41 PM
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2024-21627?

CVE-2024-21627 has been classified as a medium severity vulnerability due to its potential for cross-site scripting (XSS) attacks.

2

How do I fix CVE-2024-21627?

To remediate CVE-2024-21627, update your PrestaShop installation to version 8.1.3 or 1.7.8.11.

3

Which versions of PrestaShop are affected by CVE-2024-21627?

CVE-2024-21627 affects PrestaShop versions prior to 8.1.3 and 1.7.8.11.

4

What is a workaround for CVE-2024-21627 if I cannot immediately update?

A recommended workaround for CVE-2024-21627 is to use the HTMLPurifier library to sanitize HTML inputs.

5

What potential impact does CVE-2024-21627 have on my application?

CVE-2024-21627 could expose your application to cross-site scripting vulnerabilities, allowing attackers to inject malicious scripts.

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