GitHub - Rongmario/ImagineBreaker: Java 17 Hackery, destroys module system + ref...
source link: https://github.com/Rongmario/ImagineBreaker
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Imagine Breaker [幻想殺し]
I will destroy that illusion of yours.
(Disclaimer: use with care, I'll not be held responsible for your JVM burning up in flames)
Supports:
-
Breaking down the Java Platform Module System (JPMS) to allow Reflection into any base or requested modules
-
Removal of Reflection Filters, allows retrieval of any fields/methods from classes that were previously blocked:
jdk.internal.reflect.ConstantPool
jdk.internal.reflect.Reflection
jdk.internal.reflect.UnsafeStaticFieldAccessorImpl
java.lang.Class
java.lang.ClassLoader
java.lang.reflect.Constructor
java.lang.reflect.Field
java.lang.reflect.Method
java.lang.Module
java.lang.System
java.lang.invoke.MethodHandles$Lookup
java.lang.reflect.AccessibleObject
sun.misc.Unsafe
All of the above is achieved with 3 different ways:
- Reflection (needs
--add-opens=java.base/jdk.lang=ALL-UNNAMED
) - Unsafe (needs
--add-opens=java.base/jdk.internal.misc=ALL-UNNAMED
)
Namesake: Toaru Majutsu no Index
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK