|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectjd.xml.xslt.XsltSecurityManager
XsltSecurityManager is a class that allows applications to implement a security policy for XSLT transformations. It allows an application to determine, before performing a possibly unsafe or sensitive XSL instruction, what the operation is and whether it is being attempted in a security context that allows the operation to be performed. The application can allow or disallow the operation.
| Field Summary | |
static XsltSecurityManager |
DEFAULT
The default security manager which has no restrictions. |
| Constructor Summary | |
XsltSecurityManager()
|
|
| Method Summary | |
void |
checkDocumentRead(String uri)
Check the permission to read document via the document()-function The default implementation does nothing. |
void |
checkDocumentWrite(String xslUri,
String parentUri,
String href)
Check the permission to write a subdocument defined by xsl:document The default implementation does nothing. |
void |
checkExecuteScript(String xslUri,
String language,
String src,
String content)
Check the permission to execute a script defined by a xsl:script instruction. |
void |
checkReplace(XsltSecurityManager manager)
Check the permission to replace the current global security manager. |
static XsltSecurityManager |
getGlobalInstance()
Return the global security manager. |
static void |
setGlobalInstance(XsltSecurityManager manager)
Set the global security manager. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final XsltSecurityManager DEFAULT
| Constructor Detail |
public XsltSecurityManager()
| Method Detail |
public static void setGlobalInstance(XsltSecurityManager manager)
public static XsltSecurityManager getGlobalInstance()
public void checkExecuteScript(String xslUri,
String language,
String src,
String content)
throws SecurityException
xslUri - the baseUri of the defining xsl documentlanguage - the script languagesrc - the external script source. If not null content is nullcontent - the inline definition of the script. If not null src is null
SecurityException - thrown if script execution is not allowed.
public void checkDocumentWrite(String xslUri,
String parentUri,
String href)
throws SecurityException
xslUri - the baseUri of the defining xsl documentparentUri - the uri of the parent documenthref - the href of the subdocument
SecurityException - thrown if the creation of the subdocument is not allowed.
public void checkDocumentRead(String uri)
throws SecurityException
uri - the of the document
SecurityException - thrown if the document may not be read.
public void checkReplace(XsltSecurityManager manager)
throws SecurityException
manager - the new manager
SecurityException - thrown if it is not allowed to replace it
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||