Hi Dirk,

Could you create a JIRA and attach the files to it? Some of the files
didn't make it through to the list.

Colm.

On Wed, May 11, 2011 at 8:29 AM, Dirk Rudolph
<[email protected]> wrote:
> Hello again,
>
> I'm now able to confirm this issue. Adding a SOAPHandler to the Server
> configuration breaks the SoapMessage in Interaction with the
> WSS4JInInterceptor.
>
> I've written a class that implements the SOAPHandler interface and added
> this handler. Afterwards the framework wasn't able to retrieve the binding
> information from the message:
>
> WARNUNG: Interceptor for {http://spring.demo/}HelloWorldImplService has
> thrown exception, unwinding now
> org.apache.cxf.interceptor.Fault: No binding operation info while invoking
> unknown method with params unknown.
>        at
> org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:6
> 0)
>        at
> org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInt
> erceptor.java:58)
>        at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>        at
> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>        at
> org.apache.cxf.workqueue.SynchronousExecutor.execute(SynchronousExecutor.jav
> a:37)
>        at
> org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceIn
> vokerInterceptor.java:106)
>        at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain
> .java:263)
>        at
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationOb
> server.java:118)
>        at
> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDes
> tination.java:208)
>        at
> org.apache.cxf.transport.servlet.ServletController.invokeDestination(Servlet
> Controller.java:223)
>        at
> org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.
> java:166)
>        at
> org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServ
> let.java:113)
>        at
> org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractH
> TTPServlet.java:184)
>        at
> org.apache.cxf.transport.servlet.AbstractHTTPServlet.doPost(AbstractHTTPServ
> let.java:107)
>        at javax.servlet.http.HttpServlet.service(HttpServlet.java:595)
>        at
> org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPSer
> vlet.java:163)
>        at
> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:534)
>        at
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:476)
>        at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119
> )
>        at
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:517)
>        at
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java
> :226)
>        at
> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java
> :934)
>        at
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:404)
>        at
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:
> 184)
>        at
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:
> 869)
>        at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117
> )
>        at
> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.
> java:151)
>        at
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:1
> 16)
>        at org.eclipse.jetty.server.Server.handle(Server.java:346)
>        at
> org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:58
> 1)
>        at
> org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnectio
> n.java:1057)
>        at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:807)
>        at
> org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:220)
>        at
> org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:411)
>        at
> org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.
> java:526)
>        at
> org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.j
> ava:41)
>        at
> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:5
> 28)
>        at java.lang.Thread.run(Thread.java:662)
>
> To reproduce the issue copy the attached files into the
> java_first_spring_support example.
>
> java_first_spring_support/pom.xml
> java_first_spring_support/webapp/WEB-INF/beans.xml
> java_first_spring_support/src/demo/spring/servlet/SOAPRequestHandler.java
> java_first_spring_support/src/demo/spring/servlet/UTPasswordCallback.java
>
> In my project I forced the WSS4JInInterceptor to be invoked before the
> SOAPHandlerInterceptor but this isn't a fix only a dirty work around.
>
> Thanks,
> Dirk
>
> -----Ursprüngliche Nachricht-----
> Von: Dirk Rudolph [mailto:[email protected]]
> Gesendet: Montag, 9. Mai 2011 12:59
> An: [email protected]; [email protected]
> Betreff: AW: WSS4JInInceptor breaks recieved SOAPMessage
>
> Hi and thanks for your reply.
>
> I'm sorry but I wasn't able to build a test case based on the given
> examples. The error isn't reproducible with the simple spring example
> because it is related to the SOAPHandler provided by the seamframework. The
> interceptor chain was changed by this handler in a way I didn't understood:
>
> Interceptor chain without org.jboss.seam.webservice.SOAPRequestHandler:
>
> org.apache.cxf.interceptor.AttachmentInInterceptor
> org.apache.cxf.transport.https.CertConstraintsInterceptor
> org.apache.cxf.interceptor.StaxInInterceptor
> org.apache.cxf.binding.soap.saaj.SAAJInInterceptor$SAAJPreInInterceptor
> org.apache.cxf.frontend.WSDLGetInterceptor
> org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor
> org.apache.cxf.binding.soap.interceptor.SoapActionInInterceptor
> org.apache.cxf.binding.soap.interceptor.StartBodyInterceptor
> org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor
> org.apache.cxf.binding.soap.interceptor.MustUnderstandInterceptor
> ...
>
> Interceptor chain with org.jboss.seam.webservice.SOAPRequestHandler:
>
> ...
> org.apache.cxf.interceptor.AttachmentInInterceptor
> org.apache.cxf.transport.https.CertConstraintsInterceptor
> org.apache.cxf.interceptor.StaxInInterceptor
> org.apache.cxf.binding.soap.saaj.SAAJInInterceptor$SAAJPreInInterceptor
> org.apache.cxf.frontend.WSDLGetInterceptor
> org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor
> org.apache.cxf.binding.soap.interceptor.SoapActionInInterceptor
> org.apache.cxf.binding.soap.interceptor.StartBodyInterceptor
> org.apache.cxf.binding.soap.interceptor.MustUnderstandInterceptor
> org.apache.cxf.jaxws.handler.soap.SOAPHandlerInterceptor
> org.apache.cxf.jaxws.handler.logical.LogicalHandlerInInterceptor
> org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor
> ...
>
>
> I think the error is related to the different position of the
> MustUnderstandInterceptor or the LogicalHandlerInInterceptor. Using the
> SOAPHandler caused the firstChild-Property of the Node given to
> WSS4JInInterceptor.advanceBody being null and so no parameters were found
> afterwards.
>
> After removing the handler (removing the <jaxws:handler> tag) and adding a
> custom Interceptor for starting / finishing the lifecycle of seam it works
> like charm.
>
> Thanks,
> Dirk
>
> -----Ursprüngliche Nachricht-----
> Von: Colm O hEigeartaigh [mailto:[email protected]]
> Gesendet: Freitag, 6. Mai 2011 16:09
> An: [email protected]
> Betreff: Re: WSS4JInInceptor breaks recieved SOAPMessage
>
> Hi,
>
> Could you supply a test-case for this?
>
> Colm.
>
> On Thu, May 5, 2011 at 2:46 PM, Dirk Rudolph
> <[email protected]> wrote:
>> Hi @all,
>>
>>
>>
>> I added the WSS4JInInterceptor to the endpoint configured as spring bean
> but
>> this caused a different processing of values received in the soap body.
> Can
>> anyone give me a hint what the problem in my configuration is.
>>
>>
>>
>> Additional informations:
>>
>> The hole service is working without the interceptor and with methods
>> requiring no parameters.
>>
>> I'm using cxf 2.4 with WSS4J 1.6 and UsernameToken authentication.
>>
>>
>>
>> Thanks,
>>
>> Dirk
>>
>>
>>
>> Endpoint config:
>>
>>      <jaxws:endpoint id="PersonenSucheServiceEndpoint"
>>
>>            implementor="#core_ws_PersonenSucheService"
>> address="/PersonenSuche">
>>
>>            <jaxws:inInterceptors>
>>
>>                  <bean
>> class="org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor">
>>
>>                        <constructor-arg>
>>
>>                             <map>
>>
>>                                   <entry key="action"
> value="UsernameToken"
>> />
>>
>>                                   <entry key="passwordType"
>> value="PasswordDigets" />
>>
>>                                   <entry key="passwordCallbackRef">
>>
>>                                         <ref
>> bean="core_ws_security_WebServiceAuthenticationCallback" />
>>
>>                                   </entry>
>>
>>                             </map>
>>
>>                        </constructor-arg>
>>
>>                  </bean>
>>
>>            </jaxws:inInterceptors>
>>
>>            <jaxws:handlers>
>>
>>                  <bean id="seamHandler"
>> class="org.jboss.seam.webservice.SOAPRequestHandler" />
>>
>>            </jaxws:handlers>
>>
>>            <jaxws:features>
>>
>>                  <bean
>> class="org.apache.cxf.transport.common.gzip.GZIPFeature" />
>>
>>                  <bean class="org.apache.cxf.feature.LoggingFeature" />
>>
>>            </jaxws:features>
>>
>>      </jaxws:endpoint>
>>
>>
>>
>> SoapMessage:
>>
>> <soapenv:Envelope
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
>> xmlns:ws="http://ws.core.ebbi.mms_dresden.de/";>
>>
>>   <soapenv:Header><wsse:Security
>>
> xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecuri
>> ty-secext-1.0.xsd"><wsse:UsernameToken wsu:Id="UsernameToken-77"
>>
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurit
>>
> y-utility-1.0.xsd"><wsse:Username>[email protected]</wsse:Username><
>> wsse:Password
>>
> Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token
>> -profile-1.0#PasswordText">*****</wsse:Password><wsse:Nonce
>>
> EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-m
>>
> essage-security-1.0#Base64Binary">ebrntIcuiXDmA0Mk9tC72Q==</wsse:Nonce><wsu:
>>
> Created>2011-05-05T13:40:07.949Z</wsu:Created></wsse:UsernameToken></wsse:Se
>> curity></soapenv:Header>
>>
>>   <soapenv:Body>
>>
>>      <ws:findPersonen>
>>
>>         <ws:query>'az'</ws:query>
>>
>>      </ws:findPersonen>
>>
>>   </soapenv:Body>
>>
>> </soapenv:Envelope>
>>
>>
>>
>> ServiceInterface (only the head and the method)
>>
>>
>>
>> @WebService
>>
>> public interface PersonenSucheService {
>>
>>    @WebMethod(action = "findPersonen")
>>
>>    WSPerson[] findPersonen(@WebParam(
>>
>>                                      name            = "query",
>>
>>                                      targetNamespace = NAMESPACE
>>
>>                                     ) String query);
>>
>> }
>>
>>
>>
>> Stacktrace:
>>
>> org.apache.cxf.interceptor.Fault: wrong number of arguments while invoking
>> public de.mms_dresden.ebbi.core.ws.WSPerson[]
>>
> de.mms_dresden.ebbi.core.ws.impl.PersonenSucheServiceImpl.findPersonen(java.
>> lang.String) with params null.
>>
>>      at
>>
> org.apache.cxf.service.invoker.AbstractInvoker.createFault(AbstractInvoker.j
>> ava:159)
>>
>>      at
>>
> org.apache.cxf.jaxws.AbstractJAXWSMethodInvoker.createFault(AbstractJAXWSMet
>> hodInvoker.java:86)
>>
>>      at
>>
> org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:1
>> 33)
>>
>>      at
>> org.apache.cxf.jaxws.JAXWSMethodInvoker.invoke(JAXWSMethodInvoker.java:61)
>>
>>      at
>>
> org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:7
>> 5)
>>
>>      at
>>
> org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInt
>> erceptor.java:58)
>>
>>      at
>> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>>
>>      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>>
>>      at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>>
>>      at
>>
> org.apache.cxf.workqueue.SynchronousExecutor.execute(SynchronousExecutor.jav
>> a:37)
>>
>>      at
>>
> org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceIn
>> vokerInterceptor.java:106)
>>
>>      at
>>
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain
>> .java:263)
>>
>>      at
>>
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationOb
>> server.java:118)
>>
>>      at
>>
> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDes
>> tination.java:208)
>>
>>      at
>>
> org.apache.cxf.transport.servlet.ServletController.invokeDestination(Servlet
>> Controller.java:223)
>>
>>      at
>>
> org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.
>> java:205)
>>
>>      at
>>
> org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServ
>> let.java:113)
>>
>>      at
>>
> org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractH
>> TTPServlet.java:184)
>>
>>      at
>>
> org.apache.cxf.transport.servlet.AbstractHTTPServlet.doPost(AbstractHTTPServ
>> let.java:107)
>>
>>      at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>
>>      at
>>
> org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPSer
>> vlet.java:163)
>>
>>      at
>> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
>>
>>      at
>>
> org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler
>> .java:1221)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:8
>> 3)
>>
>>      at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:60)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:6
>> 9)
>>
>>      at
>>
> de.mms_dresden.ebbi.core.fe.impl.security.SessionIdFilter.doFilter(SessionId
>> Filter.java:99)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:6
>> 9)
>>
>>      at
>>
> de.mms_dresden.ebbi.core.fe.impl.security.UrlValidationFilter.doFilter(UrlVa
>> lidationFilter.java:54)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:6
>> 9)
>>
>>      at
>> org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:6
>> 9)
>>
>>      at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:6
>> 9)
>>
>>      at org.jboss.seam.web.IdentityFilter.doFilter(IdentityFilter.java:40)
>>
>>      at
>>
> org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:6
>> 9)
>>
>>      at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
>>
>>      at
>>
> org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler
>> .java:1212)
>>
>>      at
>>
> de.mms_dresden.ebbi.core.fe.impl.security.SessionFilter.doFilter(SessionFilt
>> er.java:135)
>>
>>      at
>>
> org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler
>> .java:1212)
>>
>>      at
>> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
>>
>>      at
>>
> org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
>>
>>      at
>> org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
>>
>>      at
>> org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
>>
>>      at
>> org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
>>
>>      at
>>
> org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerColl
>> ection.java:230)
>>
>>      at
>>
> org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:11
>> 4)
>>
>>      at
>> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
>>
>>      at org.mortbay.jetty.Server.handle(Server.java:326)
>>
>>      at
>> org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
>>
>>      at
>>
> org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:
>> 945)
>>
>>      at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
>>
>>      at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
>>
>>      at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
>>
>>      at
>>
> org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
>>
>>      at
>>
> org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582
>> )
>>
>> Caused by: java.lang.IllegalArgumentException: wrong number of arguments
>>
>>      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>
>>      at
>>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
>> )
>>
>>      at
>>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
>> .java:25)
>>
>>      at java.lang.reflect.Method.invoke(Method.java:597)
>>
>>      at
>>
> org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInv
>> oker.java:173)
>>
>>      at
>>
> org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:8
>> 9)
>>
>>      ... 53 more
>>
>>
>
>

Reply via email to