Live threats

All CVEs / Djangoproject

CVE-2020-7471Djangoproject Django

Critical 9.8 No auth neededHigh EPSS

Priority
80
CVSS 3.1
9.8
EPSS
65.6%
probability of exploitation in 30 days · percentile 99
Auth required
No
Published
Feb 3, 2020
Updated
Jun 17, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-89
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

What happens

Django 1.11 before 1.11.28, 2.2 before 2.2.10, and 3.0 before 3.0.3 allows SQL Injection if untrusted data is used as a StringAgg delimiter (e.g., in Django applications that offer downloads of data as a series of rows with a user-specified column delimiter). By passing a suitably crafted delimiter to a contrib.postgres.aggregates.StringAgg instance, it was possible to break escaping and inject malicious SQL.

Original NVD text.

What to do

  1. Apply the vendor's security update for Django.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
PyPI django < 1.11.28 1.11.28 pip install "django>=1.11.28"
PyPI django ≥ 2.0 < 2.2.10 2.2.10 pip install "django>=2.2.10"
PyPI django ≥ 3.0 < 3.0.3 3.0.3 pip install "django>=3.0.3"
PyPI django ≥ 1.11 < 1.11.28 1.11.28 pip install "django>=1.11.28"
PyPI django ≥ 2.2 < 2.2.10 2.2.10 pip install "django>=2.2.10"
PyPI django ≥ 3.0 < 3.0.3 3.0.3 pip install "django>=3.0.3"

Per OSV / GitHub Advisories (GHSA-hmr4-m2h5-33qx, PYSEC-2020-35). Check the version in your lockfile before upgrading.

Affected products (CPE)

VendorProductVersions
djangoprojectdjango≥ 1.11 < 1.11.28
djangoprojectdjango≥ 2.2 < 2.2.10
djangoprojectdjango≥ 3.0 < 3.0.3

Official advisories

Also: SUSE (+1)

Vendor, CERT and distribution advisories that name this CVE. Original titles.

Official sources

References

Links published by the sources. Open them with care.