+2004-09-26 Casey Marshall <csm@gnu.org>
+
+ * java/security/ProtectionDomain.java
+ (<init>(CodeSource,PermissionCollection)): set `staticBinding' to
+ `true'.
+
+ * java/security/SecureClassLoader.java
+ (defineClass): make protection domain dynamically bound.
+ (getPermissions): call `getCurrentPolicy' to avoid permission
+ check.
+
2004-09-25 Mark Wielaard <mark@klomp.org>
* Makefile.am (core_java_source_files): Add VMTimeZone.java.
*/
public ProtectionDomain(CodeSource codesource, PermissionCollection permissions)
{
- this(codesource, permissions, null, null, false);
+ this(codesource, permissions, null, null, true);
}
/**
if (cs != null)
{
ProtectionDomain protectionDomain
- = new ProtectionDomain(cs, getPermissions(cs));
+ = new ProtectionDomain(cs, getPermissions(cs), this, null);
return super.defineClass(name, b, off, len, protectionDomain);
}
else
*/
protected PermissionCollection getPermissions(CodeSource cs)
{
- Policy policy = Policy.getPolicy();
+ Policy policy = Policy.getCurrentPolicy();
return policy.getPermissions(cs);
}
}