Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/akashrpatil/awesome-offensive-security-skillsnpx agentmods add skills/akashrpatil/awesome-offensive-security-skills/java-insecure-deserialization-ysoserialWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/akashrpatil/awesome-offensive-security-skills/java-insecure-deserialization-ysoserial)<a href="https://agentmods.dev/skills/akashrpatil/awesome-offensive-security-skills/java-insecure-deserialization-ysoserial"><img src="https://agentmods.dev/badge/skills/akashrpatil/awesome-offensive-security-skills/java-insecure-deserialization-ysoserial/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/akashrpatil/awesome-offensive-security-skills/java-insecure-deserialization-ysoserial"><img src="https://agentmods.dev/badge/skills/akashrpatil/awesome-offensive-security-skills/java-insecure-deserialization-ysoserial.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00080 | $0.02506 |
| Opus 5.5 | $0.00032 | $0.01002 |
| Sonnet 5.5 | $0.00016 | $0.00501 |
| Haiku 4.5 | $0.00008 | $0.00251 |
Grade A, and why
java-insecure-deserialization-ysoserial scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
This is a copy
100% identical to java-insecure-deserialization-ysoserial — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.
How it starts
The opening of the file, as written. The whole thing — 177 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Java Insecure Deserialization (ysoserial)
When to Use
- When discovering a Java-based web application (e.g., WebLogic, JBoss, Tomcat) natively accepting arbitrary Base64-encoded strings beginning with
rO0AB...or raw binary streams containing the hex magic bytesAC ED 00 05. - During an advanced Black-box penetration test when simplistic web vulnerabilities (XSS/SQLi) are absent, and you require definitive Remote Code Execution (RCE) terminating directly traversing deep server-side logic fundamentally.
- To execute out-of-band (OOB) blindness testing leveraging DNS interactions inherently verifying that the backend architecture is systematically parsing and executing Java objects implicitly.
Prerequisites
- Authorized scope and target URLs from bug bounty program
- Burp Suite Professional (or Community) configured with browser proxy
- Familiarity with OWASP Top 10 and common web vulnerability classes
- SecLists wordlists for fuzzing and enumeration
Workflow
Phase 1: Identifying Java Serialized Objects (The Signatures)
# Concept: Serialization explicitly converts a complex Java Object (e.g., a 'User' class
# containing a username, ID, and permissions) perfectly into a flat byte stream identically.
# Deserialization converts that stream aggressively back into a living Object in the server's RAM.
# If the server deserializes any object provided by the user without validation, RCE occurs natively.
# 1. Base64 Encoded Format (Common in Cookies or Hidden Form Fields)
# Encoded String: `rO0ABXNyAA5qYXZhLmxhbmcu...`
# - `rO0AB` is the hallmark Base64 encoding exclusively translating the raw Java magic bytes.
# 2. Raw Binary / Hex Format (Common in raw TCP sockets or custom API calls)
# Magic Bytes: `AC ED 00 05`
# - Identifies the ObjectOutputStream natively written seamlessly utilizing the JVM protocol.
Phase 2: Understanding Gadget Chains
# Concept: We fundamentally cannot instruct the server to simply `Runtime.exec("calc.exe")`
# utilizing a custom class because the server lacks our custom class in its classpath.
# We MUST explicitly construct a "Gadget Chain" - a highly complex sequence of deeply nested,
# pre-existing classes already natively available identically on the remote server (e.g.,
# vulnerable versions of Apache CommonsCollections, Spring, Hibernate, Groovy).
# `ysoserial` automates the grueling task of precisely aligning these gadget chains perfectly
# formulating our explicit command.
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago First seen · 177 lines · 80 tokens per session scan A 3ea61f8248cd
java-insecure-deserialization-ysoserial is a skill published in the GitHub repository akashrpatil/awesome-offensive-security-skills (25 stars, last pushed 7mo ago), licensed Apache-2.0. It adds 80 tokens to every session and 2,506 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 100% identical to java-insecure-deserialization-ysoserial, differing in 0 lines, and is treated as a copy.
java-insecure-deserialization-ysoserial compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| java-insecure-deserialization-ysoserialakashrpatil/awesome-offensive-security-skills | Skill | 25 | 7mo ago | Apache-2.0 | A | 80 | Claude Code |
| java-insecure-deserialization-ysoserialShulkwiSEC/bb-huge | Skill | 27 | 4mo ago | MIT | A | 80 | Claude Code, Codex |
| upgrade-spring-bootPhaedra-Solutions/cursor-rules | Skill | 4 | 28d ago | MIT | A | 150 | Claude Code, Codex |
| exploiting-insecure-deserializationbalsm-health/Balsm-AI | Skill | 3 | 1mo ago | none | A | 37 | Claude Code |
| deserialization-javablacklanternsecurity/red-run | Skill | 312 | 18d ago | AGPL-3.0 | A | 15 | Claude Code, Codex |
| detecting-insecure-deserialization-vulnerabilitieswithcrux/agentHack-skills | Skill | 5 | 7mo ago | none | A | 62 | Claude Code, Codex |
| bugcrowd-reportingelementalsouls/Claude-BugHunter | Skill | 28k | 2d ago | MIT | A | 171 | Claude Code |