What is a "safe classloader"? SecureClassLoader? It is not safe, despite its name. All he does is limit the loading of classes from class to a specific code location.
Therefore, you do not even need any unsafe operations to βbreakβ it. Just, for example, make sure the new class of the hacked class is on the class path before SecureClassLoader even gets control.
Someone in this thread has already told you - you cannot get a secure place in an unsecured environment. If your code is deployed on the user's computer, the user is god there, and no JVM security will help you simply because the JVM is a tiny layer on top of much more powerful native things.
Vladimir Dyuzhev
source share