public final class XMLSecurityManager extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
XMLSecurityManager.Limit
Limits managed by the security manager
|
static class |
XMLSecurityManager.NameMap
Map old property names with the new ones
|
static class |
XMLSecurityManager.State
States of the settings of a property, in the order: default value, value
set by FEATURE_SECURE_PROCESSING, jaxp.properties file, jaxp system
properties, and jaxp api properties
|
| Constructor and Description |
|---|
XMLSecurityManager()
Default constructor.
|
XMLSecurityManager(boolean secureProcessing)
Instantiate Security Manager in accordance with the status of
secure processing
|
| Modifier and Type | Method and Description |
|---|---|
static XMLSecurityManager |
convert(Object value,
XMLSecurityManager securityManager)
Convert a value set through setProperty to XMLSecurityManager.
|
void |
debugPrint(XMLLimitAnalyzer limitAnalyzer) |
int |
getIndex(String propertyName)
Get the index by property name
|
int |
getLimit(XMLSecurityManager.Limit limit)
Return the value of the specified property
|
String |
getLimitAsString(String propertyName)
Return the value of the specified property
|
String |
getLimitValueAsString(XMLSecurityManager.Limit limit)
Return the value of a property by its ordinal
|
String |
getLimitValueByIndex(int index)
Return the value of a property by its ordinal
|
XMLSecurityManager.State |
getState(XMLSecurityManager.Limit limit)
Return the state of the limit property
|
String |
getStateLiteral(XMLSecurityManager.Limit limit)
Return the state of the limit property
|
boolean |
isNoLimit(int limit)
Check if there's no limit defined by the Security Manager
|
boolean |
isOverLimit(int index,
String entityName,
int size,
XMLLimitAnalyzer limitAnalyzer)
Check if the value (length or count) of the specified limit property is
over the limit
|
boolean |
isOverLimit(int index,
XMLLimitAnalyzer limitAnalyzer) |
boolean |
isOverLimit(XMLSecurityManager.Limit limit,
String entityName,
int size,
XMLLimitAnalyzer limitAnalyzer)
Check if the size (length or count) of the specified limit property is
over the limit
|
boolean |
isOverLimit(XMLSecurityManager.Limit limit,
XMLLimitAnalyzer limitAnalyzer)
Check against cumulated value
|
boolean |
isSecureProcessing()
Return the state of secure processing
|
boolean |
isSet(int index)
Indicate if a property is set explicitly
|
boolean |
printEntityCountInfo() |
void |
setLimit(int index,
XMLSecurityManager.State state,
int value)
Set the value of a property by its index
|
void |
setLimit(int index,
XMLSecurityManager.State state,
Object value)
Set the value of a property by its index
|
boolean |
setLimit(String propertyName,
XMLSecurityManager.State state,
Object value)
Set limit by property name and state
|
void |
setLimit(XMLSecurityManager.Limit limit,
XMLSecurityManager.State state,
int value)
Set the value for a specific limit.
|
void |
setSecureProcessing(boolean secure)
Setting FEATURE_SECURE_PROCESSING explicitly
|
public XMLSecurityManager()
public XMLSecurityManager(boolean secureProcessing)
secureProcessing - public void setSecureProcessing(boolean secure)
public boolean isSecureProcessing()
public boolean setLimit(String propertyName, XMLSecurityManager.State state, Object value)
propertyName - property namestate - the state of the propertyvalue - the value of the propertypublic void setLimit(XMLSecurityManager.Limit limit, XMLSecurityManager.State state, int value)
limit - the limitstate - the state of the propertyvalue - the value of the propertypublic void setLimit(int index,
XMLSecurityManager.State state,
Object value)
index - the index of the propertystate - the state of the propertyvalue - the value of the propertypublic void setLimit(int index,
XMLSecurityManager.State state,
int value)
index - the index of the propertystate - the state of the propertyvalue - the value of the propertypublic String getLimitAsString(String propertyName)
propertyName - the property namepublic int getLimit(XMLSecurityManager.Limit limit)
limit - the propertypublic String getLimitValueAsString(XMLSecurityManager.Limit limit)
limit - the propertypublic String getLimitValueByIndex(int index)
index - the index of a propertypublic XMLSecurityManager.State getState(XMLSecurityManager.Limit limit)
limit - the limitpublic String getStateLiteral(XMLSecurityManager.Limit limit)
limit - the limitpublic int getIndex(String propertyName)
propertyName - property namepublic boolean isNoLimit(int limit)
limit - public boolean isOverLimit(XMLSecurityManager.Limit limit, String entityName, int size, XMLLimitAnalyzer limitAnalyzer)
limit - the type of the limit propertyentityName - the name of the entitysize - the size (count or length) of the entitypublic boolean isOverLimit(int index,
String entityName,
int size,
XMLLimitAnalyzer limitAnalyzer)
index - the index of the limit propertyentityName - the name of the entitysize - the size (count or length) of the entitypublic boolean isOverLimit(XMLSecurityManager.Limit limit, XMLLimitAnalyzer limitAnalyzer)
limit - the type of the limit propertysize - the size (count or length) of the entitypublic boolean isOverLimit(int index,
XMLLimitAnalyzer limitAnalyzer)
public void debugPrint(XMLLimitAnalyzer limitAnalyzer)
public boolean isSet(int index)
index - public boolean printEntityCountInfo()
public static XMLSecurityManager convert(Object value, XMLSecurityManager securityManager)
value - user specified security managersecurityManager - an instance of XMLSecurityManagerCopyright © 2018–2021 mhoffrogge. All rights reserved.