Internet DRAFT - draft-tschofenig-core-senml-lbn
draft-tschofenig-core-senml-lbn
CORE H. Tschofenig
Internet-Draft Arm Ltd.
Updates: 8428 (if approved) June 18, 2019
Intended status: Standards Track
Expires: December 20, 2019
Introducing the Local Base Name in SenML
draft-tschofenig-core-senml-lbn-00
Abstract
The Sensor Measurement Lists (SenML) specification defines a format
for representing simple sensor measurements and device parameters.
This specification defines a new label to relax the requirement for
global identification of every measurement.
Status of This Memo
This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress."
This Internet-Draft will expire on December 20, 2019.
Copyright Notice
Copyright (c) 2019 IETF Trust and the persons identified as the
document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License.
Tschofenig Expires December 20, 2019 [Page 1]
Internet-Draft SenML Local Base Name June 2019
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 4
3. Local Base Name SenML Structure and Semantics . . . . . . . . 4
4. CDDL . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
5. Security Considerations . . . . . . . . . . . . . . . . . . . 4
6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 4
7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 5
8. References . . . . . . . . . . . . . . . . . . . . . . . . . 5
8.1. Normative References . . . . . . . . . . . . . . . . . . 5
8.2. Informative References . . . . . . . . . . . . . . . . . 5
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 6
1. Introduction
The Sensor Measurement Lists (SenML) specification, see RFC 8428
[RFC8428], defines a format for representing simple sensor
measurements and device parameters.
Ideally, sensor readings used in the Internet of Things environment
should be as small as possible. For this reason the specification
also defines an encoding of these sensor measurements and device
parameters in CBOR (on top of other serialization formats).
A design decision in SenML was, however, that each measurement
transmitted over the network is self-contained and contains
information that uniquely identifies and differentiates the sensor
from all others - not only locally on the device but globally.
This is accomplished by the combination of two fields, namely the
'Name' and the 'Base Name' values. The specification requires the
concatenation of the Name and the Base Name values to yield the name
of the sensor and recommends that the concatenated names be
represented as URIs or URNs.
Figure 1 is an example taken from RFC 8428.
[
{"bn":"urn:dev:ow:10e2073a01080063:","n":"temp","u":"Cel","v":23.1},
{"n":"label","vs":"Machine Room"},
{"n":"open","vb":false},
{"n":"nfc-reader","vd":"aGkgCg"}
]
Figure 1: SenML Example Measurement with Base Name value
Tschofenig Expires December 20, 2019 [Page 2]
Internet-Draft SenML Local Base Name June 2019
The global identification of every measurement as it is traveling
through the network and through different systems has its use case
and allows easy identification of the source and enables correlation.
Unfortunately, it also has drawbacks:
o The unique identification of the sensor adds a substantial
overhead, particularly when the sensor identification is verbose.
Deployed systems, for example, make use of RFC 4122 [RFC4122] Type
5 Universally Unique IDentifier (UUIDs).
o The global identification of every measurements is often
unnecessary when the SenML is used as a mechanism to represent
data for device-to-clould communication or cloud-to-gateway
communication where data is subsequently processed, aggregated or
otherwise modified. In such systems, the identification of the
sensor and the device has its origin in the security context
rather than in the SenML contained measurment. LwM2M [LWM2M] is
an example of such an architecture.
o Finally, there are privacy implications of globally identifying
each measurements and some deployments may prefer better privacy
protection over ease of correlation.
This specification therefore updates RFC 8428 and defines a new Local
Base Name value (lbn) that can be used instead of the Base Name value
defined in RFC 8428.
Figure 2 shows an example based on LwM2M use of SenML.
[
{"lbn":"/3303/", "n":"0/5700/", "v":25.2},
{"n":"/1/5700/", "v":5}
]
Figure 2: SenML Example Measurement with Local Base Name value
Note: In the LwM2M data model objects, object instances, and
resources are encoded as numerical values. The value of '3303'
refers to the Temperature object, '0' and '1' to the two instances of
the resource '5700' (Sensor Value). Hence, this measurement
indicates that the two temperator sensors expose their sensor
readings.
Tschofenig Expires December 20, 2019 [Page 3]
Internet-Draft SenML Local Base Name June 2019
2. Terminology
The key words "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 BCP
14 [RFC2119] [RFC8174] when, and only when, they appear in all
capitals, as shown here.
3. Local Base Name SenML Structure and Semantics
This specification defines one new lable, the Local Base Name value,
which is used instead of the Base Name value. For practical purposes
the Local Base Name / Name concatination does not need to be a URN or
a URI because existing data models used in the IoT space do not all
make use of URIs/URNs.
+-------------------+-------+------------+------------+------------+
| Name | Label | CBOR Label | JSON Type | XML Type |
+-------------------+-------+------------+------------+------------+
| Local Base Name | lbn | 8 | String | string |
+-------------------+-------+------------+------------+------------+
Figure 3: Local Base Name SenML Label
4. CDDL
This document defines a new value to be added to the CDDL defined in
Section 11 of RFC 8428.
The new key-value-pair is
lbn => tstr ; Local Base Name
5. Security Considerations
This document inherits the security properties of RFC 8428 but
improves its privacy features by removing the unique identification
of the sensor when the Local Base Name value is used instead of the
Name / Base Name combination.
6. IANA Considerations
IANA is asked to register the following new entry in the SenML Labels
Registry.
Tschofenig Expires December 20, 2019 [Page 4]
Internet-Draft SenML Local Base Name June 2019
+-----------------+-------+----+-----------+----------+----+--------------+
| Name | Label | CL | JSON Type | XML Type | EI | Reference |
+-----------------+-------+----+-----------+----------+----+--------------+
| Local Base Name | lbn | 8 | String | string | a |[[This RFC]] |
+-----------------+-------+----+-----------+----------+----+--------------+
Note that CL = CBOR Label and EI = EXI ID.
7. Acknowledgements
The author would like to thank the OMA Device Management and Service
Enablement working group for their discussion and their input. In
particular, I would to thank Ari Keranen, David Navarro, Mojan
Mohajer and Alan Soloway.
8. References
8.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, March 1997.
[RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
May 2017, <https://www.rfc-editor.org/info/rfc8174>.
[RFC8428] Jennings, C., Shelby, Z., Arkko, J., Keranen, A., and C.
Bormann, "Sensor Measurement Lists (SenML)", RFC 8428, DOI
10.17487/RFC8428, August 2018, <https://www.rfc-
editor.org/info/rfc8428>.
8.2. Informative References
[LWM2M] Open Mobile Alliance, "Lightweight Machine to Machine
Technical Specification Version 1.0", February 2017,
<http://www.openmobilealliance.org/release/LightweightM2M/
V1_0-20170208-A/
OMA-TS-LightweightM2M-V1_0-20170208-A.pdf>.
[RFC4122] Leach, P., Mealling, M., and R. Salz, "A Universally
Unique IDentifier (UUID) URN Namespace", RFC 4122, DOI
10.17487/RFC4122, July 2005, <https://www.rfc-
editor.org/info/rfc4122>.
Tschofenig Expires December 20, 2019 [Page 5]
Internet-Draft SenML Local Base Name June 2019
Author's Address
Hannes Tschofenig
Arm Ltd.
110 Fulbourn Rd
Cambridge CB1 9NJ
UK
Email: Hannes.tschofenig@arm.com
URI: http://www.tschofenig.priv.at
Tschofenig Expires December 20, 2019 [Page 6]