8134861: XSLT: Extension func call cause exception if namespace URI contains partial package name
Reviewed-by: joehw
--- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FunctionCall.java Sun Aug 30 23:03:23 2015 -0700
+++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FunctionCall.java Wed Sep 09 01:57:38 2015 +0300
@@ -932,9 +932,9 @@
//Check if FSP and SM - only then process with loading
if (namespace != null && isSecureProcessing
&& isExtensionFunctionEnabled
- && (namespace.equals(JAVA_EXT_XALAN)
- || namespace.equals(JAVA_EXT_XSLTC)
- || namespace.equals(JAVA_EXT_XALAN_OLD)
+ && (namespace.startsWith(JAVA_EXT_XALAN)
+ || namespace.startsWith(JAVA_EXT_XSLTC)
+ || namespace.startsWith(JAVA_EXT_XALAN_OLD)
|| namespace.startsWith(XALAN_CLASSPACKAGE_NAMESPACE))) {
_clazz = getXSLTC().loadExternalFunction(_className);
} else {