|
RFC 3340 |
| TOC |
|
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.
Copyright © The Internet Society (2002).
This memo describes Application Exchange (APEX) Core, an extensible, asynchronous message relaying service for application layer programs.
|
RFC 3340 |
| TOC |
1.
Introduction
1.1.
Overview
1.2.
Architecture at a Glance
2.
Service Principles
2.1.
Modes of Operation
2.2.
Naming of Entities
2.2.1.
Comparing Endpoints
3.
Service Provisioning
3.1.
Connection Establishment
3.2.
Authentication
3.3.
Authorization
3.4.
Confidentiality
3.5.
Relaying Integrity
3.6.
Traffic Analysis
4.
The APEX
4.1.
Use of XML and MIME
4.2.
Profile Identification and Initialization
4.3.
Message Syntax
4.4.
Message Semantics
4.4.1.
The Attach Operation
4.4.2.
The Bind Operation
4.4.3.
The Terminate Operation
4.4.4.
The Data Operation
4.5.
APEX Access Policies
4.5.1.
Access Policies in the Endpoint-Relay Mode
4.5.2.
Access Policies in the Relay-Relay Mode
5.
APEX Options
5.1.
The statusRequest Option
6.
APEX Services
6.1.
Use of the APEX Core DTD
6.1.1.
Transaction-Identifiers
6.1.2.
The Reply Element
6.2.
The Report Service
7.
Registration Templates
7.1.
APEX Option Registration Template
7.2.
APEX Service Registration Template
7.3.
APEX Endpoint Application Registration Template
8.
Initial Registrations
8.1.
Registration: The APEX Profile
8.2.
Registration: The System (Well-Known) TCP port number for apex-mesh
8.3.
Registration: The System (Well-Known) TCP port number for apex-edge
8.4.
Registration: The statusRequest Option
8.5.
Registration: The Report Service
9.
DTDs
9.1.
The APEX Core DTD
9.2.
The Report Service DTD
10.
Reply Codes
11.
Security Considerations
12.
References
Appendix A.
Acknowledgements
Appendix B.
IANA Considerations
§
Authors' Addresses
§
Intellectual Property and Copyright Statements
| TOC |
Network applications can be broadly distinguished by five operational characteristics:
For example:
Messaging applications vary considerably in their operational requirements. For example, some messaging applications require assurance of timeliness and reliability, whilst others do not.
These features come at a cost, in terms of both infrastructural and configuration complexity. Accordingly, the underlying service must be extensible to support different requirements in a consistent manner.
This memo defines a core messaging service that supports a range of operational characteristics. The core service supports a variety of tailored services for both user-based and programmatic exchanges.
| TOC |
APEX provides an extensible, asynchronous message relaying service for application layer programs.
APEX, at its core, provides a best-effort datagram service. Each datagram, simply termed "data", is originated and received by APEX "endpoints" -- applications that dynamically attach to the APEX "relaying mesh".
The data transmitted specifies:
Options are used to alter the semantics of the service, which may occur on a per-recipient or per-data basis, and may be processed by either a single or multiple relays.
Additional APEX services are provided on top of the relaying mesh; e.g., access control and presence information.
APEX is specified, in part, as a BEEP (Rose, M., “The Blocks Extensible Exchange Protocol Core,” March 2001.) [1] "profile". Accordingly, many aspects of APEX (e.g., authentication) are provided within the BEEP core. Throughout this memo, the terms "peer", "initiator", "listener", "client", and "server" are used in the context of BEEP. In particular, Section 2.1 of the BEEP core memo discusses the roles that a BEEP peer may perform.
When reading this memo, note that the terms "endpoint" and "relay" are specific to APEX, they do not exist in the context of BEEP.
| TOC |
The APEX stack:
+-------------+ | APEX | an APEX process is either: | process | +-------------+ - an application attached as an APEX | | endpoint; or, | APEX | | | - an APEX relay +-------------+ | | APEX services are realized as applications | BEEP | having a special relationship with the APEX | | relays in their administrative domain +-------------+ | TCP | +-------------+ | ... | +-------------+
The APEX entities:
administrative domain #1 administrative domain #2
+----------------------------+ +----------------------------+
| +------+ | | +------+ |
| | | | | | | |
| | appl | | | | appl | |
| | | | | | | |
| +......+ +------+ | | +------+ +......+ |
| | | | | | | | | | | |
| |end- | |relay | | | |relay | |end- | |
| | point| | | | | | | | point| |
| +------+ +------+ | | +------+ +------+ |
| | | | | | | | | | | |
| | APEX | | APEX | | | | APEX | | APEX | |
| | | | | | | | | | | |
| +------+ +------+ | | +------+ +------+ |
| || || || | | || || || |
| ============= ================ ============= |
+----------------------------+ +----------------------------+
| <---- APEX relaying mesh ----> |
Note: relaying between administrative domains is configured
using SRV RRs. Accordingly, the actual number of
relays between two endpoints is not fixed.
| TOC |
| TOC |
APEX is used in two modes:
- endpoint-relay:
- in which the endpoint is always the BEEP initiator of the service, whilst relays are always the BEEP listeners. In this context, applications attach as endpoints, and then the transmission of data occurs.
- relay-relay:
- in which relays typically, though not necessarily, reside in different administrative domains. In this context, applications bind as relays, and then the transmission of data occurs.
In the endpoint-relay mode, an endpoint (BEEP initiator) may:
A relay (BEEP listener), in addition to servicing requests from a BEEP initiator, may:
In the relay-relay mode, a relay (BEEP listener or initiator) may:
| TOC |
Endpoints are named using the following ABNF (Crocker, D. and P. Overell, “Augmented BNF for Syntax Specifications: ABNF,” November 1997.) [2] syntax:
;; Domain is defined in [3], either a FQDN or a literal
entity = local "@" Domain
local = address [ "/" subaddress ]
address = token
subaddress = token
;; all non-control characters, excluding "/" and "@" delimiters
token = 1*(%x20-2E / %x30-3F / %x41-7E / UTF-8) ;; [4]
Two further conventions are applied when using this syntax:
- the "apex=" convention:
- All endpoint identities having a local-part starting with "apex=" are reserved for use by APEX services registered with the IANA; and,
- the "subaddress" convention:
- If the solidus character ("/", decimal code 47) occurs in the local-part, this identifies a subaddress of an endpoint identity (e.g., "fred/appl=wb@example.com" is a subaddress of the APEX endpoint "fred@example.com").
All subaddresses starting with "appl=" are reserved for use by APEX endpoint applications registered with the IANA.
Relays, although not named, serve of behalf of administrative domains, as identified by a FQDN or a domain-literal, e.g., "example.com" or "[10.0.0.1]".
In APEX, "endpoints" and "relays" are the fundamental entities. APEX is carried over BEEP, which has the "peer" as its fundamental entity. The relationship between BEEP peer entities and APEX endpoint and relay entities are defined by APEX's Access Policies (APEX Access Policies).
| TOC |
Note that since the "local" part of an entity is a string of UTF-8 (Yergeau, F., “UTF-8, a transformation format of Unicode and ISO 10646,” October 1996.) [4] octets, comparison operations on the "local" part use exact matching (i.e., are case-sensitive).
Accordingly, "fred@example.com" and "Fred@example.com" refer to different endpoints. Of course, relays serving the "example.com" administrative domain may choose to treat the two endpoints identically for the purposes of routing and delivery.
Finally, note that if an APEX endpoint is represented using a transmission encoding, then, prior to comparison, the encoding is reversed. For example, if the URL encoding is used, then "apex:fred@example.com" is identical to "apex:f%72ed@example.com".
| TOC |
| TOC |
The SRV algorithm (Gulbrandsen, A., Vixie, P., and L. Esibov, “A DNS RR for specifying the location of services (DNS SRV),” February 2000.) [5] is used to determine the IP/TCP addressing information assigned to the relays for an administrative domain identified by a FQDN:
- service:
- "apex-edge" (for the endpoint-relay mode), or "apex-mesh" (for the relay-relay mode);
- protocol:
- "tcp"; and,
- domain:
- the administrative domain.
If the administrative domain is identified by a domain-literal, then the IP address information is taken directly from the literal and the TCP port number used is assigned by the IANA for the registration in Section 8.2 (Registration: The System (Well-Known) TCP port number for apex-mesh).
| TOC |
Authentication is a matter of provisioning for each BEEP peer (c.f., Section 4.5 (APEX Access Policies)).
An APEX relay might be provisioned to allow a BEEP peer identity to coincide with a given endpoint identity. For example, a relay in the "example.com" administrative domain may be configured to allow a BEEP peer identified as "fred@example.com" to be authorized to attach as the APEX endpoint "fred@example.com".
| TOC |
Authorization is a matter of provisioning for each BEEP peer (c.f., Section 4.5 (APEX Access Policies)).
Typically, a relay requires that its BEEP peer authenticate as a prelude to authorization, but an endpoint usually does not require the same of its BEEP peer.
| TOC |
Confidentiality is a matter of provisioning for each BEEP peer.
Typically, any data considered sensitive by an originating endpoint will have its content encrypted for the intended recipient endpoint(s), rather than relying on hop-by-hop encryption. Similarly, an originating endpoint will sign the content if end-to-end authentication is desired.
| TOC |
Data are relayed according to SRV entries in the DNS. Accordingly, relaying integrity is a function of the DNS and the applications making use of the DNS. Additional assurance is provided if the BEEP initiator requires that the BEEP listener authenticate itself.
| TOC |
Hop-by-hop protection of data transmitted through the relaying mesh (endpoint identities and content) is afforded at the BEEP level through the use of a transport security profile. Other traffic characteristics, e.g., volume and timing of transmissions, are not protected from third-party analysis.
| TOC |
Section 8.1 (Registration: The APEX Profile) contains the BEEP profile registration for APEX.
| TOC |
Each BEEP payload exchanged via APEX consists of an XML document and possibly an arbitrary MIME content.
If only an XML document is sent in the BEEP payload, then the mapping to a BEEP payload is straight-forward, e.g.,
C: MSG 1 2 . 111 39
C: Content-Type: application/beep+xml
C:
C: <terminate transID='1' />
C: END
Otherwise, if an arbitrary MIME content is present, it is indicated by a URI-reference (Berners-Lee, T., Fielding, R., and L. Masinter, “Uniform Resource Identifiers (URI): Generic Syntax,” August 1998.) [6] in the XML control document. The URI-reference may contain an absolute-URI (and possibly a fragment-identifier), or it may be a relative-URI consisting only of a fragment-identifier. Arbitrary MIME content is included in the BEEP payload by using a "multipart/related" (Levinson, E., “The MIME Multipart/Related Content-type,” August 1998.) [7], identified using a "cid" URL (Levinson, E., “Content-ID and Message-ID Uniform Resource Locators,” August 1998.) [8], and the XML control document occurs as the start of the "multipart/related", e.g.,
C: MSG 1 1 . 42 1234
C: Content-Type: multipart/related; boundary="boundary";
C: start="<1@example.com>";
C: type="application/beep+xml"
C:
C: --boundary
C: Content-Type: application/beep+xml
C: Content-ID: <1@example.com>
C:
C: <data content='cid:2@example.com'>
C: <originator identity='fred@example.com' />
C: <recipient identity='barney@example.com' />
C: </data>
C: --boundary
C: Content-Type: image/gif
C: Content-Transfer-Encoding: binary
C: Content-ID: <2@example.com>
C:
C: ...
C: --boundary--
C: END
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 (Freed, N. and N. Borenstein, “Multipurpose Internet Mail Extensions (MIME) Part One: Format of Internet Message Bodies,” November 1996.) [9] requires that the value of the "Content-ID" header be globally unique.
If the arbitrary MIME content is itself an XML document, it may be contained within the control document directly as a "data-content" element, and identified using a URI-reference consisting of only a fragment-identifier, e.g.,
C: MSG 1 1 . 42 295
C: Content-Type: application/beep+xml
C:
C: <data content='#Content'>
C: <originator identity='fred@example.com' />
C: <recipient identity='barney@example.com' />
C: <data-content Name='Content'>
C: <statusResponse transID='86'>
C: <destination identity='barney@example.com'>
C: <reply code='250' />
C: </destination>
C: </statusResponse>
C: </data-content>
C: </data>
C: END
| TOC |
The APEX is identified as
http://iana.org/beep/APEX
in the BEEP "profile" element during channel creation.
No elements are required to be exchanged during channel creation; however, in the endpoint-relay mode, the BEEP initiator will typically include an "attach" element during channel creation, e.g.,
<start number='1'>
<profile uri='http://iana.org/beep/APEX'>
<![CDATA[<attach endpoint='fred@example.com'
transID='1' />]]>
</profile>
</start>
Similarly, in the relay-relay mode, the BEEP initiator will typically include an "bind" element during channel creation, e.g.,
<start number='1'>
<profile uri='http://iana.org/beep/APEX'>
<![CDATA[<bind relay='example.com'
transID='1' />]]>
</profile>
</start>
| TOC |
Section 9.1 (The APEX Core DTD) defines the BEEP payloads that are used in the APEX.
| TOC |
| TOC |
When an application wants to attach to the relaying mesh as a given endpoint, it sends an "attach" element to a relay, e.g.,
+-------+ +-------+
| | -- attach -----> | |
| appl. | | relay |
| | <--------- ok -- | |
+-------+ +-------+
C: <attach endpoint='fred@example.com' transID='1' />
S: <ok />
or
+-------+ +-------+
| | -- attach -----> | |
| | | |
| | <--------- ok -- | |
| appl. | | relay |
| | -- attach -----> | |
| | | |
| | <--------- ok -- | |
+-------+ +-------+
C: <attach endpoint='fred@example.com' transID='1' />
S: <ok />
C: <attach endpoint='wilma@example.com' transID='2' />
S: <ok />
or
+-------+ +-------+
| | -- attach -----> | |
| appl. | | relay |
| | <------ error -- | |
+-------+ +-------+
C: <attach endpoint='fred@example.com' transID='1' />
S: <error code='537'>access denied</error>
The "attach" element has an "endpoint" attribute, a "transID" attribute, and contains zero or more "option" elements:
When a relay receives an "attach" element, it performs these steps:
| TOC |
When an application wants to identify itself as a relay, it sends a "bind" element to another relay, e.g.,
+-------+ +-------+
| | -- bind -------> | |
| relay | | relay |
| #1 | <--------- ok -- | #2 |
+-------+ +-------+
C: <bind relay='example.com' transID='1' />
S: <ok />
or
+-------+ +-------+
| | -- bind -------> | |
| | | |
| | <--------- ok -- | |
| relay | | relay |
| #1 | -- bind -------> | #2 |
| | | |
| | <--------- ok -- | |
+-------+ +-------+
C: <bind relay='example.com' transID='1' />
S: <ok />
C: <bind relay='rubble.com' transID='2' />
S: <ok />
or
+-------+ +-------+
| | -- bind -------> | |
| relay | | relay |
| #1 | <------ error -- | #2 |
+-------+ +-------+
C: <bind relay='example.com' transID='1' />
S: <error code='537'>access denied</error>
The "bind" element has a "relay" attribute, a "transID" attribute, and contains zero or more "option" elements:
When a relay receives an "bind" element, it performs these steps:
| TOC |
When an application or relay wants to release an attachment or binding, it sends a "terminate" element, e.g.,
+-------+ +-------+
| | -- terminate --> | |
| appl. | | relay |
| | <--------- ok -- | |
+-------+ +-------+
C: <terminate transID='1' />
S: <ok />
or
+-------+ +-------+
| | -- terminate --> | |
| appl. | | relay |
| | <------ error -- | |
+-------+ +-------+
C: <terminate transID='13' />
S: <error code='550'>unknown transaction-identifier</error>
or
+-------+ +-------+
| | <-- terminate -- | |
| appl. | | relay |
| | -- ok ---------> | |
+-------+ +-------+
C: <terminate transID='1' />
S: <ok />
The "terminate" element has a "transID" attribute, an optional "code" attribute, an optional "xml:lang" attribute, and may contain arbitrary textual content:
When an application or relay receives a "terminate" element, it performs these steps:
| TOC |
When an application or relay wants to transmit data over the relaying mesh, it sends a "data" element, e.g.,
+-------+ +-------+
| | -- data -------> | |
| appl. | | relay |
| #1 | <--------- ok -- | |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
</data>
S: <ok />
or
+-------+ +-------+
| | -- data -------> | |
| appl. | | relay |
| #1 | <------ error -- | |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
</data>
S: <error code='537'>access denied</error>
or
+-------+ +-------+
| | -- data -------> | |
| relay | | appl. |
| | <--------- ok -- | #2 |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
</data>
S: <ok />
The "data" element has a "content" attribute, and contains an "originator" element, one or more "recipient" elements, zero or more "option" elements, and, optionally, a "data-content" element:
The "originator" element has an "identity" attribute, and contains zero or more option elements:
Each "recipient" element has an "identity" attribute, and contains zero or more option elements:
| TOC |
When a relay receives a "data" element, it performs these steps:
Providing that these semantics are preserved, a relay may choose to optimize its behavior by grouping multiple recipients in a single "data" element that is subsequently transmitted.
Finally, note that a relay receiving a "data" element from an application may be configured to add administrative-specific options. Regardless, all relays are expressly forbidden from modifying the content of the "data" element at any time.
| TOC |
When an application receives a "data" element, it performs these steps:
| TOC |
Access to APEX is provided by the juxtaposition of:
Each of these activities occurs according to the policies of the relevant administrative domain:
| TOC |
| TOC |
| TOC |
APEX, at its core, provides a best-effort datagram service. Options are used to alter the semantics of the core service.
The semantics of the APEX "option" element are context-specific. Accordingly, the specification of an APEX option must define:
An option registration template (APEX Option Registration Template) organizes this information.
An "option" element is contained within either a "data", "originator", "recipient", or an "attach" element, all of which are termed the "containing" element. The "option" element has several attributes and contains arbitrary content:
Note that if the containing element is an "attach", then the values of the "targetHop" and "transID" attributes are ignored.
The value of the "internal" attribute is the IANA-registered name for the option. If the "internal" attribute is not present, then the value of the "external" attribute is a URI or URI with a fragment-identifier. Note that a relative-URI value is not allowed.
The "targetHop" attribute specifies which relay(s) should process the option:
- this:
- the option applies to this relay, and must be removed prior to transmitting the containing element.
- final:
- the option applies to this relay, only if the relay will transmit the containing element directly to the recipient.
- all:
- the option applies to this relay and is retained for the next.
Note that a final relay does not remove any options as it transmits the containing element directly to the recipient.
The "mustUnderstand" attribute specifies whether the relay may ignore the option if it is unrecognized, and is consulted only if the "targetHop" attribute indicates that the option applies to that relay. If the option applies, and if the value of the "mustUnderstand" attribute is "true", and if the relay does not "understand" the option, then an error in processing has occurred.
| TOC |
Section 8.4 (Registration: The statusRequest Option) contains the APEX option registration for the "statusRequest" option.
If this option is present, then each applicable relay sends a "statusResponse" message to the originator. This is done by issuing a data operation whose originator is the report service associated with the issuing relay, whose recipient is the endpoint address of the "statusRequest" originator, and whose content is a "statusResponse" element.
A "statusRequest" option MUST NOT be present in any data operation containing a "statusResponse" element. In general, applications should be careful to avoid potential looping behaviors if an option is received in error.
Consider these examples:
+-------+ +-------+
| | -- data -------> | |
| appl. | | relay |
| #1 | <--------- ok -- | |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
<option internal='statusRequest' targetHop='final'
mustUnderstand='true' transID='86' />
</data>
S: <ok />
+-------+ +-------+
| | -- data -------> | |
| relay | | appl. |
| | <--------- ok -- | #2 |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
<option internal='statusRequest' targetHop='final'
mustUnderstand='true' transID='86' />
</data>
S: <ok />
+-------+ +-------+
| | <------- data -- | |
| appl. | | relay |
| #1 | -- ok ---------> | |
+-------+ +-------+
C: <data content='#Content'>
<originator identity='apex=report@example.com' />
<recipient identity='fred@example.com' />
<data-content Name='Content'>
<statusResponse transID='86'>
<destination identity='barney@example.com'>
<reply code='250' />
</destination>
</statusResponse>
</data-content>
</data>
S: <ok />
or
+-------+ +-------+
| | -- data -------> | |
| appl. | | relay |
| #1 | <--------- ok -- | |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
<option internal='statusRequest' targetHop='final'
mustUnderstand='true' transID='86' />
</data>
S: <ok />
+-------+ +-------+
| | <------- data -- | |
| appl. | | relay |
| #1 | -- ok ---------> | |
+-------+ +-------+
C: <data content='#Content'>
<originator identity='apex=report@example.com' />
<recipient identity='fred@example.com' />
<data-content Name='Content'>
<statusResponse transID='86'>
<destination identity='barney@example.com'>
<reply code='550'>unknown endpoint
identity</reply>
</destination>
</statusResponse>
</data-content>
</data>
S: <ok />
or
+-------+ +-------+
| | -- data -------> | |
| appl. | | relay |
| #1 | <--------- ok -- | #1 |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@rubble.com' />
<option internal='statusRequest' targetHop='final'
mustUnderstand='true' transID='86' />
</data>
S: <ok />
+-------+ +-------+
| | -- data -------> | |
| relay | | relay |
| #1 | <--------- ok -- | #2 |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@rubble.com' />
<option internal='statusRequest' targetHop='final'
mustUnderstand='true' transID='86' />
</data>
S: <ok />
+-------+ +-------+
| | -- data -------> | |
| relay | | appl. |
| #2 | <--------- ok -- | #2 |
+-------+ +-------+
C: <data content='cid:1@example.com'>
<originator identity='fred@example.com' />
<recipient identity='barney@example.com' />
<option internal='statusRequest' targetHop='final'
mustUnderstand='true' transID='86' />
</data>
S: <ok />
+-------+ +-------+
| | <------- data -- | |
| relay | | relay |
| #1 | -- ok ---------> | #2 |
+-------+ +-------+
C: <data content='#Content'>
<originator identity='apex=report@rubble.com' />
<recipient identity='fred@example.com' />
<data-content Name='Content'>
<statusResponse transID='86'>
<destination identity='barney@rubble.com'>
<reply code='250' />
</destination>
</statusResponse>
</data-content>
</data>
S: <ok />
+-------+ +-------+
| | <------- data -- | |
| appl. | | relay |
| #1 | -- ok ---------> | #1 |
+-------+ +-------+
C: <data content='#Content'>
<originator identity='apex=report@rubble.com' />
<recipient identity='fred@example.com' />
<data-content Name='Content'>
<statusResponse transID='86'>
<destination identity='barney@rubble.com'>
<reply code='250' />
</destination>
</statusResponse>
</data-content>
</data>
S: <ok />
Note that a trace of a data's passage through the relaying mesh can be achieved by setting the "targetHop" attribute to "all".
| TOC |
APEX, at its core, provides a best-effort datagram service. Within an administrative domain, all relays must be able to handle messages for any endpoint within that administrative domain. APEX services are logically defined as endpoints but, given their ubiquitous semantics, they do not necessarily need to be associated with a single physical endpoint. As such, they may be provisioned co-resident with each relay within an administrative domain, even though they are logically provided on top of the relaying mesh, i.e.,
+----------+ +----------+ +----------+ +---------+
| APEX | | APEX | | APEX | | |
| access | | presence | | report | | ... |
| service | | service | | service | | |
+----------+ +----------+ +----------+ +---------+
| | | |
| | | |
+----------------------------------------------------------------+
| |
| APEX core |
| |
+----------------------------------------------------------------+
That is, applications communicate with an APEX service by exchanging data with a "well-known endpoint" (WKE).
For example, APEX applications communicate with the report service by exchanging data with the well-known endpoint "apex=report" in the corresponding administrative domain, e.g., "apex=report@example.com" is the endpoint associated with the report service in the "example.com" administrative domain.
The specification of an APEX service must define:
A service registration template (APEX Service Registration Template) organizes this information.
Finally, note that within a single administrative domain, the relaying mesh makes use of the APEX access service in order to determine if an originator is allowed to transmit data to a recipient (c.f., Step 5.3 of Section 4.4.4.1 (Relay Processing of Data)).
| TOC |
The specification of an APEX service may use definitions found in the APEX core DTD (The APEX Core DTD). For example, the reply operation (The Reply Element) is defined to provide a common format for responses.
| TOC |
In using APEX's transaction-identifiers, note the following:
To minimize the likelihood of ambiguities with long-lived transaction-identifiers, the values of transaction-identifiers generated by applications should appear to be unpredictable.
| TOC |
Many APEX services make use of a reply operation. Although each service defines the circumstances in which a "reply" element is sent, the syntax of the "reply" element is defined in Section 9.1 (The APEX Core DTD).
The "reply" element has a "code" attribute, a "transID" attribute, an optional "xml:lang" attribute, and may contain arbitrary textual content:
| TOC |
Section 8.5 (Registration: The Report Service) contains the APEX service registration for the report service:
If a relay processes a "statusRequest" option (The statusRequest Option), then it sends data to the originator containing a "statusResponse" element (The Report Service DTD).
The "statusResponse" element has a "transID" attribute and contains one or more "destination" elements:
| TOC |
| TOC |
When an APEX option is registered, the following information is supplied:
- Option Identification:
- specify the NMTOKEN or the URI that authoritatively identifies this option.
- Present in:
- specify the APEX elements in which the option may appear.
- Contains:
- specify the XML content that is contained within the "option" element.
- Processing Rules:
- specify the processing rules associated with the option.
- Contact Information:
- specify the postal and electronic contact information for the author of the profile.
| TOC |
When an APEX service is registered, the following information is supplied:
- Well-Known Endpoint:
- specify the local-part of an endpoint identity, starting with "apex=".
- Syntax of Messages Exchanged:
- specify the elements exchanged with the service.
- Sequence of Messages Exchanged:
- specify the order in which data is exchanged with the service.
- Access Control Tokens:
- specify the token(s) used to control access to the service (c.f., [10] (Rose, M., Klyne, G., and D. Crocker, “The Application Exchange (APEX) Access Service,” July 2002.)).
- Contact Information:
- specify the postal and electronic contact information for the author of the profile.
Note that the endpoints "apex=all" and "apex=core" may not be assigned.
| TOC |
When an APEX endpoint application is registered, the following information is supplied:
- Endpoint Application:
- specify the subaddress used for an endpoint application, starting with "appl=".
- Application Definition:
- specify the syntax and semantics of the endpoint application identified by this registration.
- Contact Information:
- specify the postal and electronic contact information for the author of the profile.
| TOC |
| TOC |
- Profile Identification:
- http://iana.org/beep/APEX
- Messages exchanged during Channel Creation:
- "attach", "bind"
- Messages starting one-to-one exchanges:
- "attach", "bind", "terminate", or "data"
- Messages in positive replies:
- "ok"
- Messages in negative replies:
- "error"
- Messages in one-to-many exchanges:
- none
- Message Syntax:
- c.f., Section 9.1 (The APEX Core DTD)
- Message Semantics:
- c.f., Section 4.4 (Message Semantics)
- Contact Information:
- c.f., the "Authors' Addresses" section of this memo
| TOC |
- Protocol Number:
- TCP
- Message Formats, Types, Opcodes, and Sequences:
- c.f., Section 9.1 (The APEX Core DTD)
- Functions:
- c.f., Section 4.4 (Message Semantics)
- Use of Broadcast/Multicast:
- none
- Proposed Name:
- APEX relay-relay service
- Short name:
- apex-mesh
- Contact Information:
- c.f., the "Authors' Addresses" section of this memo
| TOC |
- Protocol Number:
- TCP
- Message Formats, Types, Opcodes, and Sequences:
- c.f., Section 9.1 (The APEX Core DTD)
- Functions:
- c.f., Section 4.4 (Message Semantics)
- Use of Broadcast/Multicast:
- none
- Proposed Name:
- APEX endpoint-relay service
- Short name:
- apex-edge
- Contact Information:
- c.f., the "Authors' Addresses" section of this memo
| TOC |
- Option Identification:
- statusRequest
- Present in:
- APEX's "data" and "recipient" elements
- Contains:
- nothing
- Processing Rules:
- c.f., Section 5.1 (The statusRequest Option)
- Contact Information:
- c.f., the "Authors' Addresses" section of this memo
| TOC |
- Well-Known Endpoint:
- apex=report
- Syntax of Messages Exchanged:
- c.f., Section 9.2 (The Report Service DTD)
- Sequence of Messages Exchanged:
- c.f., Section 6.2 (The Report Service)
- Access Control Tokens:
- none
- Contact Information:
- c.f., the "Authors' Addresses" section of this memo
| TOC |
| TOC |
<!--
DTD for the APEX core, as of 2001-07-09
Refer to this DTD as:
<!ENTITY % APEXCORE PUBLIC "-//IETF//DTD APEX CORE//EN" "">
%APEXCORE;
-->
<!ENTITY % BEEP PUBLIC "-//IETF//DTD BEEP//EN" "">
%BEEP;
<!--
DTD data types:
entity syntax/reference example
====== ================ =======
APEX endpoint
ENDPOINT entity, fred@example.com
c.f., Section 2.2
domain, either a FQDN or a literal
DOMAIN c.f., [RFC-2821] example.com or [10.0.0.1]
seconds
SECONDS 0..2147483647 600
timestamp
TIMESTAMP c.f., [12] 2000-05-15T13:02:00-08:00
unique-identifier
UNIQID 1..2147483647 42
unique-identifier OR zero
UNIZID 0..2147483647 0
-->
<!ENTITY % ENDPOINT "CDATA">
<!ENTITY % DOMAIN "CDATA">
<!ENTITY % SECONDS "CDATA">
<!ENTITY % TIMESTAMP "CDATA">
<!ENTITY % UNIQID "CDATA">
<!ENTITY % UNIZID "CDATA">
<!--
APEX messages, exchanged as application/beep+xml
role MSG RPY ERR
====== === === ===
I attach ok error
I or L bind ok error
I or L terminate ok error
I or L data ok error
-->
<!ELEMENT attach (option*)>
<!ATTLIST attach
endpoint %ENDPOINT; #REQUIRED
transID %UNIQID; #REQUIRED>
<!ELEMENT bind (option*)>
<!ATTLIST bind
relay %DOMAIN; #REQUIRED
transID %UNIQID; #REQUIRED>
<!ELEMENT terminate (#PCDATA)>
<!ATTLIST terminate
code %XYZ; "250"
xml:lang %LANG; #IMPLIED
transID %UNIZID; "0">
<!ELEMENT data (originator,recipient+,option*,data-content?)>
<!ATTLIST data
content %URI; #REQUIRED>
<!ELEMENT originator (option*)>
<!ATTLIST originator
identity %ENDPOINT; #REQUIRED>
<!ELEMENT recipient (option*)>
<!ATTLIST recipient
identity %ENDPOINT; #REQUIRED>
<!ELEMENT data-content
ANY>
<!ATTLIST Name ID #REQUIRED>
<!ELEMENT ok EMPTY>
<!ELEMENT reply (#PCDATA)>
<!ATTLIST reply
code %XYZ; #REQUIRED
transID %UNIQID; #REQUIRED
xml:lang %LANG; #IMPLIED>
<!-- either the "internal" or the "external" attribute is present in
an option -->
<!ELEMENT option ANY>
<!ATTLIST option
internal NMTOKEN ""
external %URI; ""
targetHop (this|final|all) "final"
mustUnderstand
(true|false) "false"
transID %UNIQID; #REQUIRED
localize %LOCS; "i-default">
| TOC |
<!--
DTD for the APEX report service, as of 2000-12-12
Refer to this DTD as:
<!ENTITY % APEXREPORT PUBLIC "-//Blocks//DTD APEX REPORT//EN" "">
%APEXREPORT;
-->
<!ENTITY % APEXCORE PUBLIC "-//Blocks//DTD APEX CORE//EN" "">
%APEXCORE;
<!--
Synopsis of the APEX report service
service WKE: apex=report
message exchanges:
service initiates consumer replies
================= ================
statusResponse (nothing)
access control tokens: none
-->
<!ELEMENT statusResponse
(destination+)>
<!ATTLIST statusResponse
transID %UNIQID; #REQUIRED>
<!ELEMENT destination (reply)>
<!ATTLIST destination
identity %ENDPOINT; #REQUIRED>
| TOC |
code meaning ==== ======= 250 transaction successful 421 service not available 450 requested action not taken 451 requested action aborted 454 temporary authentication failure 500 general syntax error (e.g., poorly-formed XML) 501 syntax error in parameters (e.g., non-valid XML) 504 parameter not implemented 530 authentication required 534 authentication mechanism insufficient 535 authentication failure 537 action not authorized for user 538 authentication mechanism requires encryption 550 requested action not taken 553 parameter invalid 554 transaction failed (e.g., policy violation) 555 transaction already in progress
| TOC |
Consult Section 3 (Service Provisioning) and Section 4.5 (APEX Access Policies) for a discussion of security issues, e.g., relaying integrity.
Although service provisioning is a policy matter, at a minimum, all APEX implementations must provide the following tuning profiles:
- for authentication:
- http://iana.org/beep/SASL/DIGEST-MD5
- for confidentiality:
- http://iana.org/beep/TLS (using the TLS_RSA_WITH_3DES_EDE_CBC_SHA cipher)
- for both:
- http://iana.org/beep/TLS (using the TLS_RSA_WITH_3DES_EDE_CBC_SHA cipher supporting client-side certificates)
Further, APEX endpoint implementations may choose to offer MIME-based security services providing message integrity and confidentiality, such as OpenPGP (Elkins, M., Del Torto, D., Levien, R., and T. Roessler, “MIME Security with OpenPGP,” August 2001.) [13] or S/MIME (Ramsdell, B., “S/MIME Version 3 Message Specification,” June 1999.) [14].
Regardless, since APEX is a profile of the BEEP, consult [1] (Rose, M., “The Blocks Extensible Exchange Protocol Core,” March 2001.)'s Section 9 for a discussion of BEEP-specific security issues.
Finally, the statusRequest option (The statusRequest Option) may be used to expose private network topology. Accordingly, an administrator may wish to choose to disable this option except at the ingress/egress points for its administrative domain.
| TOC |
| TOC |
The authors gratefully acknowledge the contributions of: Jeffrey Altman, Harald Alvestrand, Eric Dixon, Ronan Klyne, Darren New, Chris Newman, Scott Pead, and Bob Wyman.
| TOC |
The IANA has registered "APEX" as a standards-track BEEP profile, as specified in Section 8.1 (Registration: The APEX Profile).
The IANA has registered "apex-mesh" as a TCP port number, as specified in Section 8.2 (Registration: The System (Well-Known) TCP port number for apex-mesh).
The IANA has registered "apex-edge" as a TCP port number, as specified in Section 8.3 (Registration: The System (Well-Known) TCP port number for apex-edge).
The IANA maintains a list of:
For each list, the IESG is responsible for assigning a designated expert to review the specification prior to the IANA making the assignment. As a courtesy to developers of non-standards track APEX options and services, the mailing list apexwg@lists.beepcore.org may be used to solicit commentary.
The IANA makes the registrations specified in Section 8.4 (Registration: The statusRequest Option) and Section 8.5 (Registration: The Report Service).
| TOC |
| Marshall T. Rose | |
| Dover Beach Consulting, Inc. | |
| POB 255268 | |
| Sacramento, CA 95865-5268 | |
| US | |
| Phone: | +1 916 483 8878 |
| Email: | mrose@dbc.mtview.ca.us |
| Graham Klyne | |
| Clearswift Corporation | |
| 1310 Waterside | |
| Arlington Business Park | |
| Theale, Reading RG7 4SA | |
| UK | |
| Phone: | +44 11 8903 8903 |
| Email: | Graham.Klyne@MIMEsweeper.com |
| David H. Crocker | |
| Brandenburg InternetWorking | |
| 675 Spruce Drive | |
| Sunnyvale, CA 94086 | |
| US | |
| Phone: | +1 408 246 8253 |
| Email: | dcrocker@brandenburg.com |
| URI: | http://www.brandenburg.com/ |
| TOC |
Copyright © The Internet Society (2002).
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.
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.
Funding for the RFC Editor function is provided by the IETF Administrative Support Activity (IASA).