I have three classes, one called Capture, AppletLogging and AbstractJLabel. I have set the following permissions in my %USERPROFILE%/.java.policy file:
grant codeBase "file:/C:/project/abc/target/test-classes/-" {
permission java.util.logging.LoggingPermission "control";
};
All classes are in the codeBase from the grant above. When Capture calls a static method in AppletLogging everything works ok. When AbstractJLabel calls the same static method in AppletLogging then I get
java.security.AccessControlException: access denied (java.util.logging.LoggingPermission control)
This runs in the Sun java plugin version 6 update 35. Does anyone have an explanation? I get the same error even if I all the following to the grant codeBase block:
permission java.security.AllPermission;
Note that Capture and AbstractJLabel invoke the static method from a static block.