Skip to content
DoS Advisory Intermediate

GHSL-2020-304: ReDoS (Regular Expression Denial of Service) in CyberChef

A regular expression used to extract email addresses in CyberChef was vulnerable to catastrophic backtracking, causing exponential runtime. An attacker could supply a crafted input to make the application consume excessive CPU, leading to denial of service.

ghsecuritylab Follow

Originally disclosed on GitHub Security Lab

The project contains one or more regular expressions that are vulnerable to ReDoS (Regular Expression Denial of Service)

ghsecuritylab, on GitHub Security Lab

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the email-extraction regular expression contains overlapping or ambiguous clauses that allow exponential backtracking on crafted input.

Impact

This issue may lead to a denial of service.

What the attacker needed

Ability to supply input to the email extraction operation

The fix

The issue was fixed.

How it was found

  1. Open the provided CyberChef URL with the crafted input.
  2. Observe CPU usage spike.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A regular expression is a pattern used to search text. Some patterns can be written so that, for certain inputs, the computer tries an enormous number of ways to match, taking far too long. Here, a crafted input could make CyberChef freeze or slow down badly, which is a denial of service.

What is DoS?

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.

More by ghsecuritylab

View all

132 more disclosed reports, best first.

More from GitHub Security Lab

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Denial of service

The lesson behind this report.

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.