Still getting AccessControlException

Hi -

I'm using the Java Plugin 1.3.1_06 with Netscape 4.75 (this is a must).

I'm using a signed applet. The applet uses a JFileChooser component. When I instantiate

it, it gives me the AccessControlException.

Here's the code snippet:

protected JFileChooser getStoreBrowser() {

if (_ksBrowser == null) {

try {

_ksBrowser = (JFileChooser)AccessController.doPrivileged(new PrivilegedAction() {

public Object run() {

JFileChooser chooser = new JFileChooser();

chooser.setFileSelectionMode(getStoreBrowserMode());

return chooser;

}

});

}

catch (Exception e) {

e.printStackTrace();

_ksBrowser = null;

}

}

return _ksBrowser;

}

And here's the stack trace:

java.security.AccessControlException: access denied (java.util.PropertyPermission user.home read)

at java.security.AccessControlContext.checkPermission(Unknown Source)

at java.security.AccessController.checkPermission(Unknown Source)

at java.lang.SecurityManager.checkPermission(Unknown Source)

at java.lang.SecurityManager.checkPropertyAccess(Unknown Source)

at java.lang.System.getProperty(Unknown Source)

at javax.swing.filechooser.FileSystemView.getHomeDirectory(Unknown Source)

at javax.swing.JFileChooser.setCurrentDirectory(Unknown Source)

at javax.swing.JFileChooser.<init>(Unknown Source)

at javax.swing.JFileChooser.<init>(Unknown Source)

at com.zaplet.signer.ui.SignerApplet$1.run(SignerApplet.java:187)

at java.security.AccessController.doPrivileged(Native Method)

at com.zaplet.signer.ui.SignerApplet.getStoreBrowser(SignerApplet.java:185)

I'm using weblogic 7.0 with one-way ssl enabled. This works with 1.4.0_01 w/ Netscape 4.75.

Any help would be appreciated.

Thanks!

achoy941

[1925 byte] By [achoy941] at [2007-9-30 12:16:07]
# 1

Your stack doesn't show that the method was called from javascript but because there are no other

posts/suggestions so you could try setting the policy to allpermission just to see if that fixes it.

bug #4883871 was fixed in 1.4.2 and later releases so if the method was called from javascript and

1.3.1 did not have the bug that could explain why it does work with 1.4.0_01.

http://forum.java.sun.com/thread.jsp?forum=63&thread=524815

second post

If that isn't it than I don't know, I am not familiar with 1.3 but I do think you can set Runtime Parameters

using the Java control panel. Could you try activating a full trace:

runtime parameter:

-Djavaplugin.trace=true -Djavaplugin.trace.option=basic|net|security|ext|liveconnect

harmmeijer at 2007-7-4 15:18:06 > top of Java-index,Security,Signed Applets...