Please review: 7143711 : Feature added by 7053556 should not override what's set by the constructor in secure mode (original) (raw)
Tom Hawtin tom.hawtin at oracle.com
Mon Feb 13 16:54:17 UTC 2012
- Previous message: Please review: 7143711 : Feature added by 7053556 should not override what's set by the constructor in secure mode
- Next message: Please review: 7143711 : Feature added by 7053556 should not override what's set by the constructor in secure mode
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Looks good to me.
Tom
On 08/02/2012 22:13, Joe Wang wrote:
Hi,
The 7053556 patch added a (Oracle) implementation-only feature to allow users to skip the plugability layer. In the same patch, there was also a change that in secure mode, dependent components should be loaded in a hardwired mode. The implementation-only feature therefore should not override what's set by the constructor in secure mode. Please consider this is a supplemental change to 7053556 since it itself is a change for 7u4. Below are the changes: Index: com/sun/org/apache/xalan/internal/xsltc/trax/TransformerFactoryImpl.java --- com/sun/org/apache/xalan/internal/xsltc/trax/TransformerFactoryImpl.java Base (BASE) +++ com/sun/org/apache/xalan/internal/xsltc/trax/TransformerFactoryImpl.java Locally Modified (Based On LOCAL) @@ -487,6 +487,8 @@ return; } else if (name.equals(XalanConstants.ORACLEFEATURESERVICEMECHANISM)) { + //in secure mode, let useServicesMechanism be determined by the constructor + if (!isSecureMode) useServicesMechanism = value; } else { Index: com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java --- com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java Base (BASE) +++ com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java Locally Modified (Based On LOCAL) @@ -226,6 +226,8 @@ return; } if (name.equals(XalanConstants.ORACLEFEATURESERVICEMECHANISM)) { + //in secure mode, let useServicesMechanism be determined by the constructor + if (!isSecureMode) useServicesMechanism = value; return; } Index: com/sun/org/apache/xerces/internal/jaxp/validation/XMLSchemaFactory.java --- com/sun/org/apache/xerces/internal/jaxp/validation/XMLSchemaFactory.java Base (BASE) +++ com/sun/org/apache/xerces/internal/jaxp/validation/XMLSchemaFactory.java Locally Modified (Based On LOCAL) @@ -390,6 +390,10 @@ fSecurityManager = value ? new SecurityManager() : null; fXMLSchemaLoader.setProperty(SECURITYMANAGER, fSecurityManager); return; + } else if (name.equals(Constants.ORACLEFEATURESERVICEMECHANISM)) { + //in secure mode, let useServicesMechanism be determined by the constructor + if (System.getSecurityManager() != null) + return; } try { fXMLSchemaLoader.setFeature(name, value); Thanks, Joe
- Previous message: Please review: 7143711 : Feature added by 7053556 should not override what's set by the constructor in secure mode
- Next message: Please review: 7143711 : Feature added by 7053556 should not override what's set by the constructor in secure mode
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]