A HITCON wargame write-up demonstrated that disclosure of a Django application's SECRET_KEY can enable remote code execution when the application uses signed-cookie sessions backed by Python Pickle serialization. Django signs serialized cookie data with an HMAC-SHA1 value derived from the secret key, intended to prevent clients from modifying session content.
An attacker with the exposed key can generate a valid signature for a crafted cookie containing a malicious Pickle object. If the server accepts and deserializes that cookie, the payload executes in the application process, turning a configuration-secret leak into server compromise. Organizations using legacy Django signed-cookie or Pickle-based session handling should rotate exposed keys, invalidate existing sessions, and eliminate unsafe deserialization.

See affected versions and whether adversaries are exploiting it.
1 event from the most recent confirmed update back to the earliest known activity.
A “Pwn3d 500” example presented at tw.PyCon.org 2013 demonstrated that disclosure of a Django SECRET_KEY could let an attacker forge HMAC-SHA1-signed cookies containing malicious Pickle payloads, resulting in remote code execution when deserialized.
See whether adversaries are exploiting this yet, and where the affected versions run in your environment.
3 references tracked. Mallory keeps watching after this page renders.
mochazz.github.io
Open sourceblog.orange.tw
Open sourcectftime.org
Open sourceMap indicators from this story to your assets and identify affected systems in minutes.
Every observed campaign, victim, and pivot linked to actors named in this story.
Malware, exploits, and IOCs connected to the activity described here.
YARA, Sigma, and Snort rules deployed to your SIEM as soon as they’re published.
Get matching new stories delivered to your team as they break — not the next morning.
Ask questions about this story and take action on the answers.