CVE-2021-4305 Woorank robots-txt-guard patterns.js makePathPattern redos
An attacker can cause a denial of service in the Woorank robots-txt-guard library by triggering inefficient regular expression complexity in the makePathPattern function.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2021-4305?
CVE-2021-4305 is a low-severity denial of service vulnerability in Woorank robots-txt-guard, published on 5 Jan 2023. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
A vulnerability was found in Woorank robots-txt-guard. It has been rated as problematic. Affected by this issue is the function makePathPattern of the file lib/patterns.js. The manipulation of the argument pattern leads to inefficient regular expression complexity. The exploit has been disclosed to the public and may be used. The name of the patch is c03827cd2f9933619c23894ce7c98401ea824020. It is recommended to apply a patch to fix this issue. The identifier of this vulnerability is VDB-217448.
Weakness: CWE-1333
Which versions are affected by CVE-2021-4305?
2 open source packages ship an affected version, including robots-txt-guard. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
robots-txt-guard npm | All versions | 1.0.2 |
robots-txt-guard npm | All versions | 1.0.2 |
Products include Bridgeline Robots-Txt-Guard.
How do I fix CVE-2021-4305?
Upgrade robots-txt-guard to 1.0.2 or later.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2021-4305 being exploited?
There is no known exploitation of CVE-2021-4305 in the wild and no public exploit code.
Sources
Also known as GHSA-6g33-8w2q-4hxv.