This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gij -Djava.security.manager ?


Gentle gcj:ers,
gij/gcj does not seem to take any notice of -Djava.security.manager :

% /home/thomas/gcc-4.1.1install/bin/gij -Djava.security.manager -Djava.security.policy=file:j.policy j
No security manager


j.java:
class j {
 public static void main(String [] v) {
   SecurityManager sm = System.getSecurityManager();
   if (sm != null) {
     sm.checkPermission(new java.security.AllPermission());
     System.out.println("OK");
   } else {
     System.out.println("No security manager");
   }
 }
}

j.policy:
grant codebase "file:./-" {
 permission java.security.AllPermission;
};

The above works for all other jvm's I've tested. Not supported? Should I use something else?
-- Thomas



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]