You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by sh_santosh <sa...@gmail.com> on 2008/07/03 11:55:15 UTC

How to consume .Net ( with WSE3.0 security enabled ) web services using Java Client(Axis 1.3)

Dear all,

I have to consume .Net web services( WSE 3.0 enabled) from Java Client. I am
using Axis 1.3 , jakarta-tomcat-5.0.28.
They have enabled WSE 3.0 in .Net web services ( Doc / Literal web services
).

Problem : Security requirements are not satisfied because the security
header is not present in the incoming message .When we invoke .Net web
services from Java client, we are getting above exception.

It's clear that we have to add security header in request xml but the
problem is how to add header. We have added security header manually but it
didn't work.

So, we search on google and found that we can use wss4j-1.5.4.jar to SOLVE
this issue.
we have implemented this but it didn't work too......I think i some where
missing in configuration setting.

How to solve this issue. 
How can we use this wss4j-1.5.4.jar concept to solve this issue. 

Please find the exception -

Exception in thread "main" AxisFault
 faultCode:
{http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd}Security
 faultSubcode: 
 faultString: Microsoft.Web.Services3.Security.SecurityFault: Security
requirements are not satisfied because the security header is not present in
the incoming message.
   at
Microsoft.Web.Services3.Design.UsernameOverTransportAssertion.ServiceInputFilter.ValidateMessageSecurity(SoapEnvelope
envelope, Security security)
   at
Microsoft.Web.Services3.Security.ReceiveSecurityFilter.ProcessMessage(SoapEnvelope
envelope)
   at Microsoft.Web.Services3.Pipeline.ProcessInputMessage(SoapEnvelope
envelope)
   at Microsoft.Web.Services3.WseProtocol.FilterRequest(SoapEnvelope
requestEnvelope)
   at Microsoft.Web.Services3.WseProtocol.RouteRequest(SoapServerMessage
message)
   at System.Web.Services.Protocols.SoapServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type,
HttpContext context, HttpRequest request, HttpResponse response,
Boolean&amp; abortProcessing)
 faultActor: https://annetest.com/bookingapi.asmx
 faultNode: 
 faultDetail: 

{http://xml.apache.org/axis/}stackTrace:Microsoft.Web.Services3.Security.SecurityFault:
Security requirements are not satisfied because the security header is not
present in the incoming message.
   at
Microsoft.Web.Services3.Design.UsernameOverTransportAssertion.ServiceInputFilter.ValidateMessageSecurity(SoapEnvelope
envelope, Security security)
   at
Microsoft.Web.Services3.Security.ReceiveSecurityFilter.ProcessMessage(SoapEnvelope
envelope)
   at Microsoft.Web.Services3.Pipeline.ProcessInputMessage(SoapEnvelope
envelope)
   at Microsoft.Web.Services3.WseProtocol.FilterRequest(SoapEnvelope
requestEnvelope)
   at Microsoft.Web.Services3.WseProtocol.RouteRequest(SoapServerMessage
message)
   at System.Web.Services.Protocols.SoapServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type,
HttpContext context, HttpRequest request, HttpResponse response,
Boolean&amp; abortProcessing)
	at
org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:222)
	at
org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:129)
	at
org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
	at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:633)
	at
com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanEndElement(XMLNSDocumentScannerImpl.java:719)
	at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1685)
	at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)
	at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)
	at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
	at
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
	at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1242)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
	at
org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227)
	at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696)
	at org.apache.axis.Message.getSOAPEnvelope(Message.java:435)
	at
org.apache.axis.handlers.soap.MustUnderstandChecker.invoke(MustUnderstandChecker.java:62)
	at org.apache.axis.client.AxisClient.invoke(AxisClient.java:206)
	at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
	at org.apache.axis.client.Call.invoke(Call.java:2767)
	at org.apache.axis.client.Call.invoke(Call.java:2443)
	at org.apache.axis.client.Call.invoke(Call.java:2366)
	at org.apache.axis.client.Call.invoke(Call.java:1812)
	at 


Please guide.

What will be the possible solution ?

Any will be much Appreciate .
 

Regards
Santosh
-- 
View this message in context: http://www.nabble.com/soapenv%3AServer.userException---SimpleDeserializer-encountered-a-child-element%2C-which-is-NOT-expected%2C-in-something-it-was-trying-to-deserialize-tp16296688p18255849.html
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: How to consume .Net ( with WSE3.0 security enabled ) web services using Java Client(Axis 1.3)

Posted by Xinjun Chen <xj...@gmail.com>.
Hi Santosh,

You can use WSS4J directly instead of Rampart.

http://ws.apache.org/wss4j/axis.html
http://weblogs.asp.net/jdanforth/archive/2005/01/16/354060.aspx


Regards,
Xinjun


On 7/5/08, sh_santosh <sa...@gmail.com> wrote:
>
>
> Dear all,
>
> Please refer these link :
>
> http://weblogs.asp.net/jdanforth/archive/2005/01/16/354060.aspx
> http://weblogs.asp.net/jdanforth/archive/2005/01/22/358764.aspx
>
> Regards
> Santosh Sharma
> NCSTian
>
>
> sh_santosh wrote:
> >
> > Dear all,
> >
> > can please suggest some tutorial or Link or your guidelines using Axis
> 1.3
> > , jakarta-tomcat-5.0.28.
> >
> > Regards
> > Santosh
> >
> >
> >
> > Nunny wrote:
> >>
> >> Hi Santosh,
> >>
> >> I have to consume .Net web services( WSE 3.0 enabled) from Java Client.
> I
> >> am
> >>> using Axis 1.3 , jakarta-tomcat-5.0.28.
> >>> They have enabled WSE 3.0 in .Net web services ( Doc / Literal web
> >>> services
> >>> ).
> >>>
> >>> Problem : Security requirements are not satisfied because the security
> >>> header is not present in the incoming message .When we invoke .Net web
> >>> services from Java client, we are getting above exception.
> >>>
> >>>
> >>> What will be the possible solution ?
> >>
> >>
> >> You can use  Apache Rampart  [1]  to solve your problem.  Apache Rampart
> >> is
> >> the security module for Axis 2.
> >> Can you post the WSDL of the service you want to consume so that I will
> >> be
> >> able to tell you the exact steps to follow.
> >>
> >> [1] - http://ws.apache.org/rampart/
> >>
> >> --
> >> Nandana Mihindukulasooriya
> >> WSO2 inc.
> >>
> >> http://nandana83.blogspot.com/
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/soapenv%3AServer.userException---SimpleDeserializer-encountered-a-child-element%2C-which-is-NOT-expected%2C-in-something-it-was-trying-to-deserialize-tp16296688p18292867.html
> Sent from the Axis - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>

Re: How to consume .Net ( with WSE3.0 security enabled ) web services using Java Client(Axis 1.3)

Posted by sh_santosh <sa...@gmail.com>.
Dear all,

Please refer these link :

http://weblogs.asp.net/jdanforth/archive/2005/01/16/354060.aspx
http://weblogs.asp.net/jdanforth/archive/2005/01/22/358764.aspx

Regards
Santosh Sharma
NCSTian


sh_santosh wrote:
> 
> Dear all,
> 
> can please suggest some tutorial or Link or your guidelines using Axis 1.3
> , jakarta-tomcat-5.0.28.
> 
> Regards
> Santosh
> 
> 
> 
> Nunny wrote:
>> 
>> Hi Santosh,
>> 
>> I have to consume .Net web services( WSE 3.0 enabled) from Java Client. I
>> am
>>> using Axis 1.3 , jakarta-tomcat-5.0.28.
>>> They have enabled WSE 3.0 in .Net web services ( Doc / Literal web
>>> services
>>> ).
>>>
>>> Problem : Security requirements are not satisfied because the security
>>> header is not present in the incoming message .When we invoke .Net web
>>> services from Java client, we are getting above exception.
>>>
>>>
>>> What will be the possible solution ?
>> 
>> 
>> You can use  Apache Rampart  [1]  to solve your problem.  Apache Rampart
>> is
>> the security module for Axis 2.
>> Can you post the WSDL of the service you want to consume so that I will
>> be
>> able to tell you the exact steps to follow.
>> 
>> [1] - http://ws.apache.org/rampart/
>> 
>> -- 
>> Nandana Mihindukulasooriya
>> WSO2 inc.
>> 
>> http://nandana83.blogspot.com/
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/soapenv%3AServer.userException---SimpleDeserializer-encountered-a-child-element%2C-which-is-NOT-expected%2C-in-something-it-was-trying-to-deserialize-tp16296688p18292867.html
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: How to consume .Net ( with WSE3.0 security enabled ) web services using Java Client(Axis 1.3)

Posted by sh_santosh <sa...@gmail.com>.
Dear all,

can please suggest some tutorial or Link or your guidelines using Axis 1.3 ,
jakarta-tomcat-5.0.28.

Regards
Santosh



Nunny wrote:
> 
> Hi Santosh,
> 
> I have to consume .Net web services( WSE 3.0 enabled) from Java Client. I
> am
>> using Axis 1.3 , jakarta-tomcat-5.0.28.
>> They have enabled WSE 3.0 in .Net web services ( Doc / Literal web
>> services
>> ).
>>
>> Problem : Security requirements are not satisfied because the security
>> header is not present in the incoming message .When we invoke .Net web
>> services from Java client, we are getting above exception.
>>
>>
>> What will be the possible solution ?
> 
> 
> You can use  Apache Rampart  [1]  to solve your problem.  Apache Rampart
> is
> the security module for Axis 2.
> Can you post the WSDL of the service you want to consume so that I will be
> able to tell you the exact steps to follow.
> 
> [1] - http://ws.apache.org/rampart/
> 
> -- 
> Nandana Mihindukulasooriya
> WSO2 inc.
> 
> http://nandana83.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/soapenv%3AServer.userException---SimpleDeserializer-encountered-a-child-element%2C-which-is-NOT-expected%2C-in-something-it-was-trying-to-deserialize-tp16296688p18273078.html
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: How to consume .Net ( with WSE3.0 security enabled ) web services using Java Client(Axis 1.3)

Posted by Nandana Mihindukulasooriya <na...@gmail.com>.
Hi Santosh,

I have to consume .Net web services( WSE 3.0 enabled) from Java Client. I am
> using Axis 1.3 , jakarta-tomcat-5.0.28.
> They have enabled WSE 3.0 in .Net web services ( Doc / Literal web services
> ).
>
> Problem : Security requirements are not satisfied because the security
> header is not present in the incoming message .When we invoke .Net web
> services from Java client, we are getting above exception.
>
>
> What will be the possible solution ?


You can use  Apache Rampart  [1]  to solve your problem.  Apache Rampart is
the security module for Axis 2.
Can you post the WSDL of the service you want to consume so that I will be
able to tell you the exact steps to follow.

[1] - http://ws.apache.org/rampart/

-- 
Nandana Mihindukulasooriya
WSO2 inc.

http://nandana83.blogspot.com/