dumping agent
is a succinct project designed to extract JVM or specific packages along with their corresponding class files. Its current implementation strives to dump all class files, barring a few blacklisted default Java packages. However, be aware that this could potentially lead to a JVM crash, especially when obfuscation techniques are applied.
The inception of this project lies in the research requirements of jCloak. It was created to facilitate the development and testing of Java agent detection mechanisms, with the ultimate goal of safeguarding classes from Java agents.
There are usually two ways to start use a java agent.
- Start the JVM with the
-javaagent
flag and specify the java agent - Attach the java agent dynamically at runtime
For the first method you don't need anything except that flag. For the second method, please take a look at this project