This JEP specifies a method for sending Common Alerting Protocol (CAP) data over XMPP.
NOTICE: This JEP is currently within Last Call or under consideration by the Jabber Council for advancement to the next stage in the JSF standards process. For further details, visit <http://www.jabber.org/council/queue.php>.
Status: Proposed
Type: Informational
Number: 0127
Version: 0.2
Last Updated: 2004-11-09
JIG: Standards JIG
Approving Body: Jabber Council
Dependencies: XMPP Core, Common Alerting Protocol
Supersedes: None
Superseded By: None
Short Name: None
Email: stpeter@jabber.org
JID: stpeter@jabber.org
Email: Boyd.Fletcher@je.jfcom.mil
JID: bfletcher@jabber.com
This Jabber Enhancement Proposal is copyright 1999 - 2004 by the Jabber Software Foundation (JSF) and is in full conformance with the JSF's Intellectual Property Rights Policy <http://www.jabber.org/jsf/ipr-policy.php>. This material may be distributed only subject to the terms and conditions set forth in the Open Publication License, v1.0 or later (the latest version is presently available at <http://www.opencontent.org/openpub/>).
The preferred venue for discussion of this document is the Standards-JIG discussion list: <http://mail.jabber.org/mailman/listinfo/standards-jig>.
The Extensible Messaging and Presence Protocol (XMPP) is defined in the XMPP Core (RFC 3920) and XMPP IM (RFC 3921) specifications contributed by the Jabber Software Foundation to the Internet Standards Process, which is managed by the Internet Engineering Task Force in accordance with RFC 2026. Any protocols defined in this JEP have been developed outside the Internet Standards Process and are to be understood as extensions to XMPP rather than as an evolution, development, or modification of XMPP itself.
The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.
The Common Alerting Protocol [1] (CAP) is an open format for alerts and notifications, defined by OASIS [2]. CAP was developed to address the call, published in a (U.S.) National Science and Technology Council report, for "a standard method ... to collect and relay instantaneously and automatically all types of hazard warnings and reports". Given that the Extensible Messaging and Presence Protocol (see XMPP Core [3]) provides a near-real-time transport mechanism for structured information, and that CAP is defined as an XML data format, it makes sense to define a way to transport CAP information over XMPP. Such a method is defined herein.
The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 [4].
Because the alerts and notifications structured via CAP require a "push" medium, they SHOULD be sent via the XML <message/> stanza defined in XMPP Core. The message could be sent using either of the following methods:
Both methods are described below.
In the case of direct messages, the message stanza SHOULD have no 'type' attribute, but MAY have any defined type that is appropriate to the communications context (e.g., "groupchat" in a text conference). The <alert/> element SHOULD be the only child element of the message stanza, but other elements MAY be included as necessary (e.g., a <body/> child in the 'jabber:client' namespace providing a natural-language description of the alert). The 'id' attribute of the <message/> stanza MAY be set to the value of the CAP <identifier/> element.
The following example shows Example A.2 from the CAP specification sent as a direct message.
<message from='KSTO@NWS.NOAA.GOV' to='weatherbot@jabber.org' id='KSTO1055887203'> <alert xmlns='http://www.incident.com/cap/1.0'> <identifier>KSTO1055887203</identifier> <sender>KSTO@NWS.NOAA.GOV</sender> <sent>2003-06-17T14:57:00-07:00</sent> <status>Actual</status> <msgType>Alert</msgType> <scope>Public</scope> <info> <category>Met</category> <event>SEVERE THUNDERSTORM</event> <urgency>Severe</urgency> <certainty>Likely</certainty> <eventCode>same=SVR</eventCode> <senderName>NATIONAL WEATHER SERVICE SACRAMENTO</senderName> <headline>SEVERE THUNDERSTORM WARNING</headline> <description> AT 254 PM PDT... NATIONAL WEATHER SERVICE DOPPLER RADAR INDICATED A SEVERE THUNDERSTORM OVER SOUTH CENTRAL ALPINE COUNTY... OR ABOUT 18 MILES SOUTHEAST OF KIRKWOOD... MOVING SOUTHWEST AT 5 MPH. HAIL... INTENSE RAIN AND STRONG DAMAGING WINDS ARE LIKELY WITH THIS STORM </description> <instruction> TAKE COVER IN A SUBSTANTIAL SHELTER UNTIL THE STORM PASSES </instruction> <contact>BARUFFALDI/JUSKIE</contact> <area> <areaDesc> EXTREME NORTH CENTRAL TUOLUMNE COUNTY IN CALIFORNIA, EXTREME NORTHEASTERN CALAVERAS COUNTY IN CALIFORNIA, SOUTHWESTERN ALPINE COUNTY IN CALIFORNIA </areaDesc> <polygon> 38.47,-120.14 38.34,-119.95 38.52,-119.74 38.62,-119.89 38.47,-120.14 </polygon> <geocode>fips6=006109</geocode> <geocode>fips6=006109</geocode> <geocode>fips6=006103</geocode> </area> </info> </alert> </message>
The publish-subscribe protocol defined in JEP-0060 provides a way to send information to a number of subscribers, and to control the list of subscribers.
The following example shows Example A.2 from the CAP specification published to a pubsub node.
<iq type='set' from='KSTO@NWS.NOAA.GOV' to='pubsub.jabber.org' id='someID'> <pubsub xmlns='http://jabber.org/protocol/pubsub'> <publish node='NOAA-ALERTS'> <item id='KSTO1055887203'> <alert xmlns='http://www.incident.com/cap/1.0'> <identifier>KSTO1055887203</identifier> <sender>KSTO@NWS.NOAA.GOV</sender> <sent>2003-06-17T14:57:00-07:00</sent> <status>Actual</status> <msgType>Alert</msgType> <scope>Public</scope> <info> <category>Met</category> <event>SEVERE THUNDERSTORM</event> <urgency>Severe</urgency> <certainty>Likely</certainty> <eventCode>same=SVR</eventCode> <senderName>NATIONAL WEATHER SERVICE SACRAMENTO</senderName> <headline>SEVERE THUNDERSTORM WARNING</headline> <description> AT 254 PM PDT... NATIONAL WEATHER SERVICE DOPPLER RADAR INDICATED A SEVERE THUNDERSTORM OVER SOUTH CENTRAL ALPINE COUNTY... OR ABOUT 18 MILES SOUTHEAST OF KIRKWOOD... MOVING SOUTHWEST AT 5 MPH. HAIL... INTENSE RAIN AND STRONG DAMAGING WINDS ARE LIKELY WITH THIS STORM </description> <instruction> TAKE COVER IN A SUBSTANTIAL SHELTER UNTIL THE STORM PASSES </instruction> <contact>BARUFFALDI/JUSKIE</contact> <area> <areaDesc> EXTREME NORTH CENTRAL TUOLUMNE COUNTY IN CALIFORNIA, EXTREME NORTHEASTERN CALAVERAS COUNTY IN CALIFORNIA, SOUTHWESTERN ALPINE COUNTY IN CALIFORNIA </areaDesc> <polygon> 38.47,-120.14 38.34,-119.95 38.52,-119.74 38.62,-119.89 38.47,-120.14 </polygon> <geocode>fips6=006109</geocode> <geocode>fips6=006109</geocode> <geocode>fips6=006103</geocode> </area> </info> </alert> </item> </publish> </pubsub> </iq>
If the pubsub node is configured to deliver payloads, the information is then sent to all subscribers.
<message from='pubsub.jabber.org' to='weatherbot@jabber.org'> <event xmlns="http://jabber.org/protocol/pubsub#event"> <items node="NOAA-ALERTS"> <alert xmlns='http://www.incident.com/cap/1.0'> <identifier>KSTO1055887203</identifier> <sender>KSTO@NWS.NOAA.GOV</sender> <sent>2003-06-17T14:57:00-07:00</sent> <status>Actual</status> <msgType>Alert</msgType> <scope>Public</scope> <info> <category>Met</category> <event>SEVERE THUNDERSTORM</event> <urgency>Severe</urgency> <certainty>Likely</certainty> <eventCode>same=SVR</eventCode> <senderName>NATIONAL WEATHER SERVICE SACRAMENTO</senderName> <headline>SEVERE THUNDERSTORM WARNING</headline> <description> AT 254 PM PDT... NATIONAL WEATHER SERVICE DOPPLER RADAR INDICATED A SEVERE THUNDERSTORM OVER SOUTH CENTRAL ALPINE COUNTY... OR ABOUT 18 MILES SOUTHEAST OF KIRKWOOD... MOVING SOUTHWEST AT 5 MPH. HAIL... INTENSE RAIN AND STRONG DAMAGING WINDS ARE LIKELY WITH THIS STORM </description> <instruction> TAKE COVER IN A SUBSTANTIAL SHELTER UNTIL THE STORM PASSES </instruction> <contact>BARUFFALDI/JUSKIE</contact> <area> <areaDesc> EXTREME NORTH CENTRAL TUOLUMNE COUNTY IN CALIFORNIA, EXTREME NORTHEASTERN CALAVERAS COUNTY IN CALIFORNIA, SOUTHWESTERN ALPINE COUNTY IN CALIFORNIA </areaDesc> <polygon> 38.47,-120.14 38.34,-119.95 38.52,-119.74 38.62,-119.89 38.47,-120.14 </polygon> <geocode>fips6=006109</geocode> <geocode>fips6=006109</geocode> <geocode>fips6=006103</geocode> </area> </info> </alert> </items> </event> </message> . . .
Security considerations for CAP are defined in Common Alerting Protocol, v. 1.0; security considerations for XMPP are defined in RFC 3920: XMPP Core; security considerations for the XMPP publish-subscribe extension are defined in JEP-0060: Publish Subscribe.
Furthermore, it may be appropriate to include the "Classification", "Distribute", and/or "Store" headers specified in Stanza Headers and Internet Metadata (SHIM) [8] in order to safeguard CAP data.
This JEP requires no interaction with the Internet Assigned Numbers Authority (IANA) [9].
No namespaces or parameters need to be registered with the Jabber Registrar [10] as a result of this JEP.
The CAP information format is defined by an XML schema. The reader is referred to the CAP specification for the relevant schema definition.
1. Common Alerting Protocol, v. 1.0 <http://www.oasis-open.org/committees/documents.php?wg_abbrev=emergency>.
2. OASIS is a not-for-profit, international consortium that drives the development, convergence and adoption of e-business standards. For further information, see <http://www.oasis-open.org/>.
3. RFC 3920: Extensible Messaging and Presence Protocol (XMPP): Core <http://www.ietf.org/rfc/rfc3920.txt>.
4. RFC 2119: Key words for use in RFCs to Indicate Requirement Levels <http://www.ietf.org/rfc/rfc2119.txt>.
5. JEP-0033: Extended Stanza Addressing <http://www.jabber.org/jeps/jep-0033.html>.
6. JEP-0045: Multi-User Chat <http://www.jabber.org/jeps/jep-0045.html>.
7. JEP-0060: Publish-Subscribe <http://www.jabber.org/jeps/jep-0060.html>.
8. JEP-0131: Stanza Headers and Internet Metadata (SHIM) <http://www.jabber.org/jeps/jep-0131.html>.
9. The Internet Assigned Numbers Authority (IANA) is the central coordinator for the assignment of unique parameter values for Internet protocols, such as port numbers and URI schemes. For further information, see <http://www.iana.org/>.
10. The Jabber Registrar maintains a list of reserved Jabber protocol namespaces as well as registries of parameters used in the context of protocols approved by the Jabber Software Foundation. For further information, see <http://www.jabber.org/registrar/>.
END