Am Freitag, 8. Oktober 2004 09:42 schrieb Stephen Crawley:
> [EMAIL PROTECTED] said:
> > I would like to make this new class public to do away with the
> > overhead (and initialization dependencies) of the security check,
> > but that would require some VM magic to make the class
> > inaccessible from untrusted code. Michael Koch (strongly) opposes
> > this. How would you feel about it?
>
> Speaking as yet another JVM implementor, I'm against this idea for
> the reasons given by Michael and others.
In order to find a solution would the following be a solution for you:
public final class VMSecureProperties
{
public String getProperty(String propName, String defaultValue)
{
GetPropertyAction getProp = new GetPropertyAction(propName,
defaultValue);
return (String)AccessController.doPrivileged(getProp);
}
}
This reduces out code duplication and should it make possible to do
whatever you want inside your VM.
What do you think ?
Michael
--
Homepage: http://www.worldforge.org/
_______________________________________________
Classpath mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/classpath