GHSA-pvg3-6q9j-mj3x: Infoleak
Impact When a Django Model instance is assigned to a public view attribute, djust serialized it to the client with no sensitive-field denylist — sending fields such as password (the hash), privilege flags (e.g. isstaff / issuperuser), tokens, and other PII to the browser. Because exposing model objects to templates is a normal djust pattern, this could leak credentials/PII without the developer realizing the full object crossed the wire.
Patches Fixed in djust 1.0.7. Model serialization applies a secure-by-default sensitive-field denylist (password/hash/token/secret-style fields and known privilege flags are withheld) with an identity-subset fallback.
Workarounds Keep Model instances on private attributes and expose only the specific fields needed, until patched.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
pip/djustto a version that resolves this vulnerability.Fixed in 1.0.7 - Upgrade
Upgrade
djustto a version that resolves this vulnerability.Fixed in 1.0.7 - Configuration
Until patched, keep Django `Model` instances on `_private` attributes and expose only the specific fields needed; do not assign a `Model` to a public view attribute that will be serialized to the client.
djust templates/view exposure Keep Django Model instances on _private attributes and expose only specific fields = Use _private attributes and limit exposed fields
Event History
Frequently Asked Questions
Which applications are exposed to this issue?
Applications using djust are exposed when a Django Model instance is assigned to a public view attribute. This is a normal djust pattern, so affected applications may unintentionally send the entire model object to the browser.
What does an attacker need to exploit the issue?
An attacker needs network access to a page that serializes a Django Model through a public view attribute. No user interaction is required, but the CVSS vector indicates low privileges are required.
What should teams do if they cannot update immediately?
Keep Django Model instances on _private attributes and expose only the specific fields required by the client. This avoids public serialization of the full model object.
How is this addressed in djust?
The issue is fixed in djust 1.0.7. The fix adds a secure-by-default denylist for sensitive field names, including password, hash, token, secret-style fields, and known privilege flags, with an identity-subset fallback.