Two of the most successful application-layer protocols for
small devices are Message Queuing Telemetry Transport
(MQTT)257 and the Constrained Application Protocol
(CoAP)258. Both MQTT and CoAP:
– are open standards
– are better suited to constrained environments than HTTP
– provide mechanisms for asynchronous communication
– run on existing protocols such as TCP/UDP over IP.
MQTT is a publish/subscribe messaging protocol designed
for lightweight device communication, originally developed
by IBM and now an open standard. It features a client/
server model, where every device is a client and connects
to a server, known as a broker, over TCP. Every message is a
discrete chunk of data published to an address, known as a
topic. Clients may subscribe to multiple topics. Every client
subscribed to a topic receives every message published to
the topic. Connections may be encrypted using TLS for
security 259.
CoAP is defined by the IETF’s Constrained RESTful
Environments (CoRE) working group260 for applications that
deal with the manipulation of simple resources on
constrained networks. This includes applications to monitor
simple sensors (e.g. temperature sensors, light switches,
and power meters), to control actuators (e.g. light switches,
heating controllers, and door locks), and to manage
devices. The general architecture consists of devices on
the constrained network that are responsible for one or
more resources that may represent sensors, actuators,
combinations of values, and/or other information.
76
257 http://mqtt.org/
258 http://coap.technology/
259 MQTT Client Authentication using TLS, IBM Knowledge Center https://www.ibm.
com/support/knowledgecenter/en/SSFKSJ_9.0.0/com.ibm.mq.adm.doc/
q021330_.htm
Devices can
– send messages to change and query resources on other
devices.
– send notifications about changed resource values to
other devices that have expressed their interest to
receive notification about changes.
– publish or be queried about its resources.
CoAP is designed for use between devices on the same
constrained network, between devices and general nodes
on the Internet, and between devices on different
constrained (but connected) networks.
Another RESTful approach to IoT is found in the so-called
Web of Things (WoT), which is an application layer that
enables access and control over IoT resources and
applications using common web technologies (such as
HTML 5.0, JavaScript, Ajax, PHP, Ruby on Rails etc.). This
approach can enable both developers and vendors to
benefit from the popularity and maturity of web
technologies. While the W3C has begun standardisation
efforts for WoT261, we do not yet find mainstream adoption
of web technologies in the IoT space.
Datagram Transport Layer Security (DTLS)262 provides
security for datagram-based application protocols such as
CoAP by allowing them to communicate in a way that is
designed (RFC 4347263, RFC 6347264) to prevent
eavesdropping, tampering, or message forgery. The DTLS
protocol is based on the stream-oriented Transport Layer
Security (TLS) protocol and is intended to provide similar
security guarantees. The DTLS protocol datagram
preserves the semantics of the underlying transport
260 https://datatracker.ietf.org/wg/core/documents/261
https://www.w3.org/WoT/,
262 https://tools.ietf.org/id/draft-ietf-tls-dtls13-01.html
263 https://tools.ietf.org/html/rfc4347
264 https://tools.ietf.org/html/rfc6347
Select target paragraph3
Connect to a paragraph
Connect to an entity
Disable highlights
Add to table of contents