Hi Manish, Looking at your request message it seems that your "SOAPAction" http header value is different from the "wsa:Action" value:
SOAPAction: "urn:anonOutInOp" <wsa:Action>urn:anonOutInOpResponse</wsa:Action> These two values has to be the same and the a "operation" element in the services.xml will have to have an "actionMapping" element mapping the the action above value to that operation. example: <actionMapping>urn:echo</actionMapping> Thanks, Ruchith Manish Verma wrote: > > Hello Ruchith, > > Yes it does. I set the action value to null, now it throws the following > exception. I have also attached the SOAP request -- > > Your help is highly appreciated. > > Regards > Manish > > > <ns1:echo > xmlns:ns1="http://service.NoSecurity.WS.Axis2.eklavya.org"><param0>Hello > world</param0><param1 /></ns1:echo> > Exception in thread "main" org.apache.axis2.AxisFault: The server failed to > process the WS-Addressing header: wsa:Action [Reason]: A header representing > a Message Addressing Property is not valid and the message cannot be > processed > at > org.apache.axis2.handlers.addressing.AddressingInFaultHandler.invoke(Address > ingInFaultHandler.java:114) > at org.apache.axis2.engine.Phase.invoke(Phase.java:292) > at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:212) > at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:132) > at > org.apache.axis2.description.OutInAxisOperationClient.handleResponse(OutInAx > isOperation.java:336) > at > org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperatio > n.java:389) > at > org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisO > peration.java:211) > at > org.apache.axis2.client.OperationClient.execute(OperationClient.java:163) > at > org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:528) > at > org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:508) > at > org.eklavya.Axis2.WS.NoSecurity.client.NoSecurityServiceClient.main(NoSecuri > tyServiceClient.java:50) > > >>>>>>>>>>>>>>> The SOAP request that I picked from TCPMON <<<<<<<<<<<<<<< > > > > POST /axis2/services/NoSecurityService HTTP/1.1 > Content-Type: text/xml; charset=UTF-8 > SOAPAction: "urn:anonOutInOp" > User-Agent: Axis2 > Host: localhost:8000 > Transfer-Encoding: chunked > > f87 > <?xml version='1.0' encoding='UTF-8'?> > <soapenv:Envelope > xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" > xmlns:xenc="http://www.w3.org/2001/04/xmlenc#" > xmlns:wsa="http://www.w3.org/2005/08/addressing"> > <soapenv:Header> > <wsse:Security > xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecuri > ty-secext-1.0.xsd" soapenv:mustUnderstand="1"> > <wsu:Timestamp > xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurit > y-utility-1.0.xsd" wsu:Id="Timestamp-29715552"> > <wsu:Created>2007-11-16T11:21:38.589Z</wsu:Created> > <wsu:Expires>2007-11-16T11:26:38.589Z</wsu:Expires> > </wsu:Timestamp> > <xenc:EncryptedKey Id="EncKeyId-18471958"> > <xenc:EncryptionMethod > Algorithm="http://www.w3.org/2001/04/xmlenc#rsa-1_5" /> > <ds:KeyInfo xmlns:ds="http://www.w3.org/2000/09/xmldsig#"> > <wsse:SecurityTokenReference> > <wsse:KeyIdentifier > EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-m > essage-security-1.0#Base64Binary" > ValueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-toke > n-profile-1.0#X509SubjectKeyIdentifier">ENBEXCdWhIw/4wrQdCs8EyhNIxk=</wsse:K > eyIdentifier> > </wsse:SecurityTokenReference> > </ds:KeyInfo> > <xenc:CipherData> > > <xenc:CipherValue>hP6QyrCfh3y4BQ+zXNcZmUnRE6V1hcM4SnawZj+ZaUQf+AidLZM2X7anVF > FO3x2Y2losPZ0ebvVxsuN+3OUS3H7mvM3Qgima4ESdMbuXTx/oN6ih5T9SVhXsq5iTJUMkBWK7sn > tb/X4zN4T2k56U/3uxWPzH3nUIDN/H77sW+0o=</xenc:CipherValue> > </xenc:CipherData> > </xenc:EncryptedKey> > <xenc:ReferenceList> > <xenc:DataReference URI="#EncDataId-9800632" /> > </xenc:ReferenceList> > <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#" > Id="Signature-2056742"> > <ds:SignedInfo> > <ds:CanonicalizationMethod > Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" /> > <ds:SignatureMethod > Algorithm="http://www.w3.org/2000/09/xmldsig#hmac-sha1" /> > <ds:Reference URI="#Timestamp-29715552"> > <ds:Transforms> > <ds:Transform > Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" /> > </ds:Transforms> > <ds:DigestMethod > Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" /> > > <ds:DigestValue>u9MmfTwxLDAdo6N4b+fdeSIe97c=</ds:DigestValue> > </ds:Reference> > </ds:SignedInfo> > > <ds:SignatureValue>A8G/pAJL7BaQhbVs44X1Vp1c4Pw=</ds:SignatureValue> > <ds:KeyInfo Id="KeyId-22608339"> > <wsse:SecurityTokenReference > xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurit > y-utility-1.0.xsd" wsu:Id="STRId-7971559"> > <wsse:Reference URI="#EncKeyId-18471958" > ValueType="http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.0#S > AMLAssertionID" /> > </wsse:SecurityTokenReference> > </ds:KeyInfo> > </ds:Signature> > </wsse:Security> > > <wsa:To>http://localhost:8000/axis2/services/NoSecurityService</wsa:To> > > <wsa:MessageID>urn:uuid:EF5AADEECF58F3D48F1195212098423</wsa:MessageID> > <wsa:Action>urn:anonOutInOpResponse</wsa:Action> > </soapenv:Header> > <soapenv:Body > xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurit > y-utility-1.0.xsd" wsu:Id="Id-9800632"> > <xenc:EncryptedData Id="EncDataId-9800632" > Type="http://www.w3.org/2001/04/xmlenc#Content"> > <xenc:EncryptionMethod > Algorithm="http://www.w3.org/2001/04/xmlenc#aes128-cbc" /> > <ds:KeyInfo xmlns:ds="http://www.w3.org/2000/09/xmldsig#"> > <wsse:SecurityTokenReference > xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecuri > ty-secext-1.0.xsd"> > <wsse:Reference URI="#EncKeyId-18471958" /> > </wsse:SecurityTokenReference> > </ds:KeyInfo> > <xenc:CipherData> > > <xenc:CipherValue>2UBHhSJosp+hJyDlrHiT+OqiNEUxrSHINRWG1njRFM4PdiocJwNH2WzSnZ > z5GN9oq2e8n+Tk4fxlm6EsWhTfrYSjm+0hPfBBUHj0K5A2EiYnxv7FNesYVCj8Ta4iMY5wzorBVH > oPA6A0kZWuW1Klb7U+4KjUPwRpkpElfFVu7q4HqSa4JKe1tyCb4fP31/oGUiiJFPyjoaXmXas78h > +VLLIMcWxftCuKDaPnp6HcVr+agTar92VmJRMgENGPul8BRvUAeAfUCSdmeEq7SKLptYdlk7v5zo > j1PiZdxmXEY1tib56+DuF0fVbUiJFntJSJCGV5m3UcGZcw0GHunfbECX3+z4lr5a7pt/gLwc82WT > AaAN1I30GQyA1yX6Hx6svPsWw3njkDE5nruEtFbil6kjlpZ63Uj4nEIeUjF86aa9X7Su3kYr22FN > 7H2TrcB6fOZ9d24xZPvByhuYPeScNL9F5LrEYmVaZAP1Av98c7k8DoLRiWv0mAsc2OokoJkZwm</ > xenc:CipherValue> > </xenc:CipherData> > </xenc:EncryptedData> > </soapenv:Body> > </soapenv:Envelope>0 > > ---------------------------------- > Manish Verma > +91 99155 98590 (Cell) > +91 172 3056 502 (Work) > VermaM1947 (AOL) > [EMAIL PROTECTED] > > > -----Original Message----- > From: Ruchith Fernando [mailto:[EMAIL PROTECTED] > Sent: Friday, November 16, 2007 11:14 AM > To: rampart-dev > Subject: Re: Not able to use Symmetric binding -- Illegal key size or > default parameters > > Seems like the axis2 server couldn't figure out the operation that the > incoming action value is mapped to. > > Does this service and client work without any rampart/security > configuration? > > Thanks, > Ruchith > > Manish Verma wrote: >> Hi Nandana, >> >> Thanks for your help. Yes, now I'm able to move past that problem. >> >> Now I'm stuck at another problem. I see the following -- >> org.apache.axis2.AxisFault: The server did not recognise the action which > it >> received >> >> Could you please help. >> >> >> Regards, >> Manish >> >> >> <ns1:echo >> > xmlns:ns1="http://service.SymmEncSecurity.WS.Axis2.eklavya.org"><ns1:param0> >> Hello world</ns1:param0></ns1:echo> >> org.apache.axis2.AxisFault: The server did not recognise the action which > it >> received: >> at >> > org.apache.axis2.handlers.addressing.AddressingInFaultHandler.invoke(Address >> ingInFaultHandler.java:114) >> at org.apache.axis2.engine.Phase.invoke(Phase.java:292) >> at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:212) >> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:132) >> at >> > org.apache.axis2.description.OutInAxisOperationClient.handleResponse(OutInAx >> isOperation.java:336) >> at >> > org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperatio >> n.java:389) >> at >> > org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisO >> peration.java:211) >> at >> org.apache.axis2.client.OperationClient.execute(OperationClient.java:163) >> at >> org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:528) >> at >> org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:508) >> at >> > org.eklavya.Axis2.WS.SymmEncSecurity.client.SymmEncSecurityServiceClient.mai >> n(Unknown Source) >> null >> >> ---------------------------------- >> Manish Verma >> +91 99155 98590 (Cell) >> +91 172 3056 502 (Work) >> VermaM1947 (AOL) >> [EMAIL PROTECTED] >> >> >> -----Original Message----- >> From: Nandana Mihindukulasooriya [mailto:[EMAIL PROTECTED] >> Sent: Thursday, November 15, 2007 5:02 PM >> To: rampart-dev@ws.apache.org >> Subject: Re: Not able to use Symmetric binding -- Illegal key size or >> default parameters >> >> Hi Manish, >> Did you download the JCE Unlimited Strength Jurisdiction Policy >> files from sun and replaced the necessary files ? >> link [1] shows how to do this if you have not already done it. >> >> Regards, >> Nandana >> >> >> [1] http://wso2.org/forum/thread/2520 >> >> On Nov 15, 2007 4:15 PM, Manish Verma <[EMAIL PROTECTED]> wrote: >> >>> Hi, >>> >>> >>> >>> I am working with Rampart1.3 on Axis 2-1.3. I have successfully executed >>> all the samples, using policy.xml, that comes with Rampart. I am now >>> trying to execute a symmetric encryption example. I am using the attached >>> policy.xml and services.xml file. >>> >>> >>> >>> When I run my client, I get the following error. There may be some > problem >>> with the way my services.xml and policy.xml files are written. I will >>> highly appreciate if someone could help me with it. >>> >>> >>> >>> Regards >>> >>> Manish Verma >>> >>> >>> >>> >>> >>> <ns1:echo xmlns:ns1=" >>> http://service.SymmetricEncSecurity.WS.Axis2.eklavya.org"><param0>Hello >>> world</param0></ns1:echo> >>> >>> org.apache.axis2.AxisFault: Error during encryption >>> >>> at org.apache.rampart.handler.RampartSender.invoke(* >>> RampartSender.java:70*) >>> >>> at org.apache.axis2.engine.Phase.invoke(*Phase.java:292*) >>> >>> at org.apache.axis2.engine.AxisEngine.invoke(*AxisEngine.java:212*) >>> >>> at org.apache.axis2.engine.AxisEngine.send(*AxisEngine.java:377*) >>> >>> at org.apache.axis2.description.OutInAxisOperationClient.send(* >>> OutInAxisOperation.java:374*) >>> >>> at > org.apache.axis2.description.OutInAxisOperationClient.executeImpl >>> (*OutInAxisOperation.java:211*) >>> >>> at org.apache.axis2.client.OperationClient.execute(* >>> OperationClient.java:163*) >>> >>> at org.apache.axis2.client.ServiceClient.sendReceive(* >>> ServiceClient.java:528*) >>> >>> at org.apache.axis2.client.ServiceClient.sendReceive(* >>> ServiceClient.java:508*) >>> >>> at >>> > org.eklavya.Axis2.WS.SymmetricEncSecurity.client.SymmetricEncSecurityService >> Client.main >>> (*SymmetricEncSecurityServiceClient.java:70*) >>> >>> Caused by: *org.apache.rampart.RampartException*: Error during encryption >>> >>> at >>> org.apache.rampart.builder.SymmetricBindingBuilder.doSignBeforeEncrypt(* >>> SymmetricBindingBuilder.java:540*) >>> >>> at org.apache.rampart.builder.SymmetricBindingBuilder.build(* >>> SymmetricBindingBuilder.java:80*) >>> >>> at > org.apache.rampart.MessageBuilder.build(*MessageBuilder.java:128* >>> ) >>> >>> at org.apache.rampart.handler.RampartSender.invoke(* >>> RampartSender.java:64*) >>> >>> ... 9 more >>> >>> Caused by: *org.apache.ws.security.WSSecurityException*: Cannot >>> encrypt/decrypt data; nested exception is: >>> >>> *org.apache.xml.security.encryption.XMLEncryptionException*: > Illegal >>> key size or default parameters >>> >>> Original Exception was *java.security.InvalidKeyException*: Illegal key >>> size or default parameters >>> >>> at org.apache.ws.security.message.WSSecEncrypt.doEncryption(* >>> WSSecEncrypt.java:480*) >>> >>> at org.apache.ws.security.message.WSSecEncrypt.doEncryption(* >>> WSSecEncrypt.java:406*) >>> >>> at > org.apache.ws.security.message.WSSecEncrypt.encryptForExternalRef >>> (*WSSecEncrypt.java:362*) >>> >>> at >>> org.apache.rampart.builder.SymmetricBindingBuilder.doSignBeforeEncrypt(* >>> SymmetricBindingBuilder.java:528*) >>> >>> ... 12 more >>> >>> Caused by: *org.apache.xml.security.encryption.XMLEncryptionException*: >>> Illegal key size or default parameters >>> >>> Original Exception was *java.security.InvalidKeyException*: Illegal key >>> size or default parametersnull >>> >>> >>> >>> at org.apache.xml.security.encryption.XMLCipher.encryptData(Unknown >>> Source) >>> >>> at org.apache.xml.security.encryption.XMLCipher.encryptData(Unknown >>> Source) >>> >>> at >>> > org.apache.xml.security.encryption.XMLCipher.encryptElementContent(Unknown >>> Source) >>> >>> at org.apache.xml.security.encryption.XMLCipher.doFinal(Unknown >>> Source) >>> >>> at org.apache.ws.security.message.WSSecEncrypt.doEncryption(* >>> WSSecEncrypt.java:475*) >>> >>> ... 15 more >>> >>> >>> >>> >>> >>> ---------------------------------- >>> >>> Manish Verma >>> >>> +91 99155 98590 (Cell) >>> >>> +91 172 3056 502 (Work) >>> >>> VermaM1947 (AOL) >>> >>> [EMAIL PROTECTED] >>> >>> >>> >>> >>> >> >> > -- http://blog.ruchith.org http://wso2.org