CVE-2012-4520: Input Validation
It was reported that Django's built-in parsing of the Host header was incorrectly handling username/password information (in django.http.HttpRequest.gethost()). This could allow a remote attacker to cause parts of Django, in particular the password-reset mechanism, to generate and display arbitrary URLs to end-users.
Acknowledgements:
Red Hat would like to thank the upstream Django project for reporting this vulnerability.
Other sources
The django.http.HttpRequest.gethost 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.
— GitHub
The django.http.HttpRequest.gethost 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.
— MITRE
Affected Software
Remediation
Patch Available
Event History
Frequently Asked Questions
What is the severity of CVE-2012-4520?
CVE-2012-4520 is classified as a medium-severity vulnerability in Django.
How can I fix CVE-2012-4520?
To fix CVE-2012-4520, upgrade Django to version 1.4.2 or 1.3.4 or later.
Which versions of Django are affected by CVE-2012-4520?
Django versions 1.3 to 1.4.1 and earlier versions of 1.3 are affected by CVE-2012-4520.
What type of attack does CVE-2012-4520 enable?
CVE-2012-4520 allows remote attackers to exploit the incorrect handling of the Host header, potentially affecting authentication mechanisms.
Are there any specific components of Django vulnerable due to CVE-2012-4520?
Yes, particularly the password-reset mechanism in Django is vulnerable due to CVE-2012-4520.