cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Graeme Hill <Graeme.H...@empired.com>
Subject WS-RM : Server sending LastMessage for SourceSequence termination back to itself.
Date Mon, 11 Apr 2016 05:46:39 GMT
We have recently identified an issue with the WS-RM LastMessage event on a WS-RM Endpoint termination
sending the LastMessage xml back onto itself. e.g. server A instead of sending LastMessage
to Client A sends the transaction back to its own Server Endpoint Address..

The scenario is a WS-RM transaction using request/response so the source message contains
a sequence and the response message contains a sequence also. The sequence in the response
is the sequence offered by the client in the CreateSequence request as per the WS-RM specification.

SInce the LastMessage isnt sent properly, the client doesn't reset any sequences and when
the server is started again all subsequent sequence id are considered invalid. Since the sequences
don't expire the client will always use the same sequence until told otherwise.

Ws-RM doesn't have any specfic client config.

I cannot include the WSDL as it's commercially sensistive. It does however provide a request
response pattern:

    <wsdl:binding name="xxxBinding" type="tns:xxxx">
        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"
/>
        <wsaw:UsingAddressing wsdl:required="true"/>
        <wsp:PolicyReference URI="#UnifiedMessaging_Policy" />
        <wsdl:operation name="xxxxxxx">
            <soap:operation soapAction="http://xxxxxxxx" style="document" />
            <wsdl:input name="xxxxxRequest">
                <soap:body use="literal" />
            </wsdl:input>
            <wsdl:output>
                <soap:body use="literal" />
            </wsdl:output>
        </wsdl:operation>
    </wsdl:binding>


Server source policy config:
                <wsrm-mgr:sourcePolicy includeOffer="false" sequenceExpiration="PT0S">
                    <wsrm-mgr:sequenceTerminationPolicy terminateOnShutdown="true" />
                </wsrm-mgr:sourcePolicy>

Server WSDL Assertion:
            <wsrmp:RMAssertion>
                <wsrmp:BaseRetransmissionInterval Milliseconds="10000" />
                <wsrmp:AcknowledgementInterval Milliseconds="5000" />
            </wsrmp:RMAssertion>

The platform is JBoss Fuse 6.1 which contains cxf 2.7.0

Has anyone else seen this scenario ? It seems like request/response with offers seems to be
a rare use pattern.

Some XML examples of the WS-RM transaction

ID: 1
Address: https://10.15.2.10:9001/cxf/service
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml; charset=UTF-8
Headers: {Accept=[*/*], Cache-Control=[no-cache], connection=[keep-alive], Content-Length=[1534],
content-type=[text/xml; charset=UTF-8], Host=[10.15.2.10:9001], Pragma=[no-cache], SOAPAction=["http://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequence"],
User-Agent=[Apache CXF 2.7.0.redhat-610379]}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<Action xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequence</Action>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:33c3f781-966d-46e2-acc7-5b0efefc7c2e</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">https://10.15.2.10:9001/cxf/service</To>
<ReplyTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<Address>http://10.2.122.92:9990/decoupled_endpoint</Address>
</ReplyTo>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
soap:mustUnderstand="1">
<wsse:UsernameToken wsu:Id="UsernameToken-65B958CE914DA0512E14593984175601">
<wsse:Username>xxx</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">yyyy</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soap:Header>
<soap:Body>
<CreateSequence xmlns="http://schemas.xmlsoap.org/ws/2005/02/rm" xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<AcksTo>
<ns2:Address>http://10.2.122.92:9990/decoupled_endpoint</ns2:Address>
</AcksTo>
<Expires>PT0S</Expires>
<Offer>
<Identifier>urn:uuid:d10bc416-acd0-40e8-a1bd-f1a1a552c39b</Identifier>
<Expires>PT0S</Expires>
</Offer>
</CreateSequence>
</soap:Body>
</soap:Envelope>
--------------------------------------

ID: 1
Response-Code: 202
Encoding: UTF-8
Content-Type: text/xml
Headers: {}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:3ca0fb2f-8a6d-4848-92d2-df7ae0be7efb</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</To>
<RelatesTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://www.w3.org/2005/08/addressing/unspecified</RelatesTo>
</soap:Header>
<soap:Body/>
</soap:Envelope>

Outbound Message TO SOAP CLIENT
---------------------------
ID: 1
Address: http://10.2.122.92:9990/decoupled_endpoint
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml
Headers: {Accept=[*/*]}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<Action xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequenceResponse</Action>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:1d262900-74e4-4700-be70-6d9dfd48122b</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://10.2.122.92:9990/decoupled_endpoint</To>
<RelatesTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:33c3f781-966d-46e2-acc7-5b0efefc7c2e</RelatesTo>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
soap:mustUnderstand="1">
<wsse:UsernameToken xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
wsu:Id="UsernameToken-5A6B2E8551939059E514593984185241">
<wsse:Username>xxxxx</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">yyyyyy</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soap:Header>
<soap:Body>
<CreateSequenceResponse xmlns="http://schemas.xmlsoap.org/ws/2005/02/rm" xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<Identifier>urn:uuid:03e0f5f8-9a4c-421c-9cce-0a66b94888ae</Identifier>
<Expires>PT0S</Expires>
<Accept>
<AcksTo>
<ns2:Address>https://10.15.2.10:9001/cxf/service</ns2:Address>
</AcksTo>
</Accept>
</CreateSequenceResponse>
</soap:Body>
</soap:Envelope>
--------------------------------------

Inbound Message FROM SOAP CLIENT
----------------------------
ID: 2
Address: https://10.15.2.10:9001/cxf/servicehttps://10.15.2.10:9001/cxf/service
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml; charset=UTF-8
Headers: {Accept=[*/*], Cache-Control=[no-cache], connection=[keep-alive], content-type=[text/xml;
charset=UTF-8], Host=[10.15.2.10:9001], Pragma=[no-cache], SOAPAction=["http://xxxxxxxxxxx],
transfer-encoding=[chunked], User-Agent=[Apache CXF 2.7.0.redhat-610379]}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<Action xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://xxxxxxxxxxx</Action>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:35f455d9-a276-4edf-bb26-36e0e5ae6b37</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">https://10.15.2.10:9001/cxf/service</To>
<ReplyTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<Address>http://10.2.122.92:9990/decoupled_endpoint</Address>
</ReplyTo>
<wsrm:Sequence xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsrm="http://schemas.xmlsoap.org/ws/2005/02/rm"
soap:mustUnderstand="1">
<wsrm:Identifier>urn:uuid:03e0f5f8-9a4c-421c-9cce-0a66b94888ae</wsrm:Identifier>
<wsrm:MessageNumber>1</wsrm:MessageNumber>
</wsrm:Sequence>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
soap:mustUnderstand="1">
<wsse:UsernameToken wsu:Id="UsernameToken-65B958CE914DA0512E14593984186992">
<wsse:Username>xxxxx</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">yyyyy</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soap:Header>
<soap:Body>
<WSDL INPUT BODY MESSAGE/>
</soap:Body>
</soap:Envelope>
--------------------------------------

Outbound Message TO SOAP CLIENT
---------------------------
ID: 2
Response-Code: 202
Encoding: UTF-8
Content-Type: text/xml
Headers: {}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:0bc725e1-534d-4653-9f16-2ea02a0657f4</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</To>
<RelatesTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://www.w3.org/2005/08/addressing/unspecified</RelatesTo>
</soap:Header>
<soap:Body/>
</soap:Envelope>
--------------------------------------

Outbound Message TO SOAP CLIENT
---------------------------
ID: 2
Address: http://10.2.122.92:9990/decoupled_endpoint
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml
Headers: {Accept=[*/*], breadcrumbId=[ID-fuse1-37687-1459398351533-0-1], Host=[10.15.2.10:9001],
SOAPAction=[http://xxxxx], startTime=[1459398418701], successful=[true], User-Agent=[Apache
CXF 2.7.0.redhat-610379]}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<Action xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://xxxxxxxxxxxx</Action>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:851099ff-7cae-4f3b-9656-bcf1e4119913</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://10.2.122.92:9990/decoupled_endpoint</To>
<RelatesTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:35f455d9-a276-4edf-bb26-36e0e5ae6b37</RelatesTo>
<wsrm:Sequence xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsrm="http://schemas.xmlsoap.org/ws/2005/02/rm"
soap:mustUnderstand="1">
<wsrm:Identifier>urn:uuid:d10bc416-acd0-40e8-a1bd-f1a1a552c39b</wsrm:Identifier>
<wsrm:MessageNumber>1</wsrm:MessageNumber>
</wsrm:Sequence>
<wsrm:SequenceAcknowledgement xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing"
xmlns:wsrm="http://schemas.xmlsoap.org/ws/2005/02/rm">
<wsrm:Identifier>urn:uuid:03e0f5f8-9a4c-421c-9cce-0a66b94888ae</wsrm:Identifier>
<wsrm:AcknowledgementRange Lower="1" Upper="1"/>
</wsrm:SequenceAcknowledgement>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
soap:mustUnderstand="1">
<wsse:UsernameToken wsu:Id="UsernameToken-65B958CE914DA0512E14593984186992">
<wsse:Username>xxxx</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">yyyyyyy</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soap:Header>
<soap:Body>
<WSDL OUTPUT BODY MESSAGE>
</soap:Body>
</soap:Envelope>
--------------------------------------

Output Message TO CLIENT
----------------------------
ID: 4
Address: https://10.15.2.10:9001/cxf/servicehttps://10.15.2.10:9001/cxf/service
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml; charset=UTF-8
Headers: {Accept=[*/*], Cache-Control=[no-cache], connection=[keep-alive], Content-Length=[1339],
content-type=[text/xml; charset=UTF-8], Host=[10.15.2.10:9001], Pragma=[no-cache], SOAPAction=["http://schemas.xmlsoap.org/ws/2005/02/rm/SequenceAcknowledgement"],
User-Agent=[Apache CXF 2.7.0.redhat-610379]}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<Action xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2005/02/rm/SequenceAcknowledgement</Action>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:19ec4cd7-d0ad-43ce-b94c-dee5f4e8d1b2</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">https://10.15.2.10:9001/cxf/service</To>
<wsrm:SequenceAcknowledgement xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing"
xmlns:wsrm="http://schemas.xmlsoap.org/ws/2005/02/rm">
<wsrm:Identifier>urn:uuid:d10bc416-acd0-40e8-a1bd-f1a1a552c39b</wsrm:Identifier>
<wsrm:AcknowledgementRange Lower="1" Upper="1"/>
</wsrm:SequenceAcknowledgement>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
soap:mustUnderstand="1">
<wsse:UsernameToken wsu:Id="UsernameToken-65B958CE914DA0512E14593984199953">
<wsse:Username>xxxxx</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">yyyyyyyyyyy</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soap:Header>
<soap:Body/>
</soap:Envelope>
--------------------------------------


ID: 4
Response-Code: 202
Encoding: UTF-8
Content-Type: text/xml
Headers: {}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:d3478830-e787-4562-8429-6b87919e5f36</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</To>
<RelatesTo xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://www.w3.org/2005/08/addressing/unspecified</RelatesTo>
</soap:Header>
<soap:Body/>
</soap:Envelope>
--------------------------------------

System is now shutdown


Outbound Message To client is instead sent from server to itself
---------------------------
ID: 5
Address: https://10.15.2.10:9001/cxf/service
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml
Headers: {Accept=[*/*], SOAPAction=["http://schemas.xmlsoap.org/ws/2005/02/rm/LastMessage"]}
Payload: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<Action xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://schemas.xmlsoap.org/ws/2005/02/rm/LastMessage</Action>
<MessageID xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">urn:uuid:f7f4fd64-2ade-425a-b32a-27457fb0e8bd</MessageID>
<To xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">https://10.15.2.10:9001/cxf/service</To>
<wsrm:Sequence xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsrm="http://schemas.xmlsoap.org/ws/2005/02/rm"
soap:mustUnderstand="1">
<wsrm:Identifier>urn:uuid:d10bc416-acd0-40e8-a1bd-f1a1a552c39b</wsrm:Identifier>
<wsrm:MessageNumber>2</wsrm:MessageNumber>
<wsrm:LastMessage/>
</wsrm:Sequence>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
soap:mustUnderstand="1">
<wsse:UsernameToken wsu:Id="UsernameToken-5A6B2E8551939059E514593987877012">
<wsse:Username>xxxxx</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">yyyyyyy</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</soap:Header>
<soap:Body/>
</soap:Envelope>
--------------------------------------


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message