Skip to content
OpenAdvisories
High · 7.5 CVE-2026-105782 EUVD-2026-92869GHSA-cwxj-rr6w-m6w7PYSEC-2026-4299

Scrapy: Arbitrary Module Import via Referrer-Policy Header in RefererMiddleware

Published Oct 5, 2026 · Updated Oct 6, 2026 · Assigned by GitHub_M

Description

Scrapy is a high-level web crawling and scraping framework for Python. From 1.4.0 until 2.14.2, RefererMiddleware in scrapy/spidermiddlewares/referer.py treated a Referrer-Policy response-header value that resembled a Python import path as a referrer policy class, imported the referenced object, and called it. A malicious website could supply a callable such as sys.exit and terminate a crawler processing the response. This issue is fixed in version 2.14.2.

Affected products

VendorProductAffectedFixed
scrapy scrapy >= 1.4.0, < 2.14.2 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 python-scrapy 2.14.2-1 —
Debian 13 python-scrapy No fix yet —
Debian 12 python-scrapy No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 26.04 LTS python-scrapy No fix yet —
Ubuntu 16.04 LTS python-scrapy No fix yet —
Show 4 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu Pro 24.04 LTS python-scrapy No fix yet —
Ubuntu Pro 22.04 LTS python-scrapy No fix yet —
Ubuntu Pro 20.04 LTS python-scrapy No fix yet —
Ubuntu Pro 18.04 LTS python-scrapy No fix yet —

Affected packages

EcosystemPackageAffectedFixedRecord
PyPI scrapy >= 1.4.0, < 2.14.2 2.14.2 GHSA-cwxj-rr6w-m6w7

References