SACM Working Group H. Birkholz Internet-Draft Fraunhofer SIT Intended status: Standards Track N. Cam-Winget Expires: July 22, 2018 Cisco Systems January 18, 2018 YANG subscribed notifications via SACM Statements draft-birkholz-sacm-yang-content-01 Abstract This document summarizes a subset of the emerging generic SACM Data Model for inter-component distribution of SACM Content in and between SACM Domains. The subset defined in this document is covering every information element that can be acquired using YANG based protocols, i.e. NETCONF, RESTCONF, COMI or derived mechanisms that transfer YANG modeled data, such as MUD. As subscriptions to data origins in a SACM domain are one of the architectural corner-stones of the SACM architecture, this document recommends the use of YANG Push, YANG subscribed Notifications and corresponding Notification Headers and Bundles. Analogously, a mapping of Notification Header content to SACM Metadata is provided in this document. 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 https://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 July 22, 2018. Copyright Notice Copyright (c) 2018 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 (https://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. Birkholz & Cam-Winget Expires July 22, 2018 [Page 1] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 (https://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. Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 2. Requirements notation . . . . . . . . . . . . . . . . . . . . 3 3. Brokering of YANG Push Telemetry via SACM Statements . . . . 3 4. Encapsulation of YANG notifications in SACM content-elements 4 4.1. Enumeration definition for content-type . . . . . . . . . 4 4.2. Element definition for content-metadata . . . . . . . . . 5 4.3. Definition of the yang-output-metadata element included in content-metadata . . . . . . . . . . . . . . . . . . . 5 5. Mapping of YANG Bundled Notifications to SACM Metadata . . . 7 6. SACM Component Composition . . . . . . . . . . . . . . . . . 8 7. IANA considerations . . . . . . . . . . . . . . . . . . . . . 8 8. Security Considerations . . . . . . . . . . . . . . . . . . . 8 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 8 10. Change Log . . . . . . . . . . . . . . . . . . . . . . . . . 8 11. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 9 12. Normative References . . . . . . . . . . . . . . . . . . . . 9 Appendix A. Minimal SACM Statement Definition for YANG Output . 9 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 29 1. Introduction This document defines an XML encoding of SACM Statements that contain SACM Content composed of YANG modeled data (i.e. NETCONF messages). Correspondingly, this documents provides a standardized mapping to derive SACM Metadata from YANG Subscribed Notifications [I-D.ietf-netconf-subscribed-notifications] using Notification Message Headers and Bundles [I-D.ietf-netconf-notification-messages] content. Every message defined in the generic SACM Data Model is a SACM Statement. The SACM Statement structure is provided by the SACM Information Model. In consequence, a SACM Statement is an Information Element not acquired by, but created by SACM Components for inter-component distribution of SACM Content (Information Elements on the Data Plane that represent information about Target Endpoints (TE) or Guidance. Examples include: software identifiers, assessment guidance/results, ECA Policy rules, or VDD). Birkholz & Cam-Winget Expires July 22, 2018 [Page 2] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 YANG modules are a powerful established tool to provide Information Elements about Target Endpoints with well-defined semantics. YANG Push [I-D.ietf-netconf-yang-push] and the corresponding YANG Subscribed Notifications [I-D.ietf-netconf-subscribed-notifications] drafts make use of these modules to create streams of notifications (YANG telemetry). Subscriptions to YANG data stores or YANG streams are Data Sources that provide Information Elements that can be acquired by SACM Collectors to provide SACM Content on the Data Plane. Analogously, filter expressions used in the context of YANG subscriptions constitute SACM Content that is Imperative Guidance consumed by SACM Components on the Management Plane in order to create YANG telemetry. In this document (not including the abstract, of course), terms that are Capitalized or prefixed with SACM are defined in the SACM Terminology document. 2. Requirements notation 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 RFC 2119, BCP 14 [RFC2119]. 3. Brokering of YANG Push Telemetry via SACM Statements Every SACM Content is published into a SACM Domain using a statement envelope/encapsulation. The general structure of a SACM Statement is based on the Information Element definition found in [I-D.ietf-sacm-information-model] and can be summarized as follows: o a sacm-statement encapsulates statement-metadata and content- elements o a content-element encapsulates content-metadata and SACM Content In the scope of this document, only one type of SACM Content is covered: YANG modeled data. Correspondingly, the minimal required structure of statements, statement-metadata, content-elements, and content-metadata are defined. A complete XML schema definition of this subset of the generic SACM Data Model can be found in Appendix A. Birkholz & Cam-Winget Expires July 22, 2018 [Page 3] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 4. Encapsulation of YANG notifications in SACM content-elements A YANG notification is associated with a set of YANG specific metadata as defined in [I-D.ietf-netconf-notification-messages]. Hence, SACM Content that is derived from a YANG notification published to a SACM Domain MUST be encapsulated with its corresponding Metadata in a content-element as defined below. YANG output that is SACM Content MUST be represented according to the XSD definition included in the content choice of the content-element. 4.1. Enumeration definition for content-type An occurrence of the yang-output element MUST be instantiated in the content-metadata element, if YANG Push output is to be transferred. Also, the content-type MUST be set to the enumeration value "yang- output", respectively. In general, the list of content-type enumerations is including every subject as defined in the SACM Information Model. Regarding the definition of the subset of the generic SACM Data Model provided by this document, the list of potential content-types is reduced to "yang-output". Please note, that the complete generic SACM Data Model includes additional content-type enumerations next to the definition provided by this document. Birkholz & Cam-Winget Expires July 22, 2018 [Page 4] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 4.2. Element definition for content-metadata The list of optional elements included in content-metadata will incorporate any every potential metadata type. For the scope of this document, the list of elements is also limited to the minimal required set of metadata elements and the yang-output metadata element to support the encapsulation of NETCONF encoded subscribed notifications or YANG query result. As defined above, one occurrence of the yang-output element has to be included in the content-metadata element. A more complete content-metadata element definition is illustrated in the Appendix A. 4.3. Definition of the yang-output-metadata element included in content-metadata The composition of metadata that can be associated with a XML NETCONF result depends on multiple factors: o acquisition method: query / subscription o encoding: XML # more content encodings will be supported as indicated by the definition o subscription interval: periodic / on-change o filter-type: xpath / subtree Additionally, the actual filter expression (or in future iterations of this work, a referencing Label, such as a URI, UUID or other composed identifier) has to be included in the content-metadata. Birkholz & Cam-Winget Expires July 22, 2018 [Page 5] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 6] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 5. Mapping of YANG Bundled Notifications to SACM Metadata [I-D.ietf-netconf-notification-messages] includes the following definition: yang-data bundled-message +-- bundled-message-header | +-- message-time yang:date-and-time | +-- message-id? uint32 | +-- previous-message-id? uint32 | +-- message-generator-id? string | +-- signature? string | +-- notification-count? uint16 +-- notifications* +-- notification-header | +-- notification-time yang:date-and-time | +-- subscription-id* uint32 | +-- notification-id? uint32 | +-- module? yang-identifier | +-- notification-type? notification | +-- observation-domain-id? string +-- receiver-record-contents? The corresponding mapping MUST be used when deriving SACM Content Metadata for content-metadata items from YANG modeled data corresponding to YANG Notification Message Headers and Bundles: notification-time -> content-creation-timestamp subscription-id + (observation-domain-id OR "SACM Component Label") -> content-element-guid module -> module-names notification-type -> yang-subscribtion-type receiver-record-contents -> content-elements If there are more than one receiver-record-contents instanced included in the received Notification Message Bundle, multiple content-elements MUST be instanciated, accordingly. The following mapping MUST be used when deriving SACM Statement Metadata (see Appendix A) statement-metadata items representing NETCONF instances adhering to the definition of YANG Notification Message Headers and Bundles: message-id -> statement-guid "SACM Component Label" -> data-origin message-time -> statement-creation-timestamp "SACM Component Publictation Time" -> statement-publish-timestamp statement-type -> "Observation" Birkholz & Cam-Winget Expires July 22, 2018 [Page 7] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 "SACM Component Publicatation Time" can only be inferred by the SACM Component using its "most trustworthy source of time". If there is not receiver-record-contents included in the YANG notification, a SACM Component MUST NOT publish a corresponding SACM Statement to the SACM Domain. 6. SACM Component Composition A SACM Component able to process YANG subscribed notifications requires at least two functions: o a SACM Function supporting YANG Push and YANG Notification Headers and o Bundles function [I-D.ietf-netconf-yang-push], [I-D.ietf-netconf-subscribed-notifications], and o an xmpp-grid provider function [I-D.ietf-mile-xmpp-grid] Orchestration of functions inside a component, their discovery as capabilities and the internal distribution of SACM Content inside a SACM Component is out of scope of this document. # for now 7. IANA considerations This document includes requests to IANA. 8. Security Considerations TBD 9. Acknowledgements Christoph Vigano, Guangying Zheng, Eric Voit, Alexander Clemm 10. Change Log First version -00 Second version -01 * generalized the content of the document, detaching it from the implementation created at the Hackaton of IETF 99 * included a mapping of the -03 version of the YANG Notification Headers and Bundles draft to this draft Birkholz & Cam-Winget Expires July 22, 2018 [Page 8] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 11. Contributors Eric Voit 12. Normative References [I-D.ietf-mile-xmpp-grid] Cam-Winget, N., Appala, S., Pope, S., and P. Saint-Andre, "Using XMPP for Security Information Exchange", draft- ietf-mile-xmpp-grid-04 (work in progress), October 2017. [I-D.ietf-netconf-notification-messages] Voit, E., Bierman, A., Clemm, A., and T. Jenkins, "Notification Message Headers and Bundles", draft-ietf- netconf-notification-messages-02 (work in progress), October 2017. [I-D.ietf-netconf-subscribed-notifications] Voit, E., Clemm, A., Prieto, A., Nilsen-Nygaard, E., and A. Tripathy, "Custom Subscription to Event Streams", draft-ietf-netconf-subscribed-notifications-08 (work in progress), December 2017. [I-D.ietf-netconf-yang-push] Clemm, A., Voit, E., Prieto, A., Tripathy, A., Nilsen- Nygaard, E., Bierman, A., and B. Lengyel, "YANG Datastore Subscription", draft-ietf-netconf-yang-push-12 (work in progress), December 2017. [I-D.ietf-sacm-information-model] Waltermire, D., Watson, K., Kahn, C., Lorenzin, L., Cokus, M., Haynes, D., and H. Birkholz, "SACM Information Model", draft-ietf-sacm-information-model-10 (work in progress), April 2017. [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, . Appendix A. Minimal SACM Statement Definition for YANG Output The definitions of statements, statement-metadata, content-element, and content-metadata are provided by the SACM Information Model [I-D.ietf-sacm-information-model]. Due to the stripping down of content-elements to YANG output, the enumerations still included in the relationship-type are not able to Birkholz & Cam-Winget Expires July 22, 2018 [Page 9] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 point to other types of content in the scope of this document, but are able to reference other content-types in the scope of the generic SACM Data Model. Birkholz & Cam-Winget Expires July 22, 2018 [Page 10] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 11] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 12] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 13] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 14] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 15] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 16] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 17] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 18] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 19] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 20] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 21] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 22] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 23] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 24] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 25] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 26] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 27] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Birkholz & Cam-Winget Expires July 22, 2018 [Page 28] Internet-DrafYANG subscribed notifications via SACM Stateme January 2018 Authors' Addresses Henk Birkholz Fraunhofer SIT Rheinstrasse 75 Darmstadt 64295 Germany Email: henk.birkholz@sit.fraunhofer.de Nancy Cam-Winget Cisco Systems 3550 Cisco Way San Jose, CA 95134 USA Email: ncamwing@cisco.com Birkholz & Cam-Winget Expires July 22, 2018 [Page 29]