Using the Simple Object Access Protocol (SOAP)

in Blocks Extensible Exchange Protocol (BEEP)

Status of This Memo

This document specifies an Internet standards track protocol for the
Internet community, and requests discussion and suggestions for
improvements. Please refer to the current edition of the "Internet
Official Protocol Standards" (STD 1) for the standardization state
and status of this protocol. Distribution of this memo is unlimited.

1. Introduction

This memo specifies how SOAP envelopes [15] are transmitted using a
BEEP profile [1]. Conforming implementations MUST support SOAP
version 1.2 [15] and MAY support other versions, such as SOAP version
1.1 [17]. This memo specifies how SOAP envelopes [15] are
transmitted using a BEEP profile [1]. Unlike its predecessor,
RFC3288 [16], this memo does not mandate the use of SOAP version 1.1.

Throughout this memo, the term "envelope" refers to the top-level
element exchanged by SOAP senders and receivers. For example, when
referring to SOAP version 1.2, the term "envelope" refers to the
"Envelope" element defined in Section 5.1 of [2]. Furthermore, the
terms "peer", "client", "server", "one-to-one", and "one-to-many" are
used in the context of BEEP. In particular, Sections 2.1 and 2.1.1
of [1] discuss BEEP roles and exchange styles.

2. BEEP Profile Identification

The BEEP profile for SOAP is identified as

http://iana.org/beep/soap/VERSION

in the BEEP "profile" element during channel creation. where
"VERSION" refers to the numeric version of the SOAP specification.

for the purposes of profile identification for SOAP version 1.1
envelopes [17]. If an implementation of this memo chooses to
implement SOAP version 1.1, then it should support both this Uniform
Resource Identifier (URI) for profile identification as well as
"http://iana.org/beep/soap/1.1".

In BEEP, when the first channel is successfully created, the
"serverName" attribute in the "start" element identifies the "virtual
host" associated with the peer acting in the server role, e.g.,

the "resource" attribute, which is analogous to HTTP's "abs_path"
Request-URI parameter (cf. Section 5.1.2 of [4]) and

the "features" attribute, which, if present, contains one or more
feature tokens, each indicating an optional feature of the BEEP
profile for SOAP that is being requested for possible use over the
channel.

Section 7.1 defines a registration template for optional features.

If the peer acting in the server role recognizes the requested
resource, it replies with the boot response that contains one
optional attribute:

The "features" attribute, if present, contains a subset of the
feature tokens in the boot message, indicating which features may
be used over the channel. (If not present or empty, then no
features may be used.)

Otherwise, if the boot message is improperly formed, or if the
requested resource is not recognized, the peer acting in the server
role replies with an error message (cf. Section 7.1 of [1]).
Typically, the boot message and its response are exchanged during
channel initialization (cf. Section 2.3.1.2 of [1]).

For example, here the boot message and its response are exchanged
during channel initialization:

Consult Section 4.1 of XOP [8] for guidance on MIME Multipart/Related
usage. Because BEEP provides an 8-bit-wide path, a "transformative"
Content-Transfer-Encoding (e.g., "base64" or "quoted-printable")
should not be used. Note that MIME [9] requires that the value of
the "Content-ID" header be globally unique. As stated in Section 4
of XOP [8], XOP may be used with diverse packaging mechanisms. When
an implementation of BEEP in SOAP does support MTOM/XOP, it SHOULD
support the MIME Multipart/Related XOP Package format, and MAY
support others. Additional formats could, in the future, include XOP
package formats specific to BEEP (e.g., sending the attachments on a
different channel to the SOAP channel, which would avoid searching
for the MIME boundary tags and allows lazy delivery of attachments,
delivering them only when really needed.)

4. SOAP Message Patterns

4.1. One-Way Message

A one-way message involves sending a message without any response
being returned.

The BEEP profile for SOAP achieves this using a one-to-many exchange,
in which the client sends a "MSG" message containing an envelope, and
the server immediately sends back a "NUL" message, before processing
the contents of the envelope.

4.2. Request-Response Exchange

A request/response exchange involves sending a request, which results
in a response being returned.

The BEEP profile for SOAP achieves this using a one-to-one exchange,
in which the client sends a "MSG" message containing an envelope, and
the server sends back a "RPY" message containing an envelope.

4.3. Request/N-Responses Exchange

A request/N-responses exchange involves sending a request, which
results in zero or more responses being returned.

The BEEP profile for SOAP achieves this using a one-to-many exchange,
in which the client sends a "MSG" message containing an envelope, and
the server sends back zero or more "ANS" messages, each containing an
envelope, followed by a "NUL" message.

4.4. Error Handling

The BEEP profile for SOAP does not use the "ERR" message for SOAP
faults. When performing one-to-one exchanges, whatever SOAP response
(including SOAP faults) generated by the server is always returned in
the "RPY" message. When performing one-to-many exchanges, whatever
SOAP response (including SOAP faults) generated by the server is
always returned in the "ANS" messages.

If there is an error with the BEEP message unrelated to the SOAP
envelope (e.g., poorly formed MIME message or MIME Content-Type not
supported), then the server responds with an ERR message (see Section
7.1 of [1]) with an appropriate reply code (e.g., see Section 8 of
[1]).

5. SOAP Protocol Binding Framework Conformance

5.1. Binding Name

This binding is identified by a URI that is exactly the same as the
profile URI for BEEP in SOAP (see Section 2).

5.2. Base URI

The Base URI for the SOAP envelope is the URI of the resource
identified in the bootmsg.

5.3. Supported SOAP Message Exchange Patterns

An implementation of this binding MUST support the following SOAP
Message Exchange Pattern (MEP):

5.4. Supported Features

An implementation of this binding MAY support the following feature:
"http://www.w3.org/2003/05/soap/features/action/" (see Section 6.5 of
[3].)

5.5. MEP Operation

For binding instances conforming to this specification:

A SOAP node instantiated at the BEEP peer that initiates the
message exchange may assume the role (i.e., the property http://
www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role ) of
"RequestingSOAPNode".

A SOAP node instantiated at the other BEEP peer may assume the
role (i.e., the property http://www.w3.org/2003/05/soap/
bindingFramework/ExchangeContext/Role) of "RespondingSOAPNode".

5.5.1. Behavior of Requesting SOAP Node

The overall flow of the behavior of a requesting SOAP node follows a
state machine description consistent with Section 6.2 of [3].

In order to avoid deadlock during streaming (see Section 6.2.3 of
[3]), the requesting SOAP node MUST be able to process incoming SOAP
response information while the SOAP request is still being
transmitted.

5.5.1.1. Init

In the "Init" state, a BEEP message is formulated according to
Section 3, transmission of the message begins, and then the state
changes to "Requesting".

5.5.1.2. Requesting

In the "Requesting" state, more of the request message is transmitted
and the arrival of the response is awaited. When the beginning of
the response message is received, if it is a BEEP ERR message, then
the state transitions to "Fail"; otherwise, the state transitions to
"Sending+Receiving".

5.5.1.3. Sending+Receiving

In the "Sending+Receiving" state, the transmission of the request
message and receiving of the response message are completed. The
response message is assumed to contain a SOAP envelope serialized
according to the rules for carrying SOAP messages in the media type
given in the Content-Type header field. Once the receipt of the
response is completed, the state transitions to "Success".

5.5.1.4. Success and Fail

"Success" and "Fail" are the terminal states for the state machine.

5.5.2. Behavior of Responding SOAP Node

The overall flow of the behavior of a responding SOAP node follows a
state machine description consistent with Section 6.2 of [3]

5.5.2.1. Init

In the "Init" state, the binding awaits the start of the inbound
request. In this state, it may only generate ERR messages (in
accordance with Section 4.4).

5.5.2.2. Receiving

The binding begins to receive the request message and prepares the
start of the response, in accordance with Section 3. When ready to
transmit the response, the state transitions to "Receiving+Sending".

5.5.2.3. Receiving+Sending

The binding completes the receiving of the request and sending of the
response and then transitions to "Success" state.

5.5.2.4. Success and Fail

"Success" and "Fail" are the terminal states that indicate completion
of the message exchange.

6. URL Schemes

This memo defines two URL schemes, "soap.beep" and "soap.beeps",
which identify the use of SOAP over BEEP over TCP. Note that, at
present, a "generic" URL scheme for SOAP is not defined.

6.1. The soap.beep URL Scheme

the server-based naming authority defined in Section 3.2.2 of [10]
is used for the authority component.

the path component maps to the "resource" component of the boot
message sent during profile initialization (if absent, it defaults
to "/").

The values of both the scheme and authority components are case-
insensitive.

For example, the URL

soap.beep://stockquoteserver.example.com/StockQuote

might result in the example shown in Section 2.1.

6.1.1. Resolving IP/TCP Address Information

The "soap.beep" URL scheme indicates the use of the BEEP profile for
SOAP running over TCP/IP.

If the authority component contains a domain name and a port number,
e.g.,

soap.beep://stockquoteserver.example.com:1026

then the DNS is queried for the A Resource Records corresponding to
the domain name, and the port number is used directly.

If the authority component contains a domain name and no port number,
e.g.,

soap.beep://stockquoteserver.example.com

the Service Record algorithm [11] is used with a service parameter of
"soap-beep" and a protocol parameter of "tcp" to determine the IP/TCP
addressing information. If no appropriate SRV RRs are found (e.g.,
for "_soap-beep._tcp.stockquoteserver.example.com"), then the DNS is
queried for the A RRs corresponding to the domain name and the port
number used is assigned by the IANA for the registration in Section
8.4.

If the authority component contains an IP address, e.g.,

soap.beep://192.0.2.0:1026

then the DNS is not queried, and the IP address is used directly. If
a port number is present, it is used directly; otherwise, the port
number used is assigned by the IANA for the registration in Section
8.4.

While the use of literal IPv6 addresses in URLs is discouraged, if a
literal IPv6 address is used in a "soap.beep" URL, it must conform to
the syntax specified in [12].

6.2. The soap.beeps URL Scheme

The "soap.beeps" URL scheme is identical, in all ways, to the
"soap.beep" URL scheme specified in Section 6.1, with the exception
that prior to starting the BEEP profile for SOAP, the BEEP session
must be tuned for privacy. In particular, note that both URL schemes
use the identical algorithms and parameters for address resolution as
specified in Section 6.1.1 (e.g., the same service name for SRV
lookups, the same port number for TCP, and so on).

There are two ways to perform privacy tuning on a BEEP session,
either

a transport security profile may be successfully started or

a user authentication profile that supports transport security may
be successfully started.

Regardless, upon completion of the negotiation process, a tuning
reset occurs in which both BEEP peers issue a new greeting. Consult
Section 3 of [1] for an example of how a BEEP peer may choose to
issue different greetings based on whether privacy is in use.

7. Registration Templates

7.1. SOAP Profile Feature Registration Template

When a feature for the BEEP profile for SOAP is registered, the
following information is supplied:

Feature Identification: specify a string that identifies this

feature. Unless the feature is registered with the IANA, the
feature's identification must start with "x-".

10. IANA Considerations

Previously, the IANA registered "http://iana.org/beep/soap" for use
with RFC 3288 [16]. This memo requires that the IANA register a
URI-prefix of

http://iana.org/beep/soap/VERSION

to correspond to the family of profiles defined Section 8.1.

The IANA has registered "soap.beep" and "soap.beeps" as URL schemes,
as specified in Section 8.2 and Section 8.3, respectively.

The IANA has also registered "SOAP over BEEP" as a TCP port number,
as specified in Section 8.4.

The IANA now broadens these three registries to support the family of
BEEP profiles defined by this URI prefix.

Finally, the IANA maintains a list of SOAP profile features, cf.
Section 7.1. The IESG is responsible for assigning a designated
expert to review the specification prior to the IANA making the
assignment. Prior to contacting the IESG, developers of SOAP profile
features must use the mailing list beepwg@lists.beepcore.org to
solicit commentary.

This memo differs from RFC 3288 [16] in one substantive way: a URL
prefix is defined to support a family of BEEP profiles corresponding
to different versions of SOAP. Similarly, the IANA registrations in
Section 8.1, Section 8.3, and Section 8.4 are updated to reflect this
broadening.

Support for W3C MTOM/XOP packaging has been added.

A new section was added to discuss the distributed state machine of
the Request-Response MEP.

In non-substantive ways, a small number of typographical errors were
corrected.

Appendix A. SOAP with Attachments (Informative)

To provide compatibility with RFC3288 [16], a BEEP profile for SOAP
MAY allow envelopes to be transmitted as the root part of a
"multipart/related" [18] content, and with subordinate parts
referenced using the rules of Section 3 of [19] (i.e., using either
the "Content-ID:" [20] or "Content-Location:" [21] headers), e.g.,

Consistent with Section 2 of [19], it is strongly recommended that
the multipart contain a "start" parameter, and that the root part
contain a "Content-ID:" header. However, because BEEP provides an
8bit-wide path, a "transformative" Content-Transfer-Encoding (e.g.,
"base64" or "quoted-printable") should not be used. Further note
that MIME [9] requires that the value of the "Content-ID" header be
globally unique.

Full Copyright Statement

This document is subject to the rights, licenses and restrictions
contained in BCP 78, and except as set forth therein, the authors
retain all their rights.

This document and the information contained herein are provided on an
"AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET
ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE
INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

Intellectual Property

The IETF takes no position regarding the validity or scope of any
Intellectual Property Rights or other rights that might be claimed to
pertain to the implementation or use of the technology described in
this document or the extent to which any license under such rights
might or might not be available; nor does it represent that it has
made any independent effort to identify any such rights. Information
on the procedures with respect to rights in RFC documents can be
found in BCP 78 and BCP 79.

Copies of IPR disclosures made to the IETF Secretariat and any
assurances of licenses to be made available, or the result of an
attempt made to obtain a general license or permission for the use of
such proprietary rights by implementers or users of this
specification can be obtained from the IETF on-line IPR repository at
http://www.ietf.org/ipr.

The IETF invites any interested party to bring to its attention any
copyrights, patents or patent applications, or other proprietary
rights that may cover technology that may be required to implement
this standard. Please address the information to the IETF at
ietf-ipr@ietf.org.

Acknowledgement

Funding for the RFC Editor function is provided by the IETF
Administrative Support Activity (IASA).