Every CVE Search/ Get API key

CVE-2016-2512

Django XSS Vulnerability

7.4 HighFix available

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
None
User interaction
Required

What an attacker can affect

Confidentiality
None
Integrity
High
Availability
None

Exploit likelihood

4.05%Up 0.6 points since Feb 4, 2022
90%50%10%1%

What each source reports

NVD Score used 7.4

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
CVE-2016-2512
CVSS 3.0
7.4 HighCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
CVSS 2.0
4.3 MediumAV:N/AC:M/Au:N/C:N/I:P/A:N
Weakness
CWE-79
Updated
2026-11-02
CVE List No score

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
CVE-2016-2512
Updated
2026-11-02
EUVDEUVD-2016-0004 No score

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
EUVD-2016-0004
Updated
2026-11-03
GitHub AdvisoriesGHSA-pw27-w7w4-9qc7 6.3

Django XSS Vulnerability

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com\@attacker.com.

Record
GHSA-pw27-w7w4-9qc7
CVSS 4.0
6.3 MediumCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:N/SI:H/SA:N
CVSS 3.0
7.4 HighCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Weakness
CWE-79
Updated
2026-11-02
OSV 7.4

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
CVE-2016-2512
CVSS 3.0
7.4 HighCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Updated
2026-11-02
OSVDEBIAN-CVE-2016-2512 7.4

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
DEBIAN-CVE-2016-2512
CVSS 3.0
7.4 HighCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Updated
2026-11-02
Show 9 moreShow less
OSVGHSA-pw27-w7w4-9qc7 6.3

Django XSS Vulnerability

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com\@attacker.com.

Record
GHSA-pw27-w7w4-9qc7
CVSS 4.0
6.3 MediumCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:N/SI:H/SA:N
CVSS 3.0
7.4 HighCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Weakness
CWE-79
Updated
2026-11-02
OSVUBUNTU-CVE-2016-2512 7.4

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
UBUNTU-CVE-2016-2512
CVSS 3.0
7.4 HighCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Updated
2026-11-02
OSVMGASA-2016-0096 No score

Updated python-django packages fix security vulnerability

Mark Striemer discovered that Django incorrectly handled user-supplied redirect URLs containing basic authentication credentials. A remote attacker could possibly use this issue to perform a cross-site scripting attack or a malicious redirect. (CVE-2016-2512)

Sjoerd Job Postmus discovered that Django incorrectly handled timing when doing password hashing operations. A remote attacker could possibly use this issue to perform user enumeration. (CVE-2016-2513)

Record
MGASA-2016-0096
Updated
2026-11-02
OSVopenSUSE-SU-2024:10361-1 No score

python3-Django-1.10.4-1.1 on GA media

These are all security issues fixed in the python3-Django-1.10.4-1.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:10361-1
Updated
2026-11-02
OSVPYSEC-2016-15 No score

The utils.http.is_safe_url function in Django before 1.8.10 and 1.9.x before 1.9.3 allows remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication, as demonstrated by http://mysite.example.com@attacker.com.

Record
PYSEC-2016-15
Updated
2026-11-02
OSVSUSE-SU-2018:1102-1 No score

Security update for python-Django

This update for python-Django fixes the following issues:

Security issues fixed:

  • CVE-2018-7537: Fixed catastrophic backtracking in django.utils.text.Truncator. (bsc#1083305)
  • CVE-2018-7536: Fixed catastrophic backtracking in urlize and urlizetrunc template filters. (bsc#1083304)
  • CVE-2017-12794: Fixed XSS possibility in traceback section of technical 500 debug page (bsc#1056284)
  • CVE-2017-7234: Open redirect vulnerability in django.views.static.serve() (bsc#1031451)
  • CVE-2017-7233: Open redirect and possible XSS attack via user-supplied numeric redirect URLs (bsc#1031450)
  • CVE-2016-9014: DNS rebinding vulnerability when DEBUG=True (bsc#1008047)
  • CVE-2016-9013: User with hardcoded password created when running tests on Oracle (bsc#1008050)
  • CVE-2016-7401: CSRF protection bypass on a site with Google Analytics (bsc#1001374)
  • CVE-2016-2512: Vulnerability in the function tils.http.is_safe_url could allow remote users to arbitrary web site and conduct phishing attacks. (bsc#bnc#967999)
Record
SUSE-SU-2018:1102-1
Updated
2026-11-02
OSVSUSE-SU-2018:1828-1 No score

Security update for python-Django

This update for python-Django fixes the following security issues:

  • CVE-2016-2512: The utils.http.is_safe_url function allowed remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication (bsc#967999).
  • CVE-2018-7536: The django.utils.html.urlize() function was extremely slow to evaluate certain inputs due to catastrophic backtracking vulnerabilities (bsc#1083304)
  • CVE-2018-7537: If django.utils.text.Truncator's chars() and words() methods were passed the html=True argument, they were extremely slow to evaluate certain inputs due to a catastrophic backtracking vulnerability in a regular expression (bsc#1083305)
Record
SUSE-SU-2018:1828-1
Updated
2026-11-02
OSVSUSE-SU-2018:1830-1 No score

Security update for python-Django

This update for python-Django fixes the following security issues:

  • CVE-2016-2512: The utils.http.is_safe_url function allowed remote attackers to redirect users to arbitrary web sites and conduct phishing attacks or possibly conduct cross-site scripting (XSS) attacks via a URL containing basic authentication (bsc#967999).
  • CVE-2018-7536: The django.utils.html.urlize() function was extremely slow to evaluate certain inputs due to catastrophic backtracking vulnerabilities (bsc#1083304).
  • CVE-2018-7537: If django.utils.text.Truncator's chars() and words() methods were passed the html=True argument, they were extremely slow to evaluate certain inputs due to a catastrophic backtracking vulnerability in a regular expression (bsc#1083305).
Record
SUSE-SU-2018:1830-1
Updated
2026-11-02
OSVUSN-2915-1 No score

python-django vulnerabilities

Mark Striemer discovered that Django incorrectly handled user-supplied redirect URLs containing basic authentication credentials. A remote attacker could possibly use this issue to perform a cross-site scripting attack or a malicious redirect. (CVE-2016-2512)

Sjoerd Job Postmus discovered that Django incorrectly handled timing when doing password hashing operations. A remote attacker could possibly use this issue to perform user enumeration. (CVE-2016-2513)

Record
USN-2915-1
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
django
PyPI
before 1.8.10
1.8.10
django
PyPI
1.9a1 up to 1.9.3
1.9.3
python-django
Debian:12
before 1.9.4-1
1.9.4-1
python-django
Debian:13
before 1.9.4-1
1.9.4-1
python-django
Debian:14
before 1.9.4-1
1.9.4-1
python-django
Debian:7
before 1.4.5-1+deb7u16, plus listed versions
1.4.5-11.4.5-1+deb7u11.4.5-1+deb7u101.4.5-1+deb7u111.4.5-1+deb7u11~bpo60+1
Show 17 moreShow less
1.4.5-1+deb7u121.4.5-1+deb7u131.4.5-1+deb7u13~bpo60+11.4.5-1+deb7u141.4.5-1+deb7u14~bpo60+11.4.5-1+deb7u151.4.5-1+deb7u21.4.5-1+deb7u31.4.5-1+deb7u41.4.5-1+deb7u4~bpo60+11.4.5-1+deb7u51.4.5-1+deb7u61.4.5-1+deb7u71.4.5-1+deb7u7~bpo60+11.4.5-1+deb7u81.4.5-1+deb7u8~bpo60+11.4.5-1+deb7u9
1.4.5-1+deb7u16
python-django
Debian:8
before 1.7.7-1+deb8u4, plus listed versions
1.7.7-11.7.7-1+deb8u11.7.7-1+deb8u21.7.7-1+deb8u3
1.7.7-1+deb8u4
django
PyPI
before 1.8.10, plus listed versions
1.0.11.0.21.0.31.0.41.1
Show 45 moreShow less
1.1.11.1.21.1.31.1.41.21.2.11.2.21.2.31.2.41.2.51.2.61.2.71.31.3.11.3.21.3.31.3.41.3.51.3.61.3.71.41.4.11.4.101.4.111.4.121.4.131.4.141.4.151.4.161.4.171.4.181.4.191.4.21.4.201.4.211.4.221.4.31.4.41.4.51.4.61.4.71.4.81.4.91.51.5.1
1.8.10
django
PyPI
1.9a1 up to 1.9.3, plus listed versions
1.91.9.11.9.21.9b11.9rc11.9rc2
1.9.3
python-django
Mageia:5
before 1.8.10-1.mga5
1.8.10-1.mga5
Show 20 moreShow less
Affected packages
PackageAffectedFixed
django
PyPI
before 1.8.10, 1.9 up to 1.9.3, plus listed versions
1.0.11.0.21.0.31.0.41.1
Show 45 moreShow less
1.1.11.1.21.1.31.1.41.21.2.11.2.21.2.31.2.41.2.51.2.61.2.71.31.3.11.3.21.3.31.3.41.3.51.3.61.3.71.41.4.11.4.101.4.111.4.121.4.131.4.141.4.151.4.161.4.171.4.181.4.191.4.21.4.201.4.211.4.221.4.31.4.41.4.51.4.61.4.71.4.81.4.91.51.5.1
1.8.101.9.3
python-django
Red Hat:openstack:5::el6
before 0:1.6.11-5.el6ost
0:1.6.11-5.el6ost
python-django-bash-completion
Red Hat:openstack:5::el6
before 0:1.6.11-5.el6ost
0:1.6.11-5.el6ost
python-django-doc
Red Hat:openstack:5::el6
before 0:1.6.11-5.el6ost
0:1.6.11-5.el6ost
python-django
Red Hat:openstack-optools:7::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django-bash-completion
Red Hat:openstack-optools:7::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django
Red Hat:openstack:7::el7
before 0:1.8.11-1.el7ost
0:1.8.11-1.el7ost
python-django-bash-completion
Red Hat:openstack:7::el7
before 0:1.8.11-1.el7ost
0:1.8.11-1.el7ost
python-django-doc
Red Hat:openstack:7::el7
before 0:1.8.11-1.el7ost
0:1.8.11-1.el7ost
python-django
Red Hat:openstack:6::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django-bash-completion
Red Hat:openstack:6::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django-doc
Red Hat:openstack:6::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django
Red Hat:openstack:5::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django-bash-completion
Red Hat:openstack:5::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-django-doc
Red Hat:openstack:5::el7
before 0:1.6.11-5.el7ost
0:1.6.11-5.el7ost
python-Django
SUSE:OpenStack Cloud 6
before 1.8.19-3.6.1
1.8.19-3.6.1
python-Django
SUSE:Enterprise Storage 4
before 1.6.11-5.5.1
1.6.11-5.5.1
python-Django
SUSE:Enterprise Storage 5
before 1.6.11-6.5.1
1.6.11-6.5.1
python-django
Ubuntu:14.04:LTS
before 1.6.1-2ubuntu0.12, plus listed versions
1.5.4-1ubuntu11.6-11.6.1-11.6.1-21.6.1-2ubuntu0.1
Show 9 moreShow less
1.6.1-2ubuntu0.21.6.1-2ubuntu0.31.6.1-2ubuntu0.41.6.1-2ubuntu0.51.6.1-2ubuntu0.61.6.1-2ubuntu0.81.6.1-2ubuntu0.91.6.1-2ubuntu0.101.6.1-2ubuntu0.11
1.6.1-2ubuntu0.12
python-Django
openSUSE:Tumbleweed
before 1.10.4-1.1
1.10.4-1.1

History

History
RecordedChangedSources
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2016-2512 is a high vulnerability (CVSS 7.4) in Djangoproject Django, published March 1, 2016. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 4.05%, the 90th percentile. Fixed in django 1.8.10.

References

Show 62 moreShow less
This page doesn't list everything

Left out here: 102 versions. The JSON record has them.

MoveEnter Open