
CVE catalog
CVE-2026-87975
An issue was discovered in Django 6.1 before 6.1.2, 6.0 before 6.0.9, and 5.2 before 5.2.18. `django.forms.models.BaseModelFormSet.save_existing_objects()` used the presence of a primary key on a subm
- Severity
- Medium · CVSS 6.5
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N - Published
- Updated
- Source
- [NVD] · [CVE record]
- EPSS
- 0.23% · Oct 27, 2026
An issue was discovered in Django 6.1 before 6.1.2, 6.0 before 6.0.9, and 5.2 before 5.2.18. `django.forms.models.BaseModelFormSet.save_existing_objects()` used the presence of a primary key on a submitted form's instance as evidence that the instance belonged to the formset's limiting queryset. An object outside that queryset is represented by a newly constructed instance whose primary key can still be populated from submitted data when the model's primary key is a field accepted by the form, such as a `OneToOneField` or parent link used as the primary key of an inline formset's model, or a natural or UUID primary key included in the form's fields. This allows an authenticated user permitted to submit such a formset to delete rows outside the limiting queryset, without any permission on the targeted object, via forged management-form data marking an out-of-queryset object for deletion. Models using the default AutoField primary key are not affected. Earlier, unsupported Django series (such as 5.1.x, 5.0.x, and 4.2.x) were not evaluated and may also be affected. Django would like to thank Seonggwon Yoon for reporting this issue.
Vulnerable and fixed packages
Distribution-reported package versions and fixes. These do not depend on matching against the OpenFactory package catalog.
| Distribution | Package | Release | Version | Status |
|---|---|---|---|---|
| Debian | python-django | sid | 3:5.2.18-2 | fixed |
| Debian | python-django | forky | 3:5.2.17-2 | vulnerable |
| Debian | python-django | trixie | 3:4.2.28-0+deb13u2 | vulnerable |
| Debian | python-django | trixie-security | 3:4.2.28-0+deb13u1 | vulnerable |
| Debian | python-django | bookworm | 3:3.2.25-0+deb12u3 | vulnerable |
| Debian | python-django | bookworm-security | 3:3.2.25-0+deb12u6 | fixed |
Fixed-version evidence
| Distribution | Package | Type | Release | Fixed version | Urgency | Origin | Bugs |
|---|---|---|---|---|---|---|---|
| Debian | python-django | source | sid | 3:5.2.18-1 | not yet assigned | Not reported | [1150176] |
| Debian | python-django | source | forky | (unfixed) | not yet assigned | Not reported | [1150176] |
| Debian | python-django | source | trixie | (unfixed) | not yet assigned | Not reported | [1150176] |
| Debian | python-django | source | bookworm | 3:3.2.25-0+deb12u6 | not yet assigned | Not reported | [1150176] |
OpenFactory catalog packages
[Debian 12 (Bookworm)]
- [python3-django]Affected
Source package: [python-django]
Details (6)
3:3.2.25-0+deb12u3· all · bookwormAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:3.2.25-0+deb12u3· all · bookwormAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:4.2.21-1~bpo12+1· all · bookworm-backportsFixed · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:4.2.21-1~bpo12+1· all · bookworm-backportsFixed · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:3.2.25-0+deb12u4· all · bookworm-securityAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:3.2.25-0+deb12u4· all · bookworm-securityAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
- [python-django-doc]Affected
Source package: [python-django]
Details (6)
3:3.2.25-0+deb12u3· all · bookwormAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:3.2.25-0+deb12u3· all · bookwormAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:4.2.21-1~bpo12+1· all · bookworm-backportsFixed · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:4.2.21-1~bpo12+1· all · bookworm-backportsFixed · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:3.2.25-0+deb12u4· all · bookworm-securityAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
3:3.2.25-0+deb12u4· all · bookworm-securityAffected · Fixed:
3:3.2.25-0+deb12u6nvd · python-django · debian · bookworm; nvd · python-django · debian · 12
[Debian 13 (Trixie)]
- [python3-django]Affected
Source package: [python-django]
Details (6)
3:4.2.28-0+deb13u2· all · trixieAffected
nvd · python-django · debian · 13
3:4.2.28-0+deb13u2· all · trixieAffected
nvd · python-django · debian · 13
3:5.2.16-1~bpo13+1· all · trixie-backportsAffected
nvd · python-django · debian · 13
3:5.2.16-1~bpo13+1· all · trixie-backportsAffected
nvd · python-django · debian · 13
3:4.2.28-0+deb13u1· all · trixie-securityAffected
nvd · python-django · debian · 13
3:4.2.28-0+deb13u1· all · trixie-securityAffected
nvd · python-django · debian · 13
- [python-django-doc]Affected
Source package: [python-django]
Details (6)
3:4.2.28-0+deb13u2· all · trixieAffected
nvd · python-django · debian · 13
3:4.2.28-0+deb13u2· all · trixieAffected
nvd · python-django · debian · 13
3:5.2.16-1~bpo13+1· all · trixie-backportsAffected
nvd · python-django · debian · 13
3:5.2.16-1~bpo13+1· all · trixie-backportsAffected
nvd · python-django · debian · 13
3:4.2.28-0+deb13u1· all · trixie-securityAffected
nvd · python-django · debian · 13
3:4.2.28-0+deb13u1· all · trixie-securityAffected
nvd · python-django · debian · 13
Observed:
References
- [https://ftp.suse.com/pub/projects/security/csaf/opensuse-su-2026_12086-1.json]
- [https://nvd.nist.gov/vuln/detail/CVE-2026-87975]
- [https://osv.dev/vulnerability/DEBIAN-CVE-2026-87975]
- [https://security-tracker.debian.org/tracker/CVE-2026-87975]
- [https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-87975.json]
- [https://wid.cert-bund.de/.well-known/csaf/white/2026/wid-sec-w-2026-3780.json]
[CERT-Bund public advisories] · [Debian Security Tracker] · [FIRST EPSS] · [National Vulnerability Database (NVD)] · [OSV Package Vulnerability Database] · [Red Hat security advisories and VEX] · [SUSE security advisories and VEX]