CVE-2018-25045
MEDIUM 6.1CVSS 3.1Django REST framework XSS Vulnerability
Django REST framework (aka django-rest-framework) before 3.9.1 allows XSS because the default DRF Browsable API view templates disable autoescaping.
- Published
- 23 Jul 2022
- Last modified
- 7 Jul 2026
- Assigned by
- cve@mitre.org
- NVD status
- Modified
- Weakness
- CWE-79
- Also known as
- GHSA-xqcf-hj92-967mPYSEC-2026-804
- Sources
- NVDJSONOSV GHSA-xqcf-hj92-967mJSONOSV PYSEC-2026-804JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | MEDIUM 6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
| OSV | GitHub | CVSS 3.1 | MEDIUM 6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
| OSV | PyPA | CVSS 3.1 | MEDIUM 6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | django-rest-framework | django_rest_frameworkcpe:2.3:a:django-rest-framework:django_rest_framework:*:*:*:*:*:*:*:* |
< 3.9.1 | 3.9.1 |
| OSV | PyPI | django-rest-framework | < 3.9.1 | 3.9.1 |
References
- https://github.com/encode/django-rest-framework/commit/4bb9a3c48427867ef1e46f7dee945a4c25a4f9b8 · Patch, Third Party Advisory, WEB
- https://github.com/encode/django-rest-framework/pull/6191 · Third Party Advisory, WEB
- https://github.com/encode/django-rest-framework/pull/6330 · Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2018-25045 · ADVISORY
- https://github.com/encode/django-rest-framework · PACKAGE
- https://pypi.org/project/django-rest-framework · PACKAGE
- https://github.com/advisories/GHSA-xqcf-hj92-967m · ADVISORY
History
- 25 Nov 2026 20:34 UTC · NVD: first stored (published 23 Jul 2022)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 6 Jul 2026)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 24 Jul 2022)