CVE-2021-28957An XSS vulnerability was discovered in python-lxml's clean module versions before 4.6.3. When disabling the safe_attrs_only and forms…
- 6.1MediumCVSS base score
- 4.0%Exploitation in 30 daysEPSS · top 9.2% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
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.
Timeline
ID reserved
By mitre
Published
- 5 years later
· 5 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| CISA-ADPADP (enrichment) | 3.1 | Medium6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
| NVDNVD · Modified | 3.1 | Medium6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
- EPSS (exploitation in 30 days)
- 4.0% · top 9.2% of all CVEs (18 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: no · Technical impact: partial
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 6.1.
Affected products
n/a
- affected n/a
Affected packages
From reviewed advisories of the GitHub Advisory Database.
References
References10
- https://bugs.launchpad.net/lxml/+bug/1888153 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/lxml/lxml/pull/316/commits/10ec1b4e9f93713513a3264ed6158af22492f270 (opens in a new tab)x_refsource_MISCx_transferred
- [debian-lts-announce] 20210324 [SECURITY] [DLA 2606-1] lxml security update (opens in a new tab)mailing-listx_refsource_MLISTx_transferred
- DSA-4880 (opens in a new tab)vendor-advisoryx_refsource_DEBIANx_transferred
- FEDORA-2021-28723f9670 (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
- FEDORA-2021-4cdb0f68c7 (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
- https://www.oracle.com/security-alerts/cpuoct2021.html (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/lxml/lxml/commit/a5f9cb52079dc57477c460dbe6ba0f775e14a999 (opens in a new tab)x_refsource_MISCx_transferred
- https://security.netapp.com/advisory/ntap-20210521-0004/ (opens in a new tab)x_refsource_CONFIRMx_transferred
- GLSA-202208-06 (opens in a new tab)vendor-advisoryx_refsource_GENTOOx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2021-0116 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-jq4v-f5q6-mjqq (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2021-28957)Record last updated .