Package org.apache.batik.script.rhino
Class BatikSecurityController
java.lang.Object
org.mozilla.javascript.SecurityController
org.apache.batik.script.rhino.BatikSecurityController
public class BatikSecurityController
extends org.mozilla.javascript.SecurityController
This implementation of the Rhino
SecurityController
interface is
meant for use within the context of Batik only. It is a partial
implementation of the interface that does what is needed by Batik and
no more.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncallWithDomain
(Object securityDomain, org.mozilla.javascript.Context cx, org.mozilla.javascript.Callable callable, org.mozilla.javascript.Scriptable scope, org.mozilla.javascript.Scriptable thisObj, Object[] args) CallsCallable.call(Context, Scriptable, Scriptable, Object[])
ofcallable
under restricted security domain where an action is allowed only if it is allowed according to the Java stack on the moment of thecallWithDomain
call andsecurityDomain
.org.mozilla.javascript.GeneratedClassLoader
createClassLoader
(ClassLoader parentLoader, Object securityDomain) Default constructorgetDynamicSecurityDomain
(Object securityDomain) Get dynamic security domain that allows an action only if it is allowed by the current Java stack and securityDomain.Methods inherited from class org.mozilla.javascript.SecurityController
createLoader, execWithDomain, getStaticSecurityDomainClass, getStaticSecurityDomainClassInternal, hasGlobal, initGlobal
-
Constructor Details
-
BatikSecurityController
public BatikSecurityController()
-
-
Method Details
-
createClassLoader
public org.mozilla.javascript.GeneratedClassLoader createClassLoader(ClassLoader parentLoader, Object securityDomain) Default constructor- Specified by:
createClassLoader
in classorg.mozilla.javascript.SecurityController
-
getDynamicSecurityDomain
Get dynamic security domain that allows an action only if it is allowed by the current Java stack and securityDomain. If securityDomain is null, return domain representing permissions allowed by the current stack.- Specified by:
getDynamicSecurityDomain
in classorg.mozilla.javascript.SecurityController
-
callWithDomain
public Object callWithDomain(Object securityDomain, org.mozilla.javascript.Context cx, org.mozilla.javascript.Callable callable, org.mozilla.javascript.Scriptable scope, org.mozilla.javascript.Scriptable thisObj, Object[] args) CallsCallable.call(Context, Scriptable, Scriptable, Object[])
ofcallable
under restricted security domain where an action is allowed only if it is allowed according to the Java stack on the moment of thecallWithDomain
call andsecurityDomain
. Any call togetDynamicSecurityDomain(Object)
during execution ofCallable.call(Context, Scriptable, Scriptable, Object[])
should return a domain incorporate restrictions imposed bysecurityDomain
.- Overrides:
callWithDomain
in classorg.mozilla.javascript.SecurityController
-