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

PolicyVerificationOutInterceptor writes faults at wrong phase when processing response

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.1.2
    • 2.1.3
    • WS-* Components
    • None

    Description

      When a CXF response is processed on an endpoint that contains policy assertions (via spring, WSDL, etc), and the policy assertions are not marked as asserted, the PolicyVerificationOutInterceptor properly raises a SOAP fault. However, this interceptor is inserted into the "post-stream" phase, and it seems as though the fault gets written to the SOAP body after the business logic has been written.

      So a response in this scenario will come out as follows:

      <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
      <soap:Body>
      <sayHiResponse xmlns="...">
      <responseType>Bonjou</responseType>
      </sayHiResponse>
      <soap:Fault>
      <faultcode>soap:Server</faultcode>
      <faultstring>These policy alternatives can not be satisfied: [snip]</faultstring >
      </soap:Fault>
      </soap:Body>
      </soap:Envelope>

      Attachments

        1. CXF-1849-trunk-r703513.patch
          2 kB
          Fred Dushin

        Activity

          People

            dkulp Daniel Kulp
            fdushin Fred Dushin
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: