Java security policy file example 3

/* Grants permission to run Derby and access a single */
/* database (salesdb) under the Derby system home     */

/* Note Derby.system.home must be an absolute pathname */

grant codeBase "file://f:/derby/lib/derby.jar" {

  permission java.lang.RuntimePermission "createClassLoader";
  permission java.util.PropertyPermission "derby.*", "read";
  permission java.io.FilePermission "${derby.system.home}","read";
  permission java.io.FilePermission "${derby.system.home}${/}*", 
      "read,write,delete";
  permission java.io.FilePermission "${derby.system.home}${/}
      salesdb${/}-", "read,write,delete";
  permission java.util.PropertyPermission "derby.storage.jvmInstanceId", 
      "write"; 


}; 
Related reference
Java security policy file example 1
Java security policy file example 2