
Deserialization turns stored or transmitted data back into objects. When an application deserializes data an attacker can control, using formats such as Java serialization, PHP serialize, Python pickle or .NET formatters, the attacker may be able to run code on the server.
The attacker sends a crafted serialized object, often in a cookie, a hidden field or an API body. During deserialization, "gadget" classes that already exist in the application's libraries are chained together to perform actions, up to executing commands.
Deserializers can create objects and call their methods. Attackers chain existing library classes (gadgets) to run commands during deserialization.
Plain JSON with a strict schema is much safer than native object serialization, but polymorphic JSON libraries can still be abused if misconfigured.
Try Vooki Pro free for 7 days
Deserialization bugs lead straight to code execution. Find them early. The trial unlocks every feature for 7 days, and scanning runs on your own machine.
Related: JSON Web Token (JWT) vulnerabilities · HTTP request smuggling