[WSIT-1616] metro RM sends mustUnderstand="true" for SOAP 1.1 messages Created: 22/Mar/12  Updated: 20/May/13  Resolved: 20/May/13

Status: Resolved
Project: wsit
Component/s: rm
Affects Version/s: 2.2
Fix Version/s: 2.3.1

Type: Bug Priority: Major
Reporter: bnaugle Assignee: Uday Joshi
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

NA


Tags: metro2_2_1-waived

 Description   

Create a client with a Feature created like this :
ReliableMessagingFeatureBuilder fb = new ReliableMessagingFeatureBuilder(RmProtocolVersion.WSRM200502);
fb.maxRmSessionControlMessageResendAttempts(1);

invoke the client with a SOAP1.1 message, and this goes over the wire :
<ns3:Sequence xmlns:ns2="http://www.w3.org/2005/08/addressing" xmlns:ns3="http://schemas.xmlsoap.org/ws/2005/02/rm" xmlns="" xmlns:ns5="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:ns6="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:ns7="http://docs.oasis-open.org/wss/oasis-wss-wssecurity-secext-1.1.xsd" xmlns:ns8="http://schemas.microsoft.com/ws/2006/05/rm" env:mustUnderstand="true"><ns3:Identifier>91da7384-83b5-457a-8afc-cf2b365a0821</ns3:Identifier><ns3:MessageNumber>1</ns3:MessageNumber></ns3:Sequence>

For soap1.1 the value for mustUnderstand can only be 0 or 1 but true is used as shown above.
Note that soap 1.2 allows mustUnderstand values to be false or true.



 Comments   
Comment by Uday Joshi [ 20/May/13 ]

Right.

1) From SOAP 1.1 spec:

http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383500

4.2.3 SOAP mustUnderstand Attribute

The SOAP mustUnderstand global attribute can be used to indicate whether a header entry is mandatory or optional for the recipient to process. The recipient of a header entry is defined by the SOAP actor attribute (see section 4.2.2). The value of the mustUnderstand attribute is either "1" or "0". The absence of the SOAP mustUnderstand attribute is semantically equivalent to its presence with the value "0".

2) From SOAP 1.2 spec:

http://www.w3.org/TR/soap12-part1/#soapmu

5.2.3 SOAP mustUnderstand Attribute

The SOAP mustUnderstand attribute information item is used to indicate whether the processing of a SOAP header block is mandatory or optional (see 2.4 Understanding SOAP Header Blocks)

The mustUnderstand attribute information item has the following XML infoset properties:

A [local name] of mustUnderstand .

A [namespace name] of "http://www.w3.org/2003/05/soap-envelope".

A [specified] property with a value of "true".

The type of the mustUnderstand attribute information item is xs:boolean.

Omitting this attribute information item is defined as being semantically equivalent to including it with a value of "false".

SOAP senders SHOULD NOT generate, but SOAP receivers MUST accept, the SOAP mustUnderstand attribute information item with a value of "false" or "0".

If generating a SOAP mustUnderstand attribute information item, a SOAP sender SHOULD use the canonical representation "true" of the attribute value (see XML Schema [XML Schema Part 2]). A SOAP receiver MUST accept any valid lexical representation of the attribute value.

If relaying the message, a SOAP intermediary MAY substitute "true" for the value "1", or "false" for "0". In addition, a SOAP intermediary MAY omit a SOAP mustUnderstand attribute information item if its value is "false" (see 2.7 Relaying SOAP Messages).

A SOAP sender generating a SOAP message SHOULD use the mustUnderstand attribute information item only on SOAP header blocks. A SOAP receiver MUST ignore this attribute information item if it appears on descendants of a SOAP header block or on a SOAP body child element information item (or its descendents).

Comment by Uday Joshi [ 20/May/13 ]

Fixed in current trunk (2.3.1) svn revision 7569.

Generated at Sun Sep 25 02:31:35 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.