Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.1.8
-
None
Description
The following works OK on 2.1.5.1 :-
<?xml version="1.0" encoding="ISO-8859-1"?>
<ldapuser xmlns:ldap="http://apache.org/cocoon/LDAP/1.0">
<ldap:execute-replace>
<ldap:initializer>com.sun.jndi.ldap.LdapCtxFactory</ldap:initializer>
<ldap:version>3</ldap:version>
<ldap:serverurl>ldap://ldap.westsussex.gov.uk</ldap:serverurl>
<ldap:searchbase>ou=training,ou=IRT,ou=apps,o=wscc,dc=westsussex,dc=gov,dc=uk</ldap:searchbase>
<ldap:rootdn>cn=root</ldap:rootdn>
<ldap:password>passw0rd</ldap:password>
<ldap:count-limit>0</ldap:count-limit>
<ldap:time-limit>0</ldap:time-limit>
<ldap:filter>(&(uid=irttraining02))</ldap:filter>
<ldap:attribute name="givenname">two</ldap:attribute>
</ldap:execute-replace>
</ldapuser>
but fails with NPE on 2.1.8
java.lang.NullPointerException
at org.apache.cocoon.transformation.LDAPTransformer$LDAPQuery.execute(LDAPTransformer.java:1264)
at org.apache.cocoon.transformation.LDAPTransformer.executeQuery(LDAPTransformer.java:249)
at org.apache.cocoon.transformation.LDAPTransformer.endExecuteElement(LDAPTransformer.java:288)
at org.apache.cocoon.transformation.LDAPTransformer.endElement(LDAPTransformer.java:781)
at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at org.apache.excalibur.xml.impl.JaxpParser.parse(JaxpParser.java:315)
at org.apache.excalibur.xml.impl.JaxpParser.parse(JaxpParser.java:334)
at org.apache.cocoon.components.source.SourceUtil.parse(SourceUtil.java:325)
at org.apache.cocoon.generation.FileGenerator.generate(FileGenerator.java:115)
at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLPipeline(AbstractProcessingPipeline.java:578)
at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:480)
at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:120)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:117)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
at org.apache.cocoon.Cocoon.process(Cocoon.java:679)
<?xml version="1.0" encoding="ISO-8859-1"?>
<ldapuser xmlns:ldap="http://apache.org/cocoon/LDAP/1.0">
<ldap:execute-replace>
<ldap:initializer>com.sun.jndi.ldap.LdapCtxFactory</ldap:initializer>
<ldap:version>3</ldap:version>
<ldap:serverurl>ldap://ldap.westsussex.gov.uk</ldap:serverurl>
<ldap:searchbase>ou=training,ou=IRT,ou=apps,o=wscc,dc=westsussex,dc=gov,dc=uk</ldap:searchbase>
<ldap:rootdn>cn=root</ldap:rootdn>
<ldap:password>passw0rd</ldap:password>
<ldap:count-limit>0</ldap:count-limit>
<ldap:time-limit>0</ldap:time-limit>
<ldap:filter>(&(uid=irttraining02))</ldap:filter>
<ldap:attribute name="givenname">two</ldap:attribute>
</ldap:execute-replace>
</ldapuser>
but fails with NPE on 2.1.8
java.lang.NullPointerException
at org.apache.cocoon.transformation.LDAPTransformer$LDAPQuery.execute(LDAPTransformer.java:1264)
at org.apache.cocoon.transformation.LDAPTransformer.executeQuery(LDAPTransformer.java:249)
at org.apache.cocoon.transformation.LDAPTransformer.endExecuteElement(LDAPTransformer.java:288)
at org.apache.cocoon.transformation.LDAPTransformer.endElement(LDAPTransformer.java:781)
at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at org.apache.excalibur.xml.impl.JaxpParser.parse(JaxpParser.java:315)
at org.apache.excalibur.xml.impl.JaxpParser.parse(JaxpParser.java:334)
at org.apache.cocoon.components.source.SourceUtil.parse(SourceUtil.java:325)
at org.apache.cocoon.generation.FileGenerator.generate(FileGenerator.java:115)
at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLPipeline(AbstractProcessingPipeline.java:578)
at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:480)
at org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:120)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:117)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
at org.apache.cocoon.Cocoon.process(Cocoon.java:679)