Bleach LIB Style Attr ReDoS via bleach.clean
CVE-2020-6817 Published on February 16, 2023

bleach.clean behavior parsing style attributes could result in a regular expression denial of service (ReDoS). Calls to bleach.clean with an allowed tag with an allowed style attribute are vulnerable to ReDoS. For example, bleach.clean(..., attributes={'a': ['style']}).

Github Repository NVD

Vulnerability Analysis

CVE-2020-6817 can be exploited with network access, and does not require authorization privileges or user interaction. This vulnerability is considered to have a low attack complexity. An automatable proof of concept (POC) exploit exists. The potential impact of an exploit of this vulnerability is considered to have no impact on confidentiality and integrity, and a high impact on availability.

Attack Vector:
NETWORK
Attack Complexity:
LOW
Privileges Required:
NONE
User Interaction:
NONE
Scope:
UNCHANGED
Confidentiality Impact:
NONE
Integrity Impact:
NONE
Availability Impact:
HIGH

Weakness Type

What is a ReDoS Vulnerability?

The product uses a regular expression with an inefficient, possibly exponential worst-case computational complexity that consumes excessive CPU cycles. Some regular expression engines have a feature called "backtracking". If the token cannot match, the engine "backtracks" to a position that may result in a different token that can match. Backtracking becomes a weakness if all of these conditions are met:

CVE-2020-6817 has been classified to as a ReDoS vulnerability or weakness.


Products Associated with CVE-2020-6817

stack.watch emails you whenever new vulnerabilities are published in Mozilla Bleach or Canonical Ubuntu Linux. Just hit a watch button to start following.

 
 

Affected Versions

Mozilla Bleach:

Vulnerable Packages

The following package name and versions may be associated with CVE-2020-6817

Package Manager Vulnerable Package Versions Fixed In
pip bleach < 3.1.4 3.1.4

Exploit Probability

EPSS
0.58%
Percentile
68.57%

EPSS (Exploit Prediction Scoring System) scores estimate the probability that a vulnerability will be exploited in the wild within the next 30 days. The percentile shows you how this score compares to all other vulnerabilities.