CVE-2024-1968
HIGH 7.5CVSS 3.0Scrapy leaks the authorization header on same-domain but cross-origin redirects
In scrapy/scrapy, an issue was identified where the Authorization header is not removed during redirects that only change the scheme (e.g., HTTPS to HTTP) but remain within the same domain. This behavior contravenes the Fetch standard, which mandates the removal of Authorization headers in cross-origin requests when the scheme, host, or port changes. Consequently, when a redirect downgrades from HTTPS to HTTP, the Authorization header may be inadvertently exposed in plaintext, leading to potential sensitive information disclosure to unauthorized actors. The flaw is located in the _build_redirect_request function of the redirect middleware.
- Published
- 20 May 2024
- Last modified
- 17 Jun 2026
- Assigned by
- security@huntr.dev
- NVD status
- Analyzed
- Weakness
- CWE-200
- Also known as
- GHSA-4qqq-9vqf-3h3fPYSEC-2024-258
- Sources
- NVDJSONOSV GHSA-4qqq-9vqf-3h3fJSONOSV PYSEC-2024-258JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| OSV | GitHub | CVSS 3.1 | MEDIUM 5.9 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N |
| NVD | security@huntr.dev (Secondary) | CVSS 3.0 | HIGH 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | scrapy | scrapycpe:2.3:a:scrapy:scrapy:*:*:*:*:*:*:*:* |
<= 1.8.4 | |
| NVD | scrapy | scrapycpe:2.3:a:scrapy:scrapy:*:*:*:*:*:*:*:* |
>= 2.0.0, < 2.11.2 | 2.11.2 |
| OSV | PyPI | scrapy | < 2.11.2 | 2.11.2 |
| OSV | PyPI | scrapy | < 2.0.0; >= 2.0.0, < 2.11.2 | 2.0.0, 2.11.2 |
References
- https://github.com/scrapy/scrapy/commit/1d0502f25bbe55a22899af915623fda1aaeb9dd8 · Patch, WEB, FIX
- https://huntr.com/bounties/27f6a021-a891-446a-ada5-0226d619dd1a · Exploit, Third Party Advisory, WEB, EVIDENCE
- https://github.com/scrapy/scrapy/security/advisories/GHSA-4qqq-9vqf-3h3f · WEB
- https://github.com/scrapy/scrapy · PACKAGE
- https://github.com/advisories/GHSA-4qqq-9vqf-3h3f · ADVISORY
History
- 25 Nov 2026 20:55 UTC · NVD: first stored (published 20 May 2024)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 20 May 2024)
- 25 Nov 2026 20:11 UTC · OSV: first stored (published 14 May 2024)