CVE-2021-21418 Potential XSS injection in the newsletter conditions field
An employee can inject JavaScript into the newsletter conditions field, leading to execution in the front office.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2021-21418?
CVE-2021-21418 is a medium-severity cross-site scripting vulnerability in PrestaShop ps_emailsubscription, published on 31 Mar 2021. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.
Official description
ps_emailsubscription is a newsletter subscription module for the PrestaShop platform. An employee can inject javascript in the newsletter condition field that will then be executed on the front office The issue has been fixed in 2.6.1
Weakness: CWE-79
Which versions are affected by CVE-2021-21418?
2 open source packages ship an affected version, including prestashop/ps_emailsubscription. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
prestashop/ps_emailsubscription Packagist | All versions | 2.6.1 |
prestashop/ps_emailsubscription Packagist | All versions | 2.6.1 |
Products include Prestashop Ps Emailsubscription.
How do I fix CVE-2021-21418?
Upgrade prestashop/ps_emailsubscription to 2.6.1 or later.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2021-21418 being exploited?
There is no known exploitation of CVE-2021-21418 in the wild and no public exploit code.
Sources
Also known as GHSA-vwfx-hh3w-fj99.