CVE-2021-21416
Potential sensitive information disclosed in error reports
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
Attack profile
How easy it is to exploit
- Attack vector
- Local
- Complexity
- High
- Privileges needed
- High
- User interaction
- Required
What an attacker can affect
- Confidentiality
- Low
- Integrity
- Low
- Availability
- None
Exploit likelihood
What each source reports
CVE List Score used
3.7
Potential sensitive information disclosed in error reports
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
CVE-2021-21416- CVSS 3.1
- 3.7 Low
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:N - Weakness
- CWE-209
- Updated
- 2026-11-02
EUVDEUVD-2021-0057
3.7
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
EUVD-2021-0057- CVSS 3.1
- 3.7 Low
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:N - Updated
- 2026-11-03
GitHub AdvisoriesGHSA-58c7-px5v-82hh
2.0
Potential sensitive information disclosed in error reports
django-registration is a user-registration application for Django.
Impact
The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django.
Triggering this requires the following conditions:
- A site is using django-registration < 3.1.2
- The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled
- A server-side error (HTTP 5xx) occurs during an attempt by a user to register an account
Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
Patches
As of version 3.1.2, django-registration properly applies Django's sensitive_post_parameters() decorator to the base user-registration view, which will cause all data from the HTTP request body to be filtered from detailed error reports in the event of a server-side crash during user account registration.
Note that as applied, this filters all HTTP request data from error reports. To selectively allow some fields but not others, see Django's own documentation (in references) and the notes below for how to apply sensitive_post_parameters() manually to a particular codebase's RegistrationView subclass(es).
Workarounds
Users who cannot upgrade quickly can apply the django.views.decorators.debug.sensitive_post_parameters() decorator to their own registration views. The decorator should be applied on the dispatch() method of the appropriate RegistrationView class, using Django's method_decorator() helper. For example:
from django.utils.decorators import method_decorator
from django.views.decorators.debug import sensitive_post_parameters
from django_registration.views import RegistrationView
class MyRegistrationView(RegistrationView):
"""
A RegistrationView subclass manually protected against sensitive information disclosure
in error reports.
"""
@method_decorator(sensitive_post_parameters())
def dispatch(self, *args, **kwargs):
return super().dispatch(*args, **kwargs)
References
- Django's documentation on error reporting in production
- How Django's sensitive-data filters work
- Record
GHSA-58c7-px5v-82hh- CVSS 4.0
- 2.0 Low
CVSS:4.0/AV:N/AC:L/AT:P/PR:H/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N - CVSS 3.1
- 3.7 Low
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:N - Weakness
- CWE-201, CWE-209
- Updated
- 2026-11-02
NVD
3.7
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
CVE-2021-21416- CVSS 3.1
- 3.7 Low
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:N - CVSS 3.1
- 2.6 Low
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:L/I:N/A:N - CVSS 2.0
- 3.5 Low
AV:N/AC:M/Au:S/C:P/I:N/A:N - Weakness
- CWE-209
- Updated
- 2026-11-02
OSV
2.6
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
CVE-2021-21416- CVSS 3.1
- 2.6 Low
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:L/I:N/A:N - Updated
- 2026-11-02
OSVDEBIAN-CVE-2021-21416
2.6
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
DEBIAN-CVE-2021-21416- CVSS 3.1
- 2.6 Low
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:L/I:N/A:N - Updated
- 2026-11-02
Show 9 moreShow less
OSVGHSA-58c7-px5v-82hh
2.0
Potential sensitive information disclosed in error reports
django-registration is a user-registration application for Django.
Impact
The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django.
Triggering this requires the following conditions:
- A site is using django-registration < 3.1.2
- The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled
- A server-side error (HTTP 5xx) occurs during an attempt by a user to register an account
Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
Patches
As of version 3.1.2, django-registration properly applies Django's sensitive_post_parameters() decorator to the base user-registration view, which will cause all data from the HTTP request body to be filtered from detailed error reports in the event of a server-side crash during user account registration.
Note that as applied, this filters all HTTP request data from error reports. To selectively allow some fields but not others, see Django's own documentation (in references) and the notes below for how to apply sensitive_post_parameters() manually to a particular codebase's RegistrationView subclass(es).
Workarounds
Users who cannot upgrade quickly can apply the django.views.decorators.debug.sensitive_post_parameters() decorator to their own registration views. The decorator should be applied on the dispatch() method of the appropriate RegistrationView class, using Django's method_decorator() helper. For example:
from django.utils.decorators import method_decorator
from django.views.decorators.debug import sensitive_post_parameters
from django_registration.views import RegistrationView
class MyRegistrationView(RegistrationView):
"""
A RegistrationView subclass manually protected against sensitive information disclosure
in error reports.
"""
@method_decorator(sensitive_post_parameters())
def dispatch(self, *args, **kwargs):
return super().dispatch(*args, **kwargs)
References
- Django's documentation on error reporting in production
- How Django's sensitive-data filters work
- Record
GHSA-58c7-px5v-82hh- CVSS 4.0
- 2.0 Low
CVSS:4.0/AV:N/AC:L/AT:P/PR:H/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N - CVSS 3.1
- 3.7 Low
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:N - Weakness
- CWE-201, CWE-209
- Updated
- 2026-11-02
OSVUBUNTU-CVE-2021-21416
3.7
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
UBUNTU-CVE-2021-21416- CVSS 3.1
- 3.7 Low
CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:N - CVSS 3.1
- 2.6 Low
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:L/I:N/A:N - Updated
- 2026-11-02
OSVMGASA-2022-0178 No score
Updated python-django-registration packages fix security vulnerability
Sensitive data could be included in error reports (CVE-2021-21416)
- Record
MGASA-2022-0178- Updated
- 2026-11-02
OSVopenSUSE-SU-2021:0588-1 No score
Security update for python-django-registration
This update for python-django-registration fixes the following issues:
Update to 3.1.2 (boo#1184427, CVE-2021-21416)
- Filter sensitive POST parameters in error reports
- Fix RemovedInDjango40Warning from Signal arguments
- Record
openSUSE-SU-2021:0588-1- Updated
- 2026-11-02
OSVopenSUSE-SU-2021:0597-1 No score
Security update for python-django-registration
This update for python-django-registration fixes the following issues:
Update to 3.1.2 (boo#1184427, CVE-2021-21416)
- Filter sensitive POST parameters in error reports
- Fix RemovedInDjango40Warning from Signal arguments
This update was imported from the openSUSE:Leap:15.2:Update update project.
- Record
openSUSE-SU-2021:0597-1- Updated
- 2026-11-02
OSVopenSUSE-SU-2024:11226-1 No score
python36-django-registration-3.2-1.2 on GA media
These are all security issues fixed in the python36-django-registration-3.2-1.2 package on the GA media of openSUSE Tumbleweed.
- Record
openSUSE-SU-2024:11226-1- Updated
- 2026-11-02
OSVopenSUSE-SU-2024:14138-1 No score
python310-django-registration-3.3-2.2 on GA media
These are all security issues fixed in the python310-django-registration-3.3-2.2 package on the GA media of openSUSE Tumbleweed.
- Record
openSUSE-SU-2024:14138-1- Updated
- 2026-11-02
OSVopenSUSE-SU-2026:12007-1 No score
python313-django-registration-5.2.1-1.3 on GA media
These are all security issues fixed in the python313-django-registration-5.2.1-1.3 package on the GA media of openSUSE Tumbleweed.
- Record
openSUSE-SU-2026:12007-1- Updated
- 2026-11-02
OSVPYSEC-2021-11 No score
django-registration is a user registration package for Django. The django-registration package provides tools for implementing user-account registration flows in the Django web framework. In django-registration prior to 3.1.2, the base user-account registration view did not properly apply filters to sensitive data, with the result that sensitive data could be included in error reports rather than removed automatically by Django. Triggering this requires: A site is using django-registration < 3.1.2, The site has detailed error reports (such as Django's emailed error reports to site staff/developers) enabled and a server-side error (HTTP 5xx) occurs during an attempt by a user to register an account. Under these conditions, recipients of the detailed error report will see all submitted data from the account-registration attempt, which may include the user's proposed credentials (such as a password).
- Record
PYSEC-2021-11- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
django-registrationPyPI |
before 3.1.2 | 3.1.2 |
python-django-registrationDebian:12 |
before 3.3-1 | 3.3-1 |
python-django-registrationDebian:13 |
before 3.3-1 | 3.3-1 |
python-django-registrationDebian:14 |
before 3.3-1 | 3.3-1 |
django-registrationPyPI |
before 3.1.2, plus listed versions 0.50.60.70.81.0 Show 19 moreShow less2.02.0.12.0.22.0.32.0.42.12.1.12.1.22.22.32.42.4.12.52.5.12.5.23.03.0.13.13.1.1 |
3.1.2 |
python-django-registrationMageia:8 |
before 3.2-2.mga8 | 3.2-2.mga8 |
python-django-registrationUbuntu:16.04:LTS |
All versions, plus listed versions 1.0+dfsg-22.0.4-1 |
None known |
python-django-registrationUbuntu:18.04:LTS |
All versions, plus listed versions 2.2-12.2-2 |
None known |
python-django-registrationUbuntu:20.04:LTS |
All versions, plus listed versions 2.2-22.2-3 |
None known |
python-django-registrationUbuntu:22.04:LTS |
All versions, plus listed versions 2.2-5 |
None known |
Show 8 moreShow less
| Package | Affected | Fixed |
|---|---|---|
python-django-registrationUbuntu:24.04:LTS |
All versions, plus listed versions 3.3-1 |
None known |
python-django-registrationUbuntu:25.10 |
All versions, plus listed versions 3.3-1 |
None known |
python-django-registrationUbuntu:26.10 |
All versions, plus listed versions 3.3-1build1 |
None known |
python-django-registrationUbuntu:26.04:LTS |
All versions, plus listed versions 3.3-13.3-1build1 |
None known |
python-django-registrationopenSUSE:Leap 15.2 |
before 3.1.2-lp152.3.3.1 | 3.1.2-lp152.3.3.1 |
python-django-registrationSUSE:Package Hub 15 SP2 |
before 3.1.2-bp152.3.3.1 | 3.1.2-bp152.3.3.1 |
python-django-registrationopenSUSE:Tumbleweed |
before 3.3-2.2 | 3.3-2.2 |
python-django-registrationopenSUSE:Tumbleweed |
before 5.2.1-1.3 | 5.2.1-1.3 |
History
| Recorded | Changed | Sources |
|---|---|---|
| aliases | EUVD | |
| first indexed | CVE List, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2021-21416 is a low vulnerability (CVSS 3.7) in Django-registration Project Django-registration, published April 1, 2021. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.41%, the 35th percentile. Fixed in django-registration 3.1.2.
References
github.com/ubernostrum/django-registration/security/advisories/GHSA-58c7-px5v-82hh
nvd.nist.gov/vuln/detail/CVE-2021-21416
github.com/ubernostrum/django-registration/commit/2db0bb7ec35636ea46b07b146328b87b2cb13ca5
github.com/pypa/advisory-database/tree/main/vulns/django-registration/PYSEC-2021-11.yaml
github.com/advisories/GHSA-58c7-px5v-82hh
security-tracker.debian.org/tracker/CVE-2021-21416
Show 9 moreShow less
github.com/ubernostrum/django-registration
advisories.mageia.org/MGASA-2022-0178.html
bugs.mageia.org/show_bug.cgi?id=29052
lists.opensuse.org/archives/list/[email protected]/thread/2F72NF6ZBHDNQRLYZZFU7B52UQ4CZZRE
ubuntu.com/security/CVE-2021-21416
cve.org/CVERecord?id=CVE-2021-21416
bugzilla.suse.com/1184427
suse.com/security/cve/CVE-2021-21416
lists.opensuse.org/archives/list/[email protected]/thread/NL4XGVJ2AN5KEZDKGXRP3QKFGI24ETYA