CVE-2019-12781
Django Incorrect HTTP detection with reverse-proxy connecting via HTTPS
Reported by mitre · Published July 1, 2019
Django is fixed in 2.2.3, 2.1.10 and 1.11.22 (PyPI)
An issue was discovered in Django 1.11 before 1.11.22, 2.1 before 2.1.10, and 2.2 before 2.2.3. An HTTP request is not redirected to HTTPS when the SECURE_PROXY_SSL_HEADER and SECURE_SSL_REDIRECT settings are used, and the proxy connects to Django via HTTPS. In other words, django.http.HttpRequest.scheme has incorrect behavior when a client uses HTTP.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| Django | PyPI | 2.2.3, 2.1.10, 1.11.22 |
| py3-django | Alpine | 1.11.22-r0 |
| py-django | Alpine | 1.11.22-r0 |
| python-django | Ubuntu:16.04:LTS | 1.8.7-1ubuntu5.9 |
| django | djangoproject | 2.2.3, 2.1.10, 1.11.22 |
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| n/a | n/a | n/a |
| alpine | py3-django | 0 |
| alpine | py-django | 0 |
| n/a | n/a | * |
| arch | python-django | 0 |
| PyPI | Django | 2.1, 2.2, 1.11 |
Timeline
- Jul 1, 2019 CVE Published
- Apr 14, 2021 EPSS Score (30 in total, the first dated here)
- Sep 18, 2024 CVE Updated
- Mar 6, 2026 Distribution Patch (2 in total, the first dated here)
- Mar 6, 2026 Security Advisory (7 in total, the first dated here)
- Sep 15, 2026 Coalition ESS Score
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2019-12781
vulnetix vdb fixes CVE-2019-12781
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2019-12781/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- x_refsource_MISC
- x_refsource_MISC
- x_refsource_CONFIRM
- [oss-security] 20190701 Django: CVE-2019-12781: Incorrect HTTP detection with reverse-proxy connecting via HTTPS mailing-listx_refsource_MLIST
- USN-4043-1 vendor-advisoryx_refsource_UBUNTU
- 109018 vdb-entryx_refsource_BID
- x_refsource_CONFIRM
- DSA-4476 vendor-advisoryx_refsource_DEBIAN
- 20190708 [SECURITY] [DSA 4476-1] python-django security update mailing-listx_refsource_BUGTRAQ
- FEDORA-2019-d9aa58d863 vendor-advisoryx_refsource_FEDORA
- openSUSE-SU-2019:1839 vendor-advisoryx_refsource_SUSE
- openSUSE-SU-2019:1872 vendor-advisoryx_refsource_SUSE
- https://nvd.nist.gov/vuln/detail/CVE-2019-12781 advisory
- https://github.com/advisories/GHSA-6c7v-2f49-8h26 advisory
- https://docs.djangoproject.com/en/dev/releases/security url
- https://github.com/django/django url
- https://github.com/pypa/advisory-database/tree/main/vulns/django/PYSEC-2019-10.yaml advisory
- https://groups.google.com/forum/#!topic/django-announce/Is4kLY9ZcZQ url
- https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/5VXXWIOQGXOB7JCGJ3CVUW673LDHKEYL url
- https://security.netapp.com/advisory/ntap-20190705-0002 advisory
…and 2 more