Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-5325

error when having alternative transport bindings in WSDL

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: Invalid
    • Component/s: Configuration
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      Hi,
      we have received a WSDL from a WS provider that allows Basic Authentication or Client Certificate Authentication. When I configure Client Certificate Authentication in the conduit for my CXF WS consumer. I receive the following error

      WARNUNG: Interceptor for

      {http://xi.com/xiveri/source_runtime}

      ZMTOM_CXF_IN#

      {http://xi.com/xiveri/source_runtime}

      CXF_IN has thrown exception, unwinding now
      org.apache.cxf.ws.policy.PolicyException: Assertion of type

      {http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702}

      HttpsToken could not be asserted: HttpBasicAuthentication is set, but not being used
      at org.apache.cxf.ws.security.policy.interceptors.HttpsTokenInterceptorProvider$HttpsTokenOutInterceptor.assertHttps(HttpsTokenInterceptorProvider.java:144)
      at org.apache.cxf.ws.security.policy.interceptors.HttpsTokenInterceptorProvider$HttpsTokenOutInterceptor.handleMessage(HttpsTokenInterceptorProvider.java:87)
      at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:271)
      at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:541)
      at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:467)
      If I just allow Client Certificarte it works. If in the WSDL Client Certificate is defined first it works. If I use WSRM the Create Sequence is executed without error, the message fails.
      I did some investigations. It seems that the HTTPSToken for Client Certificate is correctly evaluated by Neethi/CXF but some how get lost during the WSDL parsing. At the end all alternative policies contain a transport binding (referencing a transport token) referencing a HTTPSToken that requires Basic Authentication. I have attached a maven project that includes a simple junit test. It uses the Camel test functionality (CamelSpringTestSupport) to send directly a message to a CXF endpoint. mvn install or executing the junit test leads automatically to the error described above.

      Best Regards,

      Jörg

        Attachments

          Activity

            People

            • Assignee:
              dkulp Daniel Kulp
              Reporter:
              joerg Joerg Heinicke
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: