CVE-2021-28957

MEDIUMCVSS 6.1/10EPSS 4.00%

Last modified

CVE-2021-28957 is a medium-severity vulnerability rated 6.1/10 on the CVSS scale. An XSS vulnerability was discovered in python-lxml's clean module versions before 4.6.3. When disabling the safe_attrs_only and forms arguments, the Cleaner class does not remove the formaction attribute allowing for JS to bypass the sanitizer. EPSS estimates a 4.00% chance of exploitation in the next 30 days.

Description

An XSS vulnerability was discovered in python-lxml's clean module versions before 4.6.3. When disabling the safe_attrs_only and forms arguments, the Cleaner class does not remove the formaction attribute allowing for JS to bypass the sanitizer. A remote attacker could exploit this flaw to run arbitrary JS code on users who interact with incorrectly sanitized HTML. This issue is patched in lxml 4.6.3.

Metrics

CVSS 3.1
6.1/10

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

EPSS Probability
4.00%

89.2th percentile

Probability of exploitation in the next 30 days. Learn more

Weakness Enumeration

Affected Software

VendorProductVersions
LxmlLxml< 4.6.3
DebianDebian Linux9.0
DebianDebian Linux10.0
FedoraprojectFedora33
FedoraprojectFedora34
NetappSnapcenterAll versions
OracleZfs Storage Appliance Kit8.8

References

Timeline

Published
Last Modified
Status
Modified

Frequently Asked Questions

What is CVE-2021-28957?
An XSS vulnerability was discovered in python-lxml's clean module versions before 4.6.3. When disabling the safe_attrs_only and forms arguments, the Cleaner class does not remove the formaction attribute allowing for JS to bypass the sanitizer. A remote attacker could exploit this flaw to run arbitrary JS code on users who interact with incorrectly sanitized HTML. This issue is patched in lxml 4.6.3.
How severe is CVE-2021-28957?
CVE-2021-28957 has a CVSS score of 6.1/10 (MEDIUM severity). The EPSS model estimates a 4.00% probability of exploitation in the next 30 days.
How do I fix CVE-2021-28957?
Check the vendor references and advisories linked above for patched versions and mitigation guidance. You can also run a Strix scan to test if your systems are affected.

Are you affected by CVE-2021-28957?

Run a free Strix scan to check your systems for this vulnerability.

Scan your code now

Source: NVD / NIST