CVE-2012-4520

The django.http.HttpRequest.get_host function in Django 1.3.x before 1.3.4 and 1.4.x before 1.4.2 allows remote attackers to generate and display arbitrary URLs via crafted username and password Host header values.

Published: 2012-11-18 Last update: 2026-04-29 Assigner: [email protected] Source: [email protected]

Conclusion & alert: CVE-2012-4520 is rated Moderate Risk (55.8/100): CVSS Medium severity, with medium exploitation likelihood (EPSS 3.89%). Mandatory action: Review affected assets and schedule remediation.

Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.

Exploit prediction scoring system (EPSS) score for CVE-2012-4520

EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).

# Date Old EPSS score New EPSS score Delta (New - Old)
1 2025-11-30 4.44% 3.89% -0.55%
2 2025-03-30 3.19% 4.44% +1.25%
3 2025-03-29 3.19%

Full EPSS history (6 records total)

Common vulnerability scoring system (CVSS) metrics for CVE-2012-4520

CVSS metrics for this CVE.

Base score Version Severity Vector Exploitability Impact Score source
6.4 2.0 MEDIUM
AV:N/AC:L/Au:N/C:P/I:P/A:N Click to expand
Access vector (AV:N)
Can be exploited remotely over network reachability.
Access complexity (AC:L)
Exploitation conditions are straightforward and predictable.
Authentication (AU:N)
No authentication is required.
Confidentiality impact (C:P)
Partial confidentiality impact.
Integrity impact (I:P)
Partial integrity impact.
Availability impact (A:N)
No availability impact.
10.0 4.9 [email protected]

Weakness enumeration for CVE-2012-4520

GitHub Security Advisory for CVE-2012-4520

GHSA-2655-q453-22f9 · Severity: high · Ecosystem: pip — Django Allows Arbitrary URL Generation

OS Trackers for CVE-2012-4520

vendor priority summary link
debian not yet assigned CVE-2012-4520 not yet assigned priority: Debian including 1 source packages (python-django), 5 status rows across 5 suites (bookworm, bullseye, forky, sid, trixie): resolved 5. https://security-tracker.debian.org/tracker/CVE-2012-4520
redhat medium https://access.redhat.com/security/cve/CVE-2012-4520
ubuntu medium CVE-2012-4520 medium priority: Ubuntu including 1 source packages (python-django), 6 status rows across 6 suites (hardy, lucid, oneiric, precise, quantal, upstream): released 5, ignored 1. https://ubuntu.com/security/CVE-2012-4520

Affected software / configurations for CVE-2012-4520

Vendor Product Version Raw CPE
djangoproject django 1.3 cpe:2.3:a:djangoproject:django:1.3:*:*:*:*:*:*:*
djangoproject django 1.3 cpe:2.3:a:djangoproject:django:1.3:alpha1:*:*:*:*:*:*
djangoproject django 1.3 cpe:2.3:a:djangoproject:django:1.3:beta1:*:*:*:*:*:*
djangoproject django 1.3.1 cpe:2.3:a:djangoproject:django:1.3.1:*:*:*:*:*:*:*
djangoproject django 1.3.2 cpe:2.3:a:djangoproject:django:1.3.2:*:*:*:*:*:*:*
djangoproject django 1.3.3 cpe:2.3:a:djangoproject:django:1.3.3:*:*:*:*:*:*:*
djangoproject django 1.4 cpe:2.3:a:djangoproject:django:1.4:*:*:*:*:*:*:*
djangoproject django 1.4.1 cpe:2.3:a:djangoproject:django:1.4.1:*:*:*:*:*:*:*

References for CVE-2012-4520

URL Tags
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=691145
http://lists.fedoraproject.org/pipermail/package-announce/2012-October/090666.html
http://lists.fedoraproject.org/pipermail/package-announce/2012-October/090904.html
http://lists.fedoraproject.org/pipermail/package-announce/2012-October/090970.html
http://secunia.com/advisories/51033 Vendor Advisory
http://secunia.com/advisories/51314 Vendor Advisory
http://securitytracker.com/id?1027708
http://ubuntu.com/usn/usn-1632-1
http://ubuntu.com/usn/usn-1757-1
http://www.debian.org/security/2013/dsa-2634
http://www.openwall.com/lists/oss-security/2012/10/30/4
http://www.osvdb.org/86493
https://bugzilla.redhat.com/show_bug.cgi?id=865164
https://github.com/django/django/commit/92d3430f12171f16f566c9050c40feefb830a4a3
https://github.com/django/django/commit/9305c0e12d43c4df999c3301a1f0c742264a657e
https://github.com/django/django/commit/b45c377f8f488955e0c7069cad3f3dd21910b071
https://www.djangoproject.com/weblog/2012/oct/17/security/ Patch Vendor Advisory
cvelogic Threat Intelligence