Community
Participate
Working Groups
20020123 I know I've done this successfully in the past. Is it now disallowed? I set the scrapbook run in package to java.util, then try to run something like "System.out.println("hi")" and get the following walkback in the console: java.lang.SecurityException: Prohibited package name: java.util at java.lang.ClassLoader.defineClass(ClassLoader.java:479) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:111) at java.net.URLClassLoader.defineClass(URLClassLoader.java:248) at java.net.URLClassLoader.access$100(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:299) at java.lang.ClassLoader.loadClass(ClassLoader.java:255) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:120) at org.eclipse.jdt.internal.debug.ui.snippeteditor.ScrapbookMain1.eval(ScrapbookMain1.java:14) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.jdt.internal.debug.ui.snippeteditor.ScrapbookMain.evalLoop(ScrapbookMain.java:46) at org.eclipse.jdt.internal.debug.ui.snippeteditor.ScrapbookMain.main(ScrapbookMain.java:27) If this is disallowed, we ought to supress the walkback and disallow selection of these packages in the run in package dialog.
This is a known problem. You can't run in the context of system package.
*** This bug has been marked as a duplicate of 1633 ***