changeset 731:9230de21402d

SchemaParsingConfig also needs to be updated to initialise a SECURITY_MANAGER
author andrew
date Mon, 14 Oct 2013 14:04:51 +0100
parents 1dbd732765d0
children f715be7cd8ab
files src/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaParsingConfig.java
diffstat 1 files changed, 7 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaParsingConfig.java	Thu Oct 10 02:08:57 2013 +0100
+++ b/src/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaParsingConfig.java	Mon Oct 14 14:04:51 2013 +0100
@@ -41,6 +41,7 @@
 import com.sun.org.apache.xerces.internal.util.PropertyState;
 import com.sun.org.apache.xerces.internal.util.Status;
 import com.sun.org.apache.xerces.internal.util.SymbolTable;
+import com.sun.org.apache.xerces.internal.utils.XMLSecurityManager;
 import com.sun.org.apache.xerces.internal.xni.XMLLocator;
 import com.sun.org.apache.xerces.internal.xni.XNIException;
 import com.sun.org.apache.xerces.internal.xni.grammars.XMLGrammarPool;
@@ -160,6 +161,8 @@
     protected static final String LOCALE =
         Constants.XERCES_PROPERTY_PREFIX + Constants.LOCALE_PROPERTY;
 
+    /** Property identifier: Security manager. */
+    private static final String SECURITY_MANAGER = Constants.SECURITY_MANAGER;
 
     // debugging
 
@@ -329,7 +332,8 @@
             DATATYPE_VALIDATOR_FACTORY,
             VALIDATION_MANAGER,
             GENERATE_SYNTHETIC_ANNOTATIONS,
-            LOCALE
+            LOCALE,
+            SECURITY_MANAGER
         };
         addRecognizedProperties(recognizedProperties);
 
@@ -364,6 +368,8 @@
 
         fVersionDetector = new XMLVersionDetector();
 
+        fProperties.put(SECURITY_MANAGER, new XMLSecurityManager(true));
+
         // add message formatters
         if (fErrorReporter.getMessageFormatter(XMLMessageFormatter.XML_DOMAIN) == null) {
             XMLMessageFormatter xmft = new XMLMessageFormatter();