Please review: 7143711 : Feature added by 7053556 should not override what's set by the constructor in secure mode
Joe Wang
huizhe.wang at oracle.com
Mon Feb 13 17:06:13 UTC 2012
Thanks Tom.
Joe
On 2/13/2012 8:54 AM, Tom Hawtin wrote:
> 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.ORACLE_FEATURE_SERVICE_MECHANISM)) {
>> + //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.ORACLE_FEATURE_SERVICE_MECHANISM)) {
>> + //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(SECURITY_MANAGER, fSecurityManager);
>> return;
>> + } else if (name.equals(Constants.ORACLE_FEATURE_SERVICE_MECHANISM)) {
>> + //in secure mode, let _useServicesMechanism be determined by the
>> constructor
>> + if (System.getSecurityManager() != null)
>> + return;
>> }
>> try {
>> fXMLSchemaLoader.setFeature(name, value);
>>
>> Thanks,
>> Joe
>
More information about the core-libs-dev
mailing list