Skip to content
Noroxi
CVE-2021-43818· NVD / CVE Program· CNA GitHub_M

HTML Cleaner allows crafted and SVG embedded scripts to pass through

lxml is a library for processing XML and HTML in the Python language. Prior to version 4.6.5, the HTML Cleaner in lxml.html lets certain crafted script content pass through, as well as script content in SVG files embedded using data URIs. Users that employ the HTML cleaner in a security relevant context should upgrade to lxml 4.6.5 to receive a patch. There are no known workarounds available.

HighCVSS 7.1 · v3.1—No exploit Fix available

Noroxi analysis

No Noroxi analysis for this record yet

We don't hand-write analysis for the hundreds of thousands of vulnerabilities in the database; that wouldn't be honest. For notable, high-impact vulnerabilities our team writes the mechanism, detection and remediation steps.

We use this product, ask for help
Published
Dec 13, 2021
Updated
Jun 17, 2026
EPSS
2.5% · 84th percentile
Follow this CVE

Sign in to follow · You’ll be notified if a followed record enters KEV, gets an exploit or is updated.

Report tools

JSON

Action score

29

Monitor

Low priority for now.

CVSS
28 / 40 · 7.1 / 10
CISA KEV
0 / 30 · Not listed
EPSS
1 / 30 · 2.5%

CISA SSVC decision

Exploitation
none
Automatable
no
Technical impact
partial

Vulnrichment: CISA's decision-tree inputs.

CNA vs NVD score

NVD
7.1
CNA · GitHub_M
8.2
1.1 point gap

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

The score given by the assigning authority versus NVD’s independent score. A gap means the severity is contested.

Affected systems

VendorProduct
lxmllxml
fedoraprojectfedora
debiandebian linux
netappsolidfire
netappsolidfire enterprise sds
netapphci storage node firmware
netapphci storage node
oraclecommunications cloud native core binding support function
oraclecommunications cloud native core network exposure function
oraclecommunications cloud native core policy
oraclehttp server
oraclezfs storage appliance kit

Affected versions

NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.

  • debian debian linux10.0
  • debian debian linux11.0
  • debian debian linux9.0
  • fedoraproject fedora34
  • fedoraproject fedora35
  • lxml lxmlbefore 4.6.5
  • netapp hci storage node firmwareall versions
  • netapp solidfireall versions
  • netapp solidfire enterprise sdsall versions
  • oracle communications cloud native core binding support function22.1.3
  • oracle communications cloud native core network exposure function22.1.1
  • oracle communications cloud native core policy22.2.0
  • oracle http server12.2.1.3.0
  • oracle http server12.2.1.4.0
  • oracle zfs storage appliance kit8.8

Versions reported by the vendor

Affected version ranges reported by the assigning authority (GitHub_M). Independent of NVD's CPE analysis and usually ahead of it.

  • lxml lxml

    • < 4.6.5affected

Package-level exposure

OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.

EcosystemPackageAffected rangeFix
AlmaLinux:8babelbefore 2.5.1-10.module_el8.6.0+2781+fed64c132.5.1-10.module_el8.6.0+2781+fed64c13
AlmaLinux:8python-nose-docsbefore 1.3.7-31.module_el8.5.0+2569+5c5719bc1.3.7-31.module_el8.5.0+2569+5c5719bc
AlmaLinux:8python-nose-docsbefore 1.3.7-31.module_el8.6.0+2781+fed64c131.3.7-31.module_el8.6.0+2781+fed64c13
AlmaLinux:8python-psycopg2-docbefore 2.7.5-7.module_el8.6.0+2781+fed64c132.7.5-7.module_el8.6.0+2781+fed64c13
AlmaLinux:8python-sqlalchemy-docbefore 1.3.2-2.module_el8.6.0+2781+fed64c131.3.2-2.module_el8.6.0+2781+fed64c13
AlmaLinux:8python-sqlalchemy-docbefore 1.3.2-2.module_el8.5.0+2569+5c5719bc1.3.2-2.module_el8.5.0+2569+5c5719bc
AlmaLinux:8python2before 2.7.18-10.module_el8.6.0+2781+fed64c13.alma2.7.18-10.module_el8.6.0+2781+fed64c13.alma
AlmaLinux:8python2-attrsbefore 17.4.0-10.module_el8.6.0+2781+fed64c1317.4.0-10.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-babelbefore 2.5.1-10.module_el8.6.0+2781+fed64c132.5.1-10.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-backportsbefore 1.0-16.module_el8.6.0+2781+fed64c131.0-16.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-backports-ssl_match_hostnamebefore 3.5.0.1-12.module_el8.6.0+2781+fed64c133.5.0.1-12.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-bsonbefore 3.7.0-1.module_el8.6.0+2781+fed64c133.7.0-1.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-chardetbefore 3.0.4-10.module_el8.6.0+2781+fed64c133.0.4-10.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-coveragebefore 4.5.1-4.module_el8.6.0+2781+fed64c134.5.1-4.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-Cythonbefore 0.28.1-7.module_el8.6.0+2781+fed64c130.28.1-7.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-debugbefore 2.7.18-10.module_el8.6.0+2781+fed64c13.alma2.7.18-10.module_el8.6.0+2781+fed64c13.alma
AlmaLinux:8python2-develbefore 2.7.18-10.module_el8.6.0+2781+fed64c13.alma2.7.18-10.module_el8.6.0+2781+fed64c13.alma
AlmaLinux:8python2-dnsbefore 1.15.0-10.module_el8.6.0+2781+fed64c131.15.0-10.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-docsbefore 2.7.16-2.module_el8.6.0+2781+fed64c132.7.16-2.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-docs-infobefore 2.7.16-2.module_el8.6.0+2781+fed64c132.7.16-2.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-docutilsbefore 0.14-12.module_el8.6.0+2781+fed64c130.14-12.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-funcsigsbefore 1.0.2-13.module_el8.6.0+2781+fed64c131.0.2-13.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-idnabefore 2.5-7.module_el8.6.0+2781+fed64c132.5-7.module_el8.6.0+2781+fed64c13
AlmaLinux:8python2-ipaddressbefore 1.0.18-6.module_el8.6.0+2781+fed64c131.0.18-6.module_el8.6.0+2781+fed64c13

+96

Same product

lxml: all records

Other highest-scoring records for the same primary product.

  • CVE-2026-49825lxml: javascript: URL bypass in Cleaner via xlink:href
    32Monitor
  • CVE-2022-2309NULL Pointer Dereference in lxml/lxml
    31Monitor
  • CVE-2026-41066lxml: Default configuration of iterparse() and ETCompatXMLParser() allows XXE to local files
    30Monitor
  • CVE-2014-3146Incomplete blacklist vulnerability in the lxml.html.clean module in lxml before 3.3.5 allows remote attackers to conduct cross-site scriptin
    26Monitor
  • CVE-2021-28957An XSS vulnerability was discovered in python-lxml's clean module versions before 4.6.3.
    25Monitor
  • CVE-2020-27783A XSS vulnerability was discovered in python-lxml's clean module.
    25Monitor

Remediation

Which version to upgrade to

Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.

Product / packageFixed versionSource
almalinux:python393.9.7-1.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-attrs20.3.0-2.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-cffi1.14.3-2.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-chardet3.0.4-19.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-cryptography3.3.1-2.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-Cython0.29.21-5.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-debug3.9.7-1.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-devel3.9.7-1.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-idle3.9.7-1.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-idna2.10-3.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-iniconfig1.1.1-2.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
almalinux:python39-PyMySQL0.10.1-2.module_el8.6.0+2780+a40f65e1 · AlmaLinux:8Package registry (OSV)
alpine:py3-lxml4.6.5-r0 · Alpine:v3.16Package registry (OSV)
debian:lxml4.7.1-1 · Debian:12Package registry (OSV)
opensuse:python-lxml4.7.1-3.7.1 · openSUSE:Leap 15.3Package registry (OSV)
PyPI:lxml4.6.5Package registry (OSV)
red hat:mod_wsgi0:4.7.1-4.module+el8.4.0+9822+20bf1249 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:numpy0:1.19.4-3.module+el8.5.0+12204+54860423 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:numpy-debugsource0:1.19.4-3.module+el8.5.0+12204+54860423 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:python-cffi0:1.14.3-2.module+el8.4.0+9822+20bf1249 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:python-cffi-debugsource0:1.14.3-2.module+el8.4.0+9822+20bf1249 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:python-chardet0:3.0.4-19.module+el8.4.0+9822+20bf1249 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:python-cryptography0:3.3.1-2.module+el8.4.0+9822+20bf1249 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:python-PyMySQL0:0.10.1-2.module+el8.4.0+9822+20bf1249 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:PyYAML0:5.4.1-1.module+el8.5.0+10613+59a13ec4 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:PyYAML-debugsource0:5.4.1-1.module+el8.5.0+10613+59a13ec4 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:rh-python38-python-lxml0:4.4.1-8.el7 · Red Hat:rhel_software_collections:3::el7Package registry (OSV)
red hat:rh-python38-python-lxml-debuginfo0:4.4.1-8.el7 · Red Hat:rhel_software_collections:3::el7Package registry (OSV)
rocky linux:Cython0:0.29.21-5.module+el8.4.0+574+843c4898 · Rocky Linux:8Package registry (OSV)
rocky linux:mod_wsgi0:4.7.1-4.module+el8.4.0+574+843c4898 · Rocky Linux:8Package registry (OSV)

+22

Exploit status

No known public exploit

No public exploit has been observed yet. That doesn't mean you're safe, only that the bar is a little higher.

Research context

For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.

Timeline

From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.

No dated events beyond publication.

EPSS, last 120 days

FIRST EPSS daily score; only changes of 0.01 or more are recorded (step chart).

Patch and commit links

Commit, PR and diff links among the references. A starting point for patch-diffing and variant hunting; fixes, not exploits.

Finders, reporters and analysts named in the CNA record. Click a name for that researcher’s other records.

No credits in the CNA record.

Variant candidates

Same product, same weakness class, within 18 months. If the patch missed the root cause, the sibling bug is here.

No nightly-computed relations.

Chain candidates

An authentication bypass and a privilege-requiring bug in the same product, published close together: combined they may become an unauthenticated path.

—

Bug bounty scope

No known public program.

Source: bounty-targets-data (public HackerOne, Bugcrowd, Intigriti, YesWeHack listings).

Technical details

Attack conditions

  • Anyone who can reach it over the internet can trigger it.
  • No account or password is required.
  • A user must open a link or visit a page.
  • No special conditions are required; it is repeatable.

If successful

Confidentiality
low · data can be read
Integrity
low · data or configuration can be modified
Availability
low · the service can be disrupted

Impact can extend beyond the vulnerable component (scope changes).

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
Required
Scope
Changed
Confidentiality impact
Low
Integrity impact
Low
Availability impact
Low

CVSS vector

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

nvd-primary

Change log

  1. Fix✗ → ✓

For records you follow, these changes also arrive as notifications. →

References

All records