org.mozilla.javascript

Class PolicySecurityController


public class PolicySecurityController
extends SecurityController

A security controller relying on Java Policy in effect. When you use this security controller, your securityDomain objects must be instances of CodeSource representing the location from where you load your scripts. Any Java policy "grant" statements matching the URL and certificate in code sources will apply to the scripts. If you specify any certificates within your CodeSource objects, it is your responsibility to verify (or not) that the script source files are signed in whatever implementation-specific way you're using.
Author:
Attila Szegedi

Nested Class Summary

static class
PolicySecurityController.SecureCaller

Method Summary

Object
callWithDomain(Object securityDomain, Context cx, Callable callable, Scriptable scope, Scriptable thisObj, Object[] args)
GeneratedClassLoader
createClassLoader(ClassLoader parent, Object securityDomain)
Object
getDynamicSecurityDomain(Object securityDomain)
Class
getStaticSecurityDomainClassInternal()

Methods inherited from class org.mozilla.javascript.SecurityController

callWithDomain, createClassLoader, createLoader, execWithDomain, getDynamicSecurityDomain, getStaticSecurityDomainClass, getStaticSecurityDomainClassInternal, hasGlobal, initGlobal

Method Details

callWithDomain

public Object callWithDomain(Object securityDomain,
                             Context cx,
                             Callable callable,
                             Scriptable scope,
                             Scriptable thisObj,
                             Object[] args)
Overrides:
callWithDomain in interface SecurityController

createClassLoader

public GeneratedClassLoader createClassLoader(ClassLoader parent,
                                              Object securityDomain)
Overrides:
createClassLoader in interface SecurityController

getDynamicSecurityDomain

public Object getDynamicSecurityDomain(Object securityDomain)
Overrides:
getDynamicSecurityDomain in interface SecurityController

getStaticSecurityDomainClassInternal

public Class getStaticSecurityDomainClassInternal()
Overrides:
getStaticSecurityDomainClassInternal in interface SecurityController