Hi,
I am executing a webservice with and without security turned on. The result when executing the WS with security turned on is that I get excessive amount of namespaces ( axis2ns23, axis2ns24, axis2ns25, etc) compared to executing without security. I also get a ArrayIndexOutOfBoundsException the first time running with security but it works if I run it again.
Who is generating all of these namespaces, and can I do something to avoid it?
See info below.
Regards,
Marcus Ludvigson
Result when executing without security:
<listAllServicesResponse xmlns="http://corp.net/ConfigManager/listAllServices">
<service secure="false" servicename="Program"/>
<service secure="false" servicename="Apps"/>
<service secure="false" servicename="ConfigManager"/>
<service secure="false" servicename="version"/>
</listAllServicesResponse>
<service secure="false" servicename="Program"/>
<service secure="false" servicename="Apps"/>
<service secure="false" servicename="ConfigManager"/>
<service secure="false" servicename="version"/>
</listAllServicesResponse>
Result when executing with security:
<listAllServicesResponse xmlns:axis2ns21="http://corp.net/ConfigManager/listAllServices" xmlns:xenc="
http://www.w3.org/2001/04/xmlenc#" xmlns:wsa="http://www.w3.org/2005/08/addressing" xmlns:wsu="
http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns="http://corp.net/ConfigManager/listAllServices" xmlns:soapenv="
http://schemas.xmlsoap.org/soap/envelope/">
<service secure="false" servicename="Program" xmlns:axis2ns22=" http://corp.net/ConfigManager/listAllServices"/>
<service secure="false" servicename="Apps" xmlns:axis2ns23="http://corp.net/ConfigManager/listAllServices"/ >
<service secure="true" servicename="ConfigManager" xmlns:axis2ns24="http://corp.net/ConfigManager/listAllServices"/ >
</listAllServicesResponse>
<service secure="false" servicename="Program" xmlns:axis2ns22=" http://corp.net/ConfigManager/listAllServices"/>
<service secure="false" servicename="Apps" xmlns:axis2ns23="http://corp.net/ConfigManager/listAllServices"/ >
<service secure="true" servicename="ConfigManager" xmlns:axis2ns24="http://corp.net/ConfigManager/listAllServices"/ >
</listAllServicesResponse>
Relevant part from the WSDL:
<xs:schema targetNamespace="http://corp.net/ConfigManager/listAllServices" elementFormDefault="qualified">
<xs:element name="listAllServicesResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="service" maxOccurs="unbounded" >
<xs:complexType>
<xs:attribute name="servicename" type="xs:string" />
<xs:attribute name="secure" type="xs:boolean" />
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
<xs:element name="listAllServicesResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="service" maxOccurs="unbounded" >
<xs:complexType>
<xs:attribute name="servicename" type="xs:string" />
<xs:attribute name="secure" type="xs:boolean" />
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
ArrayIndexOutOfBounds:
SymbMap.index(Object) line: not available
SymbMap.get(String) line: not available
NameSpaceSymbTable.addMapping(String, String, Attr) line: not available
Canonicalizer20010315ExclOmitComments(Canonicalizer20010315Excl).handleAttributesSubtree(Element, NameSpaceSymbTable) line: not available
Canonicalizer20010315ExclOmitComments(CanonicalizerBase).canonicalizeSubTree(Node, NameSpaceSymbTable, Node) line: not available
Canonicalizer20010315ExclOmitComments(CanonicalizerBase).engineCanonicalizeSubTree(Node, Node) line: not available
Canonicalizer20010315ExclOmitComments(CanonicalizerBase).engineCanonicalize(XMLSignatureInput) line: not available
Canonicalizer20010315ExclOmitComments(Canonicalizer20010315Excl).engineCanonicalize(XMLSignatureInput, String) line: not available
TransformC14NExclusive.enginePerformTransform(XMLSignatureInput, OutputStream) line: not available
Transform.performTransform(XMLSignatureInput, OutputStream) line: not available
Transforms.performTransforms(XMLSignatureInput, OutputStream) line: not available
Reference.getContentsAfterTransformation(XMLSignatureInput, OutputStream) line: not available
Reference.dereferenceURIandPerformTransforms(OutputStream) line: not available
Reference.calculateDigest() line: not available
Reference.verify() line: not available
SignedInfo(Manifest).verifyReferences(boolean) line: not available
SignedInfo.verify(boolean) line: not available
XMLSignature.checkSignatureValue(Key) line: not available
XMLSignature.checkSignatureValue(X509Certificate) line: not available
SignatureProcessor.verifyXMLSignature(Element, Crypto, X509Certificate[], Set, byte[][]) line: 264
SignatureProcessor.handleToken(Element, Crypto, Crypto, CallbackHandler, WSDocInfo, Vector, WSSConfig) line: 79
WSSecurityEngine.processSecurityHeader(Element, CallbackHandler, Crypto, Crypto) line: 269
WSSecurityEngine.processSecurityHeader(Document, String, CallbackHandler, Crypto, Crypto) line: 191
WSDoAllReceiver.processMessage (MessageContext) line: 180
WSDoAllReceiver(WSDoAllHandler).invoke(MessageContext) line: 82
SymbMap.get(String) line: not available
NameSpaceSymbTable.addMapping(String, String, Attr) line: not available
Canonicalizer20010315ExclOmitComments(Canonicalizer20010315Excl).handleAttributesSubtree(Element, NameSpaceSymbTable) line: not available
Canonicalizer20010315ExclOmitComments(CanonicalizerBase).canonicalizeSubTree(Node, NameSpaceSymbTable, Node) line: not available
Canonicalizer20010315ExclOmitComments(CanonicalizerBase).engineCanonicalizeSubTree(Node, Node) line: not available
Canonicalizer20010315ExclOmitComments(CanonicalizerBase).engineCanonicalize(XMLSignatureInput) line: not available
Canonicalizer20010315ExclOmitComments(Canonicalizer20010315Excl).engineCanonicalize(XMLSignatureInput, String) line: not available
TransformC14NExclusive.enginePerformTransform(XMLSignatureInput, OutputStream) line: not available
Transform.performTransform(XMLSignatureInput, OutputStream) line: not available
Transforms.performTransforms(XMLSignatureInput, OutputStream) line: not available
Reference.getContentsAfterTransformation(XMLSignatureInput, OutputStream) line: not available
Reference.dereferenceURIandPerformTransforms(OutputStream) line: not available
Reference.calculateDigest() line: not available
Reference.verify() line: not available
SignedInfo(Manifest).verifyReferences(boolean) line: not available
SignedInfo.verify(boolean) line: not available
XMLSignature.checkSignatureValue(Key) line: not available
XMLSignature.checkSignatureValue(X509Certificate) line: not available
SignatureProcessor.verifyXMLSignature(Element, Crypto, X509Certificate[], Set, byte[][]) line: 264
SignatureProcessor.handleToken(Element, Crypto, Crypto, CallbackHandler, WSDocInfo, Vector, WSSConfig) line: 79
WSSecurityEngine.processSecurityHeader(Element, CallbackHandler, Crypto, Crypto) line: 269
WSSecurityEngine.processSecurityHeader(Document, String, CallbackHandler, Crypto, Crypto) line: 191
WSDoAllReceiver.processMessage (MessageContext) line: 180
WSDoAllReceiver(WSDoAllHandler).invoke(MessageContext) line: 82