draft-ietf-ntp-yang-data-model-03.txt   draft-ietf-ntp-yang-data-model-04.txt 
NTP Working Group N. Wu NTP Working Group N. Wu
Internet-Draft Huawei Internet-Draft D. Dhody
Intended status: Standards Track A. Kumar S N Intended status: Standards Track Huawei
Expires: December 24, 2018 RtBrick Inc. Expires: April 18, 2019 A. Sinha
A. Kumar S N
RtBrick Inc.
Y. Zhao Y. Zhao
Ericsson Ericsson
D. Dhody October 15, 2018
Huawei
A. Sinha
RtBrick Inc.
June 22, 2018
A YANG Data Model for NTP A YANG Data Model for NTP
draft-ietf-ntp-yang-data-model-03 draft-ietf-ntp-yang-data-model-04
Abstract Abstract
This document defines a YANG data model for Network Time Protocol This document defines a YANG data model for Network Time Protocol
(NTP) implementations. The data model includes configuration data (NTP) implementations. The data model includes configuration data
and state data. and state data.
Requirements Language Requirements Language
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
skipping to change at page 1, line 47 skipping to change at page 1, line 45
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at https://datatracker.ietf.org/drafts/current/. Drafts is at https://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on December 24, 2018. This Internet-Draft will expire on April 18, 2019.
Copyright Notice Copyright Notice
Copyright (c) 2018 IETF Trust and the persons identified as the Copyright (c) 2018 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(https://trustee.ietf.org/license-info) in effect on the date of (https://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
skipping to change at page 2, line 30 skipping to change at page 2, line 30
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
1.1. Operational State . . . . . . . . . . . . . . . . . . . . 3 1.1. Operational State . . . . . . . . . . . . . . . . . . . . 3
1.2. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3 1.2. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3
1.3. Tree Diagrams . . . . . . . . . . . . . . . . . . . . . . 3 1.3. Tree Diagrams . . . . . . . . . . . . . . . . . . . . . . 3
1.4. Prefixes in Data Node Names . . . . . . . . . . . . . . . 3 1.4. Prefixes in Data Node Names . . . . . . . . . . . . . . . 3
2. NTP data model . . . . . . . . . . . . . . . . . . . . . . . 4 2. NTP data model . . . . . . . . . . . . . . . . . . . . . . . 4
3. Relationship with NTPv4-MIB . . . . . . . . . . . . . . . . . 7 3. Relationship with NTPv4-MIB . . . . . . . . . . . . . . . . . 7
4. Relationship with RFC 7317 . . . . . . . . . . . . . . . . . 9 4. Relationship with RFC 7317 . . . . . . . . . . . . . . . . . 9
5. NTP YANG Module . . . . . . . . . . . . . . . . . . . . . . . 9 5. Access Rules . . . . . . . . . . . . . . . . . . . . . . . . 9
6. Usage Example . . . . . . . . . . . . . . . . . . . . . . . . 29 6. Key Management . . . . . . . . . . . . . . . . . . . . . . . 9
6.1. Unicast association . . . . . . . . . . . . . . . . . . . 29 7. NTP YANG Module . . . . . . . . . . . . . . . . . . . . . . . 10
6.2. Refclock master . . . . . . . . . . . . . . . . . . . . . 31 8. Usage Example . . . . . . . . . . . . . . . . . . . . . . . . 31
6.3. Authentication configuration . . . . . . . . . . . . . . 32 8.1. Unicast association . . . . . . . . . . . . . . . . . . . 31
6.4. Access configuration . . . . . . . . . . . . . . . . . . 34 8.2. Refclock master . . . . . . . . . . . . . . . . . . . . . 33
6.5. Multicast configuration . . . . . . . . . . . . . . . . . 34 8.3. Authentication configuration . . . . . . . . . . . . . . 34
6.6. Manycast configuration . . . . . . . . . . . . . . . . . 38 8.4. Access configuration . . . . . . . . . . . . . . . . . . 36
6.7. Clock state . . . . . . . . . . . . . . . . . . . . . . . 41 8.5. Multicast configuration . . . . . . . . . . . . . . . . . 36
6.8. Get all association . . . . . . . . . . . . . . . . . . . 41 8.6. Manycast configuration . . . . . . . . . . . . . . . . . 40
6.9. Global statistic . . . . . . . . . . . . . . . . . . . . 43 8.7. Clock state . . . . . . . . . . . . . . . . . . . . . . . 43
7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 43 8.8. Get all association . . . . . . . . . . . . . . . . . . . 43
8. Security Considerations . . . . . . . . . . . . . . . . . . . 44 8.9. Global statistic . . . . . . . . . . . . . . . . . . . . 45
9. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 45 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 45
10. References . . . . . . . . . . . . . . . . . . . . . . . . . 45 10. Security Considerations . . . . . . . . . . . . . . . . . . . 46
10.1. Normative References . . . . . . . . . . . . . . . . . . 45 11. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 47
10.2. Informative References . . . . . . . . . . . . . . . . . 47 12. References . . . . . . . . . . . . . . . . . . . . . . . . . 47
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 47 12.1. Normative References . . . . . . . . . . . . . . . . . . 47
12.2. Informative References . . . . . . . . . . . . . . . . . 49
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 49
1. Introduction 1. Introduction
This document defines a YANG [RFC6020] data model for Network Time This document defines a YANG [RFC7950] data model for Network Time
Protocol [RFC5905] implementations. Protocol [RFC5905] implementations.
The data model convers configuration of system parameters of NTP, The data model convers configuration of system parameters of NTP,
such as access rules, authentication and VPN Routing and Forwarding such as access rules, authentication and VPN Routing and Forwarding
(VRF) binding, and also associations of NTP in different modes and (VRF) binding, and also associations of NTP in different modes and
parameters of per-interface. It also provides information about parameters of per-interface. It also provides information about
running state of NTP implementations. running state of NTP implementations.
1.1. Operational State 1.1. Operational State
skipping to change at page 4, line 25 skipping to change at page 4, line 25
| rt-types | ietf-routing-types | [RFC8294] | | rt-types | ietf-routing-types | [RFC8294] |
+----------+--------------------------+-----------------------------+ +----------+--------------------------+-----------------------------+
Table 1: Prefixes and corresponding YANG modules Table 1: Prefixes and corresponding YANG modules
2. NTP data model 2. NTP data model
This document defines the YANG module "ietf-ntp", which has the This document defines the YANG module "ietf-ntp", which has the
following structure: following structure:
module: ietf-ntp module: ietf-ntp
+--rw ntp! +--rw ntp!
+--rw port? uint16 {ntp-port}? +--rw port? inet:port-number {ntp-port}?
+--rw refclock-master! +--rw refclock-master!
| +--rw master-stratum? ntp-stratum | +--rw master-stratum? ntp-stratum
+--rw authentication +--rw authentication
| +--rw auth-enabled? boolean | +--rw auth-enabled? boolean
| +--rw trusted-keys* [key-id] | +--rw authentication-keys* [key-id]
| | +--rw key-id | +--rw key-id uint32
| | -> /ntp/authentication/authentication-keys/key-id | +--rw algorithm? identityref
| +--rw authentication-keys* [key-id] | +--rw key? ianach:crypt-hash
| +--rw key-id uint32 | +--rw istrusted? boolean
| +--rw algorithm? identityref +--rw access-rules
| +--rw password? ianach:crypt-hash | +--rw access-rule* [access-mode]
+--rw access-rules | +--rw access-mode access-mode
| +--rw access-rule* [access-mode] | +--rw acl? -> /acl:acls/acl/name
| +--rw access-mode access-modes +--ro clock-state
| +--rw acl? -> /acl:acls/acl/name | +--ro system-status
+--ro clock-state | +--ro clock-state ntp-clock-status
| +--ro system-status | +--ro clock-stratum ntp-stratum
| +--ro clock-state ntp-clock-status | +--ro clock-refid union
| +--ro clock-stratum ntp-stratum | +--ro associations-address? -> /ntp/associations/address
| +--ro clock-refid union | +--ro associations-local-mode?
| +--ro associations-address? | | -> /ntp/associations/local-mode
| | -> /ntp/associations/address | +--ro associations-isconfigured?
| +--ro associations-local-mode? | | -> /ntp/associations/isconfigured
| | -> /ntp/associations/local-mode | +--ro nominal-freq decimal64
| +--ro associations-isConfigured? | +--ro actual-freq decimal64
| | -> /ntp/associations/isConfigured | +--ro clock-precision uint8
| +--ro nominal-freq decimal64 | +--ro clock-offset? decimal64
| +--ro actual-freq decimal64 | +--ro root-delay? decimal64
| +--ro clock-precision uint8 | +--ro root-dispersion? decimal64
| +--ro clock-offset? decimal64 | +--ro reference-time? yang:date-and-time
| +--ro root-delay? decimal64 | +--ro sync-state ntp-sync-state
| +--ro root-dispersion? decimal64 +--rw unicast-configuration* [address type]
| +--ro reference-time? yang:date-and-time | +--rw address inet:host
| +--ro sync-state ntp-sync-state | +--rw type unicast-configuration-type
+--rw unicast-configuration* [address type] | +--rw authentication
| +--rw address inet:host | | +--rw (authentication-type)?
| +--rw type unicast-configuration-type | | +--:(symmetric-key)
| +--rw authentication | | +--rw key-id? leafref
| | +--rw (authentication-type)? | +--rw prefer? boolean
| | +--:(symmetric-key) | +--rw burst? boolean
| | +--rw key-id? leafref | +--rw iburst? boolean
| +--rw prefer? boolean | +--rw source? if:interface-ref
| +--rw burst? boolean | +--rw minpoll? ntp-minpoll
| +--rw iburst? boolean | +--rw maxpoll? ntp-maxpoll
| +--rw source? if:interface-ref | +--rw port? inet:port-number {ntp-port}?
| +--rw minpoll? ntp-minpoll | +--rw version? ntp-version
| +--rw maxpoll? ntp-maxpoll +--ro associations* [address local-mode isconfigured]
| +--rw port? uint16 {ntp-port}? | +--ro address inet:host
| +--rw version? ntp-version | +--ro local-mode association-mode
+--ro associations* [address local-mode isConfigured] | +--ro isconfigured boolean
| +--ro address inet:host | +--ro stratum? ntp-stratum
| +--ro local-mode association-modes | +--ro refid? union
| +--ro isConfigured boolean | +--ro authentication?
| +--ro stratum? ntp-stratum | | -> /ntp/authentication/authentication-keys/key-id
| +--ro refid? union | +--ro prefer? boolean
| +--ro authentication? | +--ro peer-interface? if:interface-ref
| | -> /ntp/authentication/authentication-keys/key-id | +--ro minpoll? ntp-minpoll
| +--ro prefer? boolean | +--ro maxpoll? ntp-maxpoll
| +--ro peer-interface? if:interface-ref | +--ro port? inet:port-number {ntp-port}?
| +--ro minpoll? ntp-minpoll | +--ro version? ntp-version
| +--ro maxpoll? ntp-maxpoll | +--ro reach? uint8
| +--ro port? uint16 {ntp-port}? | +--ro unreach? uint8
| +--ro version? ntp-version | +--ro poll? uint8
| +--ro reach? uint8 | +--ro now? uint32
| +--ro unreach? uint8 | +--ro offset? decimal64
| +--ro poll? uint8 | +--ro delay? decimal64
| +--ro now? uint32 | +--ro dispersion? decimal64
| +--ro offset? decimal64 | +--ro originate-time? yang:date-and-time
| +--ro delay? decimal64 | +--ro receive-time? yang:date-and-time
| +--ro dispersion? decimal64 | +--ro transmit-time? yang:date-and-time
| +--ro originate-time? yang:date-and-time | +--ro input-time? yang:date-and-time
| +--ro receive-time? yang:date-and-time | +--ro ntp-statistics
| +--ro transmit-time? yang:date-and-time | +--ro packet-sent? yang:counter32
| +--ro input-time? yang:date-and-time | +--ro packet-sent-fail? yang:counter32
| +--ro ntp-statistics | +--ro packet-received? yang:counter32
| +--ro packet-sent? yang:counter32 | +--ro packet-dropped? yang:counter32
| +--ro packet-sent-fail? yang:counter32 +--rw interfaces
| +--ro packet-received? yang:counter32 | +--rw interface* [name]
| +--ro packet-dropped? yang:counter32 | +--rw name if:interface-ref
+--rw interfaces | +--rw broadcast-server!
| +--rw interface* [name] | | +--rw ttl? uint8
| +--rw name if:interface-ref | | +--rw authentication
| +--rw broadcast-server! | | | +--rw (authentication-type)?
| | +--rw ttl? uint8 | | | +--:(symmetric-key)
| | +--rw authentication | | | +--rw key-id? leafref
| | | +--rw (authentication-type)? | | +--rw minpoll? ntp-minpoll
| | | +--:(symmetric-key) | | +--rw maxpoll? ntp-maxpoll
| | | +--rw key-id? leafref | | +--rw port? inet:port-number {ntp-port}?
| | +--rw minpoll? ntp-minpoll | | +--rw version? ntp-version
| | +--rw maxpoll? ntp-maxpoll | +--rw broadcast-client!
| | +--rw port? uint16 {ntp-port}? | +--rw multicast-server* [address]
| | +--rw version? ntp-version | | +--rw address rt-types:ip-multicast-group-address
| +--rw broadcast-client! | | +--rw ttl? uint8
| +--rw multicast-server* [address] | | +--rw authentication
| | +--rw address | | | +--rw (authentication-type)?
| | | rt-types:ip-multicast-group-address | | | +--:(symmetric-key)
| | +--rw ttl? uint8 | | | +--rw key-id? leafref
| | +--rw authentication | | +--rw minpoll? ntp-minpoll
| | | +--rw (authentication-type)? | | +--rw maxpoll? ntp-maxpoll
| | | +--:(symmetric-key) | | +--rw port? inet:port-number {ntp-port}?
| | | +--rw key-id? leafref | | +--rw version? ntp-version
| | +--rw minpoll? ntp-minpoll | +--rw multicast-client* [address]
| | +--rw maxpoll? ntp-maxpoll | | +--rw address rt-types:ip-multicast-group-address
| | +--rw port? uint16 {ntp-port}? | +--rw manycast-server* [address]
| | +--rw version? ntp-version | | +--rw address rt-types:ip-multicast-group-address
| +--rw multicast-client* [address] | +--rw manycast-client* [address]
| | +--rw address rt-types:ip-multicast-group-address | +--rw address rt-types:ip-multicast-group-address
| +--rw manycast-server* [address] | +--rw authentication
| | +--rw address rt-types:ip-multicast-group-address | | +--rw (authentication-type)?
| +--rw manycast-client* [address] | | +--:(symmetric-key)
| +--rw address | | +--rw key-id? leafref
| | rt-types:ip-multicast-group-address | +--rw ttl? uint8
| +--rw authentication | +--rw minclock? uint8
| | +--rw (authentication-type)? | +--rw maxclock? uint8
| | +--:(symmetric-key) | +--rw beacon? uint8
| | +--rw key-id? leafref | +--rw minpoll? ntp-minpoll
| +--rw ttl? uint8 | +--rw maxpoll? ntp-maxpoll
| +--rw minclock? uint8 | +--rw port? inet:port-number {ntp-port}?
| +--rw maxclock? uint8 | +--rw version? ntp-version
| +--rw beacon? uint8 +--ro ntp-statistics
| +--rw minpoll? ntp-minpoll +--ro packet-sent? yang:counter32
| +--rw maxpoll? ntp-maxpoll +--ro packet-sent-fail? yang:counter32
| +--rw port? uint16 {ntp-port}? +--ro packet-received? yang:counter32
| +--rw version? ntp-version +--ro packet-dropped? yang:counter32
+--ro ntp-statistics groupings:
+--ro packet-sent? yang:counter32 authentication
+--ro packet-sent-fail? yang:counter32 +---- (authentication-type)?
+--ro packet-received? yang:counter32 +--:(symmetric-key)
+--ro packet-dropped? yang:counter32 +---- key-id?
-> /ntp/authentication/authentication-keys/key-id
grouping authentication-type-param statistics
+-- (authentication-type)? +---- packet-sent? yang:counter32
+--:(symmetric-key) +---- packet-sent-fail? yang:counter32
+-- key-id? +---- packet-received? yang:counter32
-> /ntp/authentication/authentication-keys/key-id +---- packet-dropped? yang:counter32
grouping comman-attributes
+-- minpoll? ntp-minpoll authentication-key
+-- maxpoll? ntp-maxpoll +---- key-id? uint32
+-- port? uint16 {ntp-port}? +---- algorithm? identityref
+-- version? ntp-version +---- key? ianach:crypt-hash
grouping association-ref +---- istrusted? boolean
+-- associations-address? -> /ntp/associations/address
+-- associations-local-mode? -> /ntp/associations/local-mode association-ref
+-- associations-isConfigured? +---- associations-address? -> /ntp/associations/address
-> /ntp/associations/isConfigured +---- associations-local-mode? -> /ntp/associations/local-mode
grouping statistics +---- associations-isconfigured? -> /ntp/associations/isconfigured
+-- packet-sent? yang:counter32
+-- packet-sent-fail? yang:counter32 common-attributes
+-- packet-received? yang:counter32 +---- minpoll? ntp-minpoll
+-- packet-dropped? yang:counter32 +---- maxpoll? ntp-maxpoll
grouping authentication-key +---- port? inet:port-number {ntp-port}?
+-- key-id? uint32 +---- version? ntp-version
+-- algorithm? identityref
+-- password? ianach:crypt-hash
This data model defines one top-level container which includes both This data model defines one top-level container which includes both
the NTP configuration and the NTP running state including access the NTP configuration and the NTP running state including access
rules, authentication, associations, unicast configurations, rules, authentication, associations, unicast configurations,
interfaces, system status and associations. interfaces, system status and associations.
3. Relationship with NTPv4-MIB 3. Relationship with NTPv4-MIB
If the device implements the NTPv4-MIB [RFC5907], data nodes from If the device implements the NTPv4-MIB [RFC5907], data nodes from
YANG module can be mapped to table entries in NTPv4-MIB. YANG module can be mapped to table entries in NTPv4-MIB.
skipping to change at page 9, line 10 skipping to change at page 9, line 10
| ntp-statistics/packet-dropped | ntpAssocStatProtocolError | | ntp-statistics/packet-dropped | ntpAssocStatProtocolError |
+---------------------------------------+---------------------------+ +---------------------------------------+---------------------------+
YANG NTP State Data Nodes and Related NTPv4-MIB Objects YANG NTP State Data Nodes and Related NTPv4-MIB Objects
4. Relationship with RFC 7317 4. Relationship with RFC 7317
This section describes the relationship with NTP definition in This section describes the relationship with NTP definition in
Section 3.2 System Time Management of [RFC7317] . YANG data nodes in Section 3.2 System Time Management of [RFC7317] . YANG data nodes in
/ntp/ also supports per-interface configurations which is not /ntp/ also supports per-interface configurations which is not
supported in /system/ntp supported in /system/ntp. If the yang model defined in this document
is implemented, then /system/ntp SHOULD NOT be used and MUST be
ignored.
+-------------------------------+--------------------------------+ +-------------------------------+--------------------------------+
| YANG data nodes in /ntp/ | YANG data nodes in /system/ntp | | YANG data nodes in /ntp/ | YANG data nodes in /system/ntp |
+-------------------------------+--------------------------------+ +-------------------------------+--------------------------------+
| ntp-enabled | enabled | | ntp-enabled | enabled |
| unicast-configuration | server | | unicast-configuration | server |
| | server/name | | | server/name |
| unicast-configuration/address | server/transport/udp/address | | unicast-configuration/address | server/transport/udp/address |
| unicast-configuration/port | server/transport/udp/port | | unicast-configuration/port | server/transport/udp/port |
| unicast-configuration/type | server/association-type | | unicast-configuration/type | server/association-type |
| unicast-configuration/iburst | server/iburst | | unicast-configuration/iburst | server/iburst |
| unicast-configuration/prefer | server/prefer | | unicast-configuration/prefer | server/prefer |
+-------------------------------+--------------------------------+ +-------------------------------+--------------------------------+
YANG NTP Configuration Data Nodes and counterparts in RFC 7317 YANG NTP Configuration Data Nodes and counterparts in RFC 7317
Objects Objects
5. NTP YANG Module 5. Access Rules
<CODE BEGINS> file "ietf-ntp@2018-06-22.yang" As per [RFC1305], NTP could include an access-control feature that
module ietf-ntp { prevents unauthorized access and controls which peers are allowed to
update the local clock. Further it is useful to differentiate
between the various kinds of access (such as peer or server; refer
access-mode) and attach different acl-rule to each. For this, the
YANG module allow such configuration via /ntp/access-rules. The
access-rule itself is configured via [I-D.ietf-netmod-acl-model].
yang-version 1.1; 6. Key Management
namespace "urn:ietf:params:xml:ns:yang:ietf-ntp"; As per [RFC1305], when authentication is enabled, NTP employs a
crypto-checksum, computed by the sender and checked by the receiver,
together with a set of predistributed algorithms, and cryptographic
keys indexed by a key identifier included in the NTP message. This
key-id is 32-bits unsigned integer that MUST be configured on the NTP
peers before the authentication could be used. For this reason, this
YANG modules allow such configuration via /ntp/authentication/
authentication-keys/. Further at the time of configuration of NTP
association (for example unicast-server), the key-id is specefied.
prefix "ntp"; 7. NTP YANG Module
import ietf-yang-types { <CODE BEGINS> file "ietf-ntp@2018-10-15.yang"
prefix "yang"; module ietf-ntp {
reference "RFC 6991";
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-ntp";
prefix "ntp";
import ietf-yang-types {
prefix "yang";
reference "RFC 6991";
}
import ietf-inet-types {
prefix "inet";
reference "RFC 6991";
}
import ietf-interfaces {
prefix "if";
reference "RFC 8343";
}
import iana-crypt-hash {
prefix "ianach";
reference "RFC 7317";
}
import ietf-key-chain {
prefix "key-chain";
reference "RFC 8177";
}
import ietf-access-control-list {
prefix "acl";
reference "RFC XXXX";
}
import ietf-routing-types {
prefix "rt-types";
reference "RFC 8294";
}
organization
"IETF NTP (Network Time Protocol) Working Group";
contact
"WG Web: <http://tools.ietf.org/wg/ntp/>
WG List: <mailto: ntpwg@lists.ntp.org
Editor: Eric Wu
<mailto:eric.wu@huawei.com>
Editor: Anil Kumar S N
<mailto:anil.ietf@gmail.com>
Editor: Yi Zhao
<mailto:yi.z.zhao@ericsson.com>
Editor: Dhruv Dhody
<mailto:dhruv.ietf@gmail.com>
Editor: Ankit Kumar Sinha
<mailto:ankit.ietf@gmail.com>";
description
"This YANG module defines essential components for the
management of a routing subsystem.
Copyright (c) 2018 IETF Trust and the persons identified
as authors of the code. All rights reserved.
Redistribution and use in source and binary forms,
with or without modification, is permitted pursuant to,
and subject to the license terms contained in, the
Simplified BSD License set forth in Section 4.c of the
IETF Trust's Legal Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info).
This version of this YANG module is part of RFC XXXX;
see the RFC itself for full legal notices.";
revision 2018-10-15 {
description
"Updated revision.";
reference
"RFC XXXX: A YANG Data Model for NTP Management";
}
/* Typedef Definitions */
typedef ntp-stratum {
type uint8 {
range "1..16";
} }
description
"The level of each server in the hierarchy is defined by
a stratum. Primary servers are assigned with stratum
one; secondary servers at each lower level are assigned with
one stratum greater than the preceding level";
import ietf-inet-types { }
prefix "inet";
reference "RFC 6991"; typedef ntp-version {
type uint8 {
range "1..4";
} }
default "3";
description
"The current NTP version supported by corresponding
association.";
}
import ietf-interfaces { typedef ntp-minpoll {
prefix "if"; type uint8 {
reference "RFC 8343"; range "4..17";
} }
import iana-crypt-hash { default "6";
prefix "ianach"; description
reference "RFC 7317"; "The minimum poll exponent for this NTP association.";
}
typedef ntp-maxpoll {
type uint8 {
range "4..17";
} }
default "10";
description
"The maximum poll exponent for this NTP association.";
}
import ietf-key-chain { typedef access-mode {
prefix "key-chain"; type enumeration {
reference "RFC 8177"; enum peer {
value "0";
description
"Enables the full access authority. Both time
request and control query can be performed
on the local NTP service, and the local clock
can be synchronized with the remote server.";
}
enum server {
value "1";
description
"Enables the server access and query.
Both time requests and control query can be
performed on the local NTP service, but the
local clock cannot be synchronized with the
remote server.";
}
enum synchronization {
value "2";
description
"Enables the server to access.
Only time request can be performed on the
local NTP service.";
}
enum query {
value "3";
description
"Enables the maximum access limitation.
Control query can be performed only on the
local NTP service.";
}
} }
description
"This defines NTP access modes.";
}
import ietf-access-control-list { typedef unicast-configuration-type {
prefix "acl"; type enumeration {
reference "RFC XXXX"; enum server {
value "0";
description
"Use client association mode. This device
will not provide synchronization to the
configured NTP server.";
}
enum peer {
value "1";
description
"Use symmetric active association mode.
This device may provide synchronization
to the configured NTP server.";
}
} }
import ietf-routing-types { description
prefix "rt-types"; "This defines NTP unicast mode of operation.";
reference "RFC 8294"; }
typedef association-mode {
type enumeration {
enum client {
value "0";
description
"Use client association mode(mode 3).
This device will not provide synchronization
to the configured NTP server.";
}
enum active {
value "1";
description
"Use symmetric active association mode(mode 1).
This device may synchronize with its NTP peer,
or provide synchronization to configured NTP peer.";
}
enum passive {
value "2";
description
"Use symmetric passive association mode(mode 2).
This device has learned this association dynamically.
This device may synchronize with its NTP peer.";
}
enum broadcast {
value "3";
description
"Use broadcast mode(mode 5).
This mode defines that its either working
as broadcast-server or multicast-server.";
}
enum broadcast-client {
value "4";
description
"This mode defines that its either working
as broadcast-client or multicast-client.";
}
} }
description
"The NTP association modes.";
}
organization typedef ntp-clock-status {
"IETF NTP (Network Time Protocol) Working Group"; type enumeration {
enum synchronized {
value "0";
description
"Indicates that the local clock has been
synchronized with an NTP server or
the reference clock.";
}
enum unsynchronized {
value "1";
description
"Indicates that the local clock has not been
synchronized with any NTP server.";
}
contact }
"WG Web: <http://tools.ietf.org/wg/ntp/>
WG List: <mailto: ntpwg@lists.ntp.org
Editor: Eric Wu
<mailto:eric.wu@huawei.com>
Editor: Anil Kumar S N
<mailto:anil.ietf@gmail.com>
Editor: Yi Zhao
<mailto:yi.z.zhao@ericsson.com>
Editor: Dhruv Dhody
<mailto:dhruv.ietf@gmail.com>
Editor: Ankit Kumar Sinha
<mailto:ankit.ietf@gmail.com>";
description description
"This YANG module defines essential components for the "This defines NTP clock status.";
management of a routing subsystem. }
Copyright (c) 2018 IETF Trust and the persons identified typedef ntp-sync-state {
as authors of the code. All rights reserved. type enumeration {
enum clock-not-set {
value "0";
description
"Indicates the clock is not updated.";
}
enum freq-set-by-cfg {
value "1";
description
"Indicates the clock frequency is set by
NTP configuration.";
}
enum clock-set {
value "2";
description
"Indicates the clock is set.";
}
enum freq-not-determined {
value "3";
description
"Indicates the clock is set but the frequency
is not determined.";
}
enum clock-synchronized {
value "4";
description
"Indicates that the clock is synchronized";
}
enum spike {
value "5";
description
"Indicates a time difference of more than 128
milliseconds is detected between NTP server
and client clock. The clock change will take
effect in XXX seconds.";
}
}
description
"This defines NTP clock sync states.";
}
Redistribution and use in source and binary forms, /* features */
with or without modification, is permitted pursuant to, feature ntp-port {
and subject to the license terms contained in, the description
Simplified BSD License set forth in Section 4.c of the "Support for NTP port configuration";
IETF Trust's Legal Provisions Relating to IETF Documents reference "RFC1305 - 3.2.7 Parameters";
(http://trustee.ietf.org/license-info). }
This version of this YANG module is part of RFC XXXX; feature authentication {
see the RFC itself for full legal notices."; description
"Support for NTP symmetric key authentication";
reference "RFC1305 - 3.2.6 Authentication Variables";
}
revision 2018-06-22 { feature access-rules {
description description
"Updated revision."; "Support for NTP access control";
reference reference "RFC1305 - 3.6 Access Control Issues";
"RFC XXXX: A YANG Data Model for NTP Management"; }
}
/* Typedef Definitions */ feature unicast-configuration {
description
"Support for NTP client/server or active/passive
in unicast";
reference "RFC1305 - 3.3 Modes of Operation";
}
typedef ntp-stratum { feature broadcast-server {
type uint8 { description
range "1..16"; "Support for broadcast server";
reference "RFC1305 - 3.3 Modes of Operation";
}
feature broadcast-client {
description
"Support for broadcast client";
reference "RFC1305 - 3.3 Modes of Operation";
}
feature multicast-server {
description
"Support for multicast server";
reference "RFC1305 - 3.3 Modes of Operation";
}
feature multicast-client {
description
"Support for multicast client";
reference "RFC1305 - 3.3 Modes of Operation";
}
feature manycast-server {
description
"Support for manycast server";
reference "RFC5905 - 3.1 Dynamic Server Discovery";
}
feature manycast-client {
description
"Support for manycast client";
reference "RFC5905 - 3.1 Dynamic Server Discovery";
}
/* Groupings */
grouping authentication-key {
description
"To define an authentication key for a Network Time
Protocol (NTP) time source.";
leaf key-id {
type uint32 {
range "1..max";
} }
description description
"The level of each server in the hierarchy is defined by "Authentication key identifier.";
a stratum number. Primary servers are assigned stratum }
one; secondary servers at each lower level are assigned leaf algorithm {
stratum numbers one greater than the preceding level"; type identityref {
base key-chain:crypto-algorithm;
}
description
"Authentication algorithm.";
}
leaf key {
type ianach:crypt-hash;
description
"The key";
} }
leaf istrusted {
type boolean;
description
"Key-id is trusted or not";
}
}
typedef ntp-version { grouping authentication {
type uint8 { description
range "1..4"; "Authentication.";
choice authentication-type {
description
"Type of authentication.";
case symmetric-key {
leaf key-id {
type leafref {
path "/ntp:ntp/ntp:authentication/"
+ "ntp:authentication-keys/ntp:key-id";
}
description
"Authentication key id referenced in this
association.";
}
} }
default "3"; }
}
grouping statistics {
description
"NTP packet statistic.";
leaf packet-sent {
type yang:counter32;
description description
"The current NTP version supported by corresponding "The total number of packets sent.";
association."; }
leaf packet-sent-fail {
type yang:counter32;
description
"The number of times packet
sending failed.";
}
leaf packet-received {
type yang:counter32;
description
"The total number of packets received.";
}
leaf packet-dropped {
type yang:counter32;
description
"The number of packets dropped.";
} }
}
typedef ntp-minpoll { grouping common-attributes {
type uint8 { description
range "4..17"; "NTP common attributes for configuration.";
leaf minpoll {
type ntp-minpoll;
description
"The minimum poll interval used in this association.";
}
leaf maxpoll {
type ntp-maxpoll;
description
"The maximum poll interval used in this association.";
}
leaf port {
if-feature ntp-port;
type inet:port-number {
range "123 | 1025..max";
} }
default "6"; default "123";
description description
"The minimum poll exponent for this NTP association."; "Specify the port used to send NTP packets.";
}
leaf version {
type ntp-version;
description
"NTP version.";
} }
}
typedef ntp-maxpoll { grouping association-ref {
type uint8 { description
range "4..17"; "Reference to NTP association mode";
leaf associations-address {
type leafref {
path "/ntp:ntp/ntp:associations/ntp:address";
} }
default "10";
description description
"The maximul poll exponent for this NTP association."; "Indicates the association's address
which result in clock synchronization.";
}
leaf associations-local-mode {
type leafref {
path "/ntp:ntp/ntp:associations/ntp:local-mode";
}
description
"Indicates the association's local-mode
which result in clock synchronization.";
} }
leaf associations-isconfigured {
type leafref {
path "/ntp:ntp/ntp:associations/"
+ "ntp:isconfigured";
}
description
"The association was configured or dynamic
which result in clock synchronization.";
}
}
typedef access-modes { /* Configuration data nodes */
type enumeration { container ntp {
enum peer { presence
value "0"; "NTP is enabled";
description description
"Sets the fully access authority. Both time "Configuration parameters for NTP.";
request and control query can be performed leaf port {
on the local NTP service, and the local clock if-feature ntp-port;
can be synchronized to the remote server."; type inet:port-number {
} range "123 | 1025..max";
enum server {
value "1";
description
"Enables the server access and query.
Both time requests and control query can be
performed on the local NTP service, but the
local clock cannot be synchronized to the
remote server.";
}
enum synchronization {
value "2";
description
"Enables the server to access.
Only time request can be performed on the
local NTP service.";
}
enum query {
value "3";
description
"Sets the maximum access limitation.
Control query can be performed only on the
local NTP service.";
}
} }
default "123";
description description
"This defines NTP acess modes."; "Specify the port used to send NTP packets.";
} }
container refclock-master {
presence
"NTP master clock is enabled";
description
"Configures the device as NTP server.";
leaf master-stratum {
type ntp-stratum;
default "16";
description
"Stratum level from which NTP
clients get their time synchronized.";
}
}
container authentication {
description
"Configuration of authentication.";
leaf auth-enabled {
type boolean;
default false;
description
"Controls whether NTP authentication is enabled
or disabled on this device.";
}
list authentication-keys {
key "key-id";
uses authentication-key;
description
"List of authentication keys.";
}
typedef unicast-configuration-type { }
type enumeration {
enum server { container access-rules {
value "0"; description
"Configuration to control access to NTP service
by using NTP access-group feature.
The access-mode identifies how the acl is
applied with NTP";
list access-rule {
key "access-mode";
description
"List of access rules.";
leaf access-mode {
type access-mode;
description description
"Use client association mode. This device "NTP access mode.";
will not provide synchronization to the
configured NTP server.";
} }
enum peer { leaf acl {
value "1"; type leafref {
path "/acl:acls/acl:acl/acl:name";
}
description description
"Use symmetric active association mode. "NTP ACL.";
This device may provide synchronization
to the configured NTP server.";
} }
reference
"RFC 1305";
} }
description
"This defines NTP unicast mode of operation.";
} }
typedef association-modes {
type enumeration { container clock-state {
enum client { config "false";
value "0"; description
description "Operational state of the NTP.";
"Use client association mode(mode 3).
This device will not provide synchronization container system-status {
to the configured NTP server."; description
} "System status of NTP.";
enum active { leaf clock-state {
value "1"; type ntp-clock-status;
mandatory true;
description description
"Use symmetric active association mode(mode 1). "The state of system clock.";
This device may synchronize with its NTP peer,
or provide synchronization to configured NTP peer.";
} }
enum passive { leaf clock-stratum {
value "2"; type ntp-stratum;
mandatory true;
description description
"Use symmetric passive association mode(mode 2). "The stratum of the reference clock.";
This device has learnt this asso dynamically.
This device may synchronize with its NTP peer.";
} }
enum broadcast { leaf clock-refid {
value "3"; type union {
type inet:ipv4-address;
type binary {
length "4";
}
type string {
length "4";
}
}
mandatory true;
description description
"Use broadcast mode(mode 5). "IPv4 address or first 32 bits of the MD5 hash of
This mode defines that its eigther working the IPv6 address or reference clock of the peer to
as broadcast-server or multicast-server."; which clock is synchronized.";
} }
enum broadcast-client {
value "4"; uses association-ref {
description description
"This mode defines that its eigther working "Reference to Association";
as broadcast-client or multicast-client.";
} }
} leaf nominal-freq {
description type decimal64 {
"This defines NTP association modes."; fraction-digits 4;
} }
units Hz;
typedef ntp-clock-status { mandatory true;
type enumeration {
enum synchronized {
value "0";
description description
"Indicates that the local clock has been "The nominal frequency of the
synchronized with an NTP server or local clock";
the reference clock.";
} }
enum unsynchronized { leaf actual-freq {
value "1"; type decimal64 {
fraction-digits 4;
}
units Hz;
mandatory true;
description description
"Indicates that the local clock has not been "The actual frequency of the
synchronized with any NTP server."; local clock";
} }
} leaf clock-precision {
description type uint8;
"This defines NTP clock status."; units Hz;
} mandatory true;
typedef ntp-sync-state {
type enumeration {
enum clock-not-set {
value "0";
description description
"Indicates the clock is not updated."; "Clock precision of this system
(prec=2^(-n))";
} }
enum freq-set-by-cfg { leaf clock-offset {
value "1"; type decimal64 {
fraction-digits 4;
}
units milliseconds;
description description
"Indicates the clock frequency is set by "Clock offset with the synchronized peer";
NTP configuration.";
} }
enum clock-set { leaf root-delay {
value "2"; type decimal64 {
fraction-digits 2;
}
units milliseconds;
description description
"Indicates the clock is set."; "Total delay along the path to root clock";
} }
enum freq-not-determined { leaf root-dispersion {
value "3"; type decimal64 {
fraction-digits 2;
}
units milliseconds;
description description
"Indicates the clock is set but the frequency "The dispersion between the local clock
is not determined."; and the master reference clock.";
} }
enum clock-synchronized { leaf reference-time {
value "4"; type yang:date-and-time;
description description
"Indicates that the clock is synchronized"; "The reference timestamp.";
} }
enum spike { leaf sync-state {
value "5"; type ntp-sync-state;
mandatory true;
description description
"Indicates a time difference of more than 128 "The synchronization status of
milliseconds is detected between NTP server the local clock.";
and client clock. The clock change will take
effect in XXX seconds.";
} }
} }
}
list unicast-configuration {
key "address type";
description description
"This defines NTP clock sync states."; "List of unicast-configuration.";
leaf address {
type inet:host;
description
"Address of this association.";
}
leaf type {
type unicast-configuration-type;
description
"Type of unicast configuration";
}
container authentication{
description
"Authentication.";
uses authentication;
}
leaf prefer {
type boolean;
default "false";
description
"Whether this association is preferred.";
}
leaf burst {
type boolean;
default "false";
description
"If set, a series of packets are sent instead of a single
packet within each synchronization interval to achieve faster
synchronization.";
}
leaf iburst {
type boolean;
default "false";
description
"If set, a series of packets are sent instead of a single
packet within the initial synchronization interval to achieve
faster initial synchronization.";
}
leaf source {
type if:interface-ref;
description
"The interface whose IP address is used by this association
as the source address.";
}
uses common-attributes {
description
"Common attributes like port, version, min and max
poll.";
}
} }
list associations {
key "address local-mode isconfigured";
config "false";
description
"list of NTP associations. Here address,local-mode
and isconfigured is required to uniquely identify
a particular association. Lets take following examples
/* feature */ 1) If RT1 acting as broadcast server,
feature ntp-port { and RT2 acting as broadcast client, then RT2
description will form dynamic association with address as RT1,
"Indicates that the device supports the configuration of local-mode as client and isconfigured as false.
the port for NTP.
This is a 'feature', since many implementations do not 2) When RT2 is configured
support any port other than the default port."; with unicast-server RT1, then RT2 will form
} association with address as RT1, local-mode as client
and isconfigured as true.
/* Groupings */ Thus all 3 leaves are needed as key to unique identify
grouping authentication-key { the association.";
description leaf address {
"To define an authentication key for a Network Time type inet:host;
Protocol (NTP) time source.";
leaf key-id {
type uint32 {
range "1..max";
}
description description
"Authentication key identifier."; "The address of this association.";
} }
leaf algorithm { leaf local-mode {
type identityref { type association-mode;
base key-chain:crypto-algorithm;
}
description description
"Authentication algorithm."; "Local mode for this NTP association.";
} }
leaf password { leaf isconfigured {
type ianach:crypt-hash; type boolean;
description "Clear or encrypted mode for password text."; description
"Indicates if this association is configured or
dynamically learned.";
} }
} leaf stratum {
type ntp-stratum;
grouping authentication-type-param {
description
"Authentication type.";
choice authentication-type {
description description
"Type of authentication."; "Indicates the stratum of the reference clock.";
case symmetric-key { }
leaf key-id { leaf refid {
type leafref { type union {
path "/ntp:ntp/ntp:authentication/" type inet:ipv4-address;
+ "ntp:authentication-keys/ntp:key-id"; type binary {
} length "4";
description }
"Authentication key id referenced in this type string {
association."; length "4";
} }
} }
description
"Reference clock type or address for the peer.";
} }
} leaf authentication{
type leafref {
grouping statistics { path "/ntp:ntp/ntp:authentication/"
description + "ntp:authentication-keys/ntp:key-id";
"NTP packet statistic."; }
leaf packet-sent {
type yang:counter32;
description description
"Indicates the total number of packets sent."; "Authentication Key used for this association.";
} }
leaf packet-sent-fail { leaf prefer {
type yang:counter32; type boolean;
default "false";
description description
"Indicates the number of times packet "Indicates if this association is preferred.";
sending failed.";
} }
leaf packet-received { leaf peer-interface {
type yang:counter32; type if:interface-ref;
description description
"Indicates the total number of packets received."; "The interface which is used for communication.";
} }
leaf packet-dropped { uses common-attributes {
type yang:counter32;
description description
"Indicates the number of packets dropped."; "Common attributes like port, version, min and
max poll.";
} }
} leaf reach {
type uint8;
grouping comman-attributes {
description
"NTP common attributes for configuration.";
leaf minpoll {
type ntp-minpoll;
description description
"The minimum poll interval used in this association."; "The reachability of the configured
server or peer.";
} }
leaf maxpoll { leaf unreach {
type ntp-maxpoll; type uint8;
description description
"The maximul poll interval used in this association."; "The unreachability of the configured
server or peer.";
} }
leaf port { leaf poll {
if-feature ntp-port; type uint8;
type uint16 { units seconds;
range "123 | 1025..max"; description
"The polling interval for current association";
}
leaf now {
type uint32;
units seconds;
description
"The time since the NTP packet was
not received or last synchronized.";
}
leaf offset {
type decimal64 {
fraction-digits 4;
} }
default "123";
description description
"Specify the port used to send NTP packets."; "The offset between the local clock
and the superior reference clock.";
} }
leaf version { leaf delay {
type ntp-version; type decimal64 {
fraction-digits 2;
}
description description
"NTP version."; "The delay between the local clock
and the superior reference clock.";
} }
} leaf dispersion {
type decimal64 {
grouping association-ref { fraction-digits 2;
description }
"Reference to NTP association mode"; description
leaf associations-address { "The dispersion between the local clock
type leafref { and the superior reference clock.";
path "/ntp:ntp/ntp:associations/ntp:address";
}
description
"Indicates the association address
which result in clock synchronization.";
} }
leaf associations-local-mode { leaf originate-time {
type leafref { type yang:date-and-time;
path "/ntp:ntp/ntp:associations/ntp:local-mode"; description
} "The packet originate timestamp(T1).";
description
"Indicates the association local-mode
which result in clock synchronization.";
} }
leaf associations-isConfigured { leaf receive-time {
type leafref { type yang:date-and-time;
path "/ntp:ntp/ntp:associations/" description
+ "ntp:isConfigured"; "The packet receive timestamp(T2).";
} }
leaf transmit-time {
type yang:date-and-time;
description
"The packet transmit timestamp(T3).";
}
leaf input-time {
type yang:date-and-time;
description
"The packet input timestamp(T4).";
}
container ntp-statistics {
description
"Per Peer packet send and receive statistics.";
uses statistics {
description description
"Indicates the association was configured or "NTP send and receive packet statistics.";
dynamic which result in clock synchronization."; }
} }
} }
/* Configuration data nodes */ container interfaces {
container ntp {
presence
"NTP is enable";
description description
"Configuration parameters for NTP."; "Configuration parameters for NTP interfaces.";
leaf port { list interface {
if-feature ntp-port; key "name";
type uint16 {
range "123 | 1025..max";
}
default "123";
description
"Specify the port used to send NTP packets.";
}
container refclock-master {
presence
"NTP master clock is enable";
description description
"Configures the device as NTP server."; "List of interfaces.";
leaf master-stratum { leaf name {
type ntp-stratum; type if:interface-ref;
default "16";
description description
"Stratum level from which NTP "The interface name.";
clients get their time synchronized.";
} }
}
container authentication { container broadcast-server {
description presence
"Configuration of authentication."; "NTP broadcast-server is configured";
leaf auth-enabled { description
type boolean; "Configuration of broadcast server.";
default false; leaf ttl {
type uint8;
description description
"Controls whether NTP authentication is enabled "Specifies the time to live (TTL) of a
or disabled on this device."; broadcast packet.";
} }
list trusted-keys { container authentication{
key "key-id";
description description
"List of keys trusted by NTP."; "Authentication.";
leaf key-id { uses authentication;
type leafref {
path "/ntp:ntp/ntp:authentication/"
+ "ntp:authentication-keys/ntp:key-id";
}
description
"The key trusted by NTP.";
}
} }
list authentication-keys { uses common-attributes {
key "key-id";
uses authentication-key;
description description
"List of authentication key."; "Common attribute like port, version, min and
max poll.";
} }
} }
container access-rules {
description
"Configuration of access rules.";
list access-rule {
key "access-mode";
description
"List of access rules.";
leaf access-mode {
type access-modes;
description
"NTP access mode.";
}
leaf acl {
type leafref {
path "/acl:acls/acl:acl/acl:name";
}
description
"NTP ACL.";
}
}
}
container clock-state {
config "false";
description
"Operational state of the NTP.";
container system-status {
description
"System status of NTP.";
leaf clock-state {
type ntp-clock-status;
mandatory true;
description "Indicates the state of system clock.";
}
leaf clock-stratum {
type ntp-stratum;
mandatory true;
description
"Indicates the stratum of the reference clock.";
}
leaf clock-refid {
type union {
type inet:ipv4-address;
type binary {
length "4";
}
type string {
length "4";
}
}
mandatory true;
description
"IPv4 address or first 32 bits of the MD5 hash of
the IPv6 address or reference clock of the peer to
which clock is synchronized.";
}
uses association-ref {
description
"Reference to Association mode";
}
leaf nominal-freq {
type decimal64 {
fraction-digits 4;
}
mandatory true;
description
"Indicates the nominal frequency of the
local clock, in Hz.";
}
leaf actual-freq {
type decimal64 {
fraction-digits 4;
}
mandatory true;
description
"Indicates the actual frequency of the
local clock, in Hz.";
}
leaf clock-precision {
type uint8;
mandatory true;
description
"Precision of the clock of this system
in Hz.(prec=2^(-n))";
}
leaf clock-offset {
type decimal64 {
fraction-digits 4;
}
description
"Offset of clock to synchronized peer,
in milliseconds.";
}
leaf root-delay {
type decimal64 {
fraction-digits 2;
}
description
"Total delay along path to root clock,
in milliseconds.";
}
leaf root-dispersion {
type decimal64 {
fraction-digits 2;
}
description
"Indicates the dispersion between the local clock
and the master reference clock, in milliseconds.";
}
leaf reference-time {
type yang:date-and-time;
description
"Indicates reference timestamp.";
}
leaf sync-state {
type ntp-sync-state;
mandatory true;
description
"Indicates the synchronization status of
the local clock.";
}
}
}
list unicast-configuration {
key "address type";
description
"list of unicast-configuration.";
leaf address {
type inet:host;
description
"The address of this association.";
}
leaf type {
type unicast-configuration-type;
description
"Type for this NTP configuration";
}
container authentication{
description
"Authentication type.";
uses authentication-type-param;
}
leaf prefer {
type boolean;
default "false";
description
"Whether this association is preferred.";
}
leaf burst {
type boolean;
default "false";
description
"Sends a series of packets instead of a single packet
within each synchronization interval to achieve faster
synchronization.";
}
leaf iburst {
type boolean;
default "false";
description
"Sends a series of packets instead of a single packet
within the initial synchronization interval to achieve
faster initial synchronization.";
}
leaf source {
type if:interface-ref;
description
"The interface whose ip address this association used
as source address.";
}
uses comman-attributes {
description
"Common attribute like port, version, min and max
poll.";
}
}
list associations {
key "address local-mode isConfigured";
config "false";
description
"list of NTP association.";
leaf address {
type inet:host;
description
"The address of this association.";
}
leaf local-mode {
type association-modes;
description
"Local mode for this NTP association.";
}
leaf isConfigured {
type boolean;
description
"Whether this association is configured or
dynamically learnt.";
}
leaf stratum {
type ntp-stratum;
description
"Indicates the stratum of the reference clock.";
}
leaf refid {
type union {
type inet:ipv4-address;
type binary {
length "4";
}
type string {
length "4";
}
}
description
"Reference clock type or address for the peer.";
}
leaf authentication{
type leafref {
path "/ntp:ntp/ntp:authentication/"
+ "ntp:authentication-keys/ntp:key-id";
}
description
"Authentication Key used for this association.";
}
leaf prefer {
type boolean;
default "false";
description
"Whether this association is preferred.";
}
leaf peer-interface {
type if:interface-ref;
description
"The interface which is used for communication.";
}
uses comman-attributes {
description
"Common attribute like port, version, min and
max poll.";
}
leaf reach {
type uint8;
description
"Indicates the reachability of the configured
server or peer.";
}
leaf unreach {
type uint8;
description
"Indicates the unreachability of the configured
server or peer.";
}
leaf poll {
type uint8;
description
"Indicates the polling interval for current,
in seconds.";
}
leaf now {
type uint32;
description
"Indicates the time since the NTP packet was
not received or last synchronized, in seconds.";
}
leaf offset {
type decimal64 {
fraction-digits 4;
}
description
"Indicates the offset between the local clock
and the superior reference clock.";
}
leaf delay {
type decimal64 {
fraction-digits 2;
}
description
"Indicates the delay between the local clock
and the superior reference clock.";
}
leaf dispersion {
type decimal64 {
fraction-digits 2;
}
description
"Indicates the dispersion between the local
clock and the superior reference clock.";
}
leaf originate-time {
type yang:date-and-time;
description
"Indicates packet originate timestamp(T1).";
}
leaf receive-time {
type yang:date-and-time;
description
"Indicates packet receive timestamp(T2).";
}
leaf transmit-time {
type yang:date-and-time;
description
"Indicates packet transmit timestamp(T3).";
}
leaf input-time {
type yang:date-and-time;
description
"Indicates packet input timestamp(T4).";
}
container ntp-statistics {
description
"Per Peer packet send and receive statistic.";
uses statistics {
description
"NTP send and receive packet statistic.";
}
}
}
container interfaces {
description
"Configuration parameters for NTP interfaces.";
list interface {
key "name";
description
"List of interfaces.";
leaf name {
type if:interface-ref;
description
"The interface name.";
}
container broadcast-server { container broadcast-client {
presence presence
"NTP broadcast-server is configured"; "NTP broadcast-client is configured";
description description
"Configuration of broadcast server."; "Configuration of broadcast-client.";
leaf ttl { }
type uint8;
description
"Specifies the time to live (TTL) of a
broadcast packet.";
}
container authentication{
description
"Authentication type.";
uses authentication-type-param;
}
uses comman-attributes {
description
"Common attribute like port, version, min and
max poll.";
}
}
container broadcast-client {
presence
"NTP broadcast-client is configured";
description
"Configuration of broadcast-client.";
}
list multicast-server { list multicast-server {
key "address"; key "address";
description description
"Configuration of multicast server."; "Configuration of multicast server.";
leaf address { leaf address {
type rt-types:ip-multicast-group-address; type rt-types:ip-multicast-group-address;
description description
"The IP address to send NTP multicast packets."; "The IP address to send NTP multicast packets.";
} }
leaf ttl { leaf ttl {
type uint8; type uint8;
description description
"Specifies the time to live (TTL) of a "Specifies the time to live (TTL) of a
multicast packet."; multicast packet.";
} }
container authentication{ container authentication{
description description
"Authentication type."; "Authentication.";
uses authentication-type-param; uses authentication;
} }
uses comman-attributes { uses common-attributes {
description description
"Common attribute like port, version, min and "Common attributes like port, version, min and
max poll."; max poll.";
} }
} }
list multicast-client { list multicast-client {
key "address"; key "address";
description description
"Configuration of multicast-client."; "Configuration of multicast-client.";
leaf address { leaf address {
type rt-types:ip-multicast-group-address; type rt-types:ip-multicast-group-address;
description description
"The IP address of the multicast group to "The IP address of the multicast group to
join."; join.";
} }
} }
list manycast-server { list manycast-server {
key "address"; key "address";
description description
"Configuration of manycast server."; "Configuration of manycast server.";
leaf address {
leaf address { type rt-types:ip-multicast-group-address;
type rt-types:ip-multicast-group-address; description
description "The multicast group IP address to receive
"The multicast group IP address to receive manycast client messages .";
manycast client messages ."; }
} reference
reference "RFC 5905";
"RFC 5905"; }
} list manycast-client {
list manycast-client { key "address";
key "address"; description
description "Configuration of manycast-client.";
"Configuration of manycast-client."; leaf address {
leaf address { type rt-types:ip-multicast-group-address;
type rt-types:ip-multicast-group-address; description
description "The group IP address that the manycast client
"The group IP address that the manycast client broadcasts the request message to.";
broadcasts the request message to."; }
} container authentication{
container authentication{ description
description "Authentication.";
"Authentication type."; uses authentication;
uses authentication-type-param; }
} leaf ttl {
leaf ttl { type uint8;
type uint8; description
description "Specifies the maximum time to live (TTL) for
"Specifies the maximum time to live (TTL) for the expanding ring search.";
the expanding ring search."; }
} leaf minclock {
leaf minclock { type uint8;
type uint8; description
description "The minimum manycast survivors in this
"The minimum manycast survivors in this association.";
association."; }
} leaf maxclock {
leaf maxclock { type uint8;
type uint8; description
description "The maximum manycast candidates in this
"The maximum manycast candidates in this association.";
association."; }
} leaf beacon {
leaf beacon { type uint8;
type uint8; description
description "The maximum interval between beacons in this
"The maximum interval between beacons in this association.";
association."; }
} uses common-attributes {
uses comman-attributes { description
description "Common attributes like port, version, min and
"Common attribute like port, version, min and
max poll."; max poll.";
} }
reference reference
"RFC 5905"; "RFC 5905";
} }
} }
} }
container ntp-statistics { container ntp-statistics {
config "false"; config "false";
description description
"Total NTP packet statistic."; "Total NTP packet statistics.";
uses statistics { uses statistics {
description description
"NTP send and receive packet statistic."; "NTP send and receive packet statistics.";
} }
} }
}
} }
}
<CODE ENDS>
<CODE ENDS> 8. Usage Example
6. Usage Example
6.1. Unicast association 8.1. Unicast association
Below is the example on how to configure a preferred unicast server Below is the example on how to configure a preferred unicast server
present at 192.0.2.1 running at port 1025 with authentication-key 10 present at 192.0.2.1 running at port 1025 with authentication-key 10
and version 4 and version 4
<edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<target> <target>
<running/> <running/>
</target> </target>
<config> <config>
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
skipping to change at page 31, line 19 skipping to change at page 33, line 19
<version>4</version> <version>4</version>
<stratum>9</stratum> <stratum>9</stratum>
<refid>20.1.1.1</refid> <refid>20.1.1.1</refid>
<reach>255</reach> <reach>255</reach>
<unreach>0</unreach> <unreach>0</unreach>
<poll>128</poll> <poll>128</poll>
<now>10</now> <now>10</now>
<offset>0.025</offset> <offset>0.025</offset>
<delay>0.5</delay> <delay>0.5</delay>
<dispersion>0.6</dispersion> <dispersion>0.6</dispersion>
<originate-time>10-10-2017 07:33:55.253 Z+05:30 <originate-time>10-10-2017 07:33:55.253 Z+05:30\
</originate-time> </originate-time>
<receive-time>10-10-2017 07:33:55.258 Z+05:30 <receive-time>10-10-2017 07:33:55.258 Z+05:30\
</receive-time> </receive-time>
<transmit-time>10-10-2017 07:33:55.300 Z+05:30 <transmit-time>10-10-2017 07:33:55.300 Z+05:30\
</transmit-time> </transmit-time>
<input-time>10-10-2017 07:33:55.305 Z+05:30 <input-time>10-10-2017 07:33:55.305 Z+05:30\
</input-time> </input-time>
<ntp-statistics> <ntp-statistics>
<packet-sent>20</packet-sent> <packet-sent>20</packet-sent>
<packet-sent-fail>0</packet-sent-fail> <packet-sent-fail>0</packet-sent-fail>
<packet-received>20</packet-received> <packet-received>20</packet-received>
<packet-dropped>0</packet-dropped> <packet-dropped>0</packet-dropped>
</ntp-statistics> </ntp-statistics>
</unicast-configuration> </unicast-configuration>
</ntp> </ntp>
</data> </data>
6.2. Refclock master 8.2. Refclock master
Below is the example on how to configure reference clock with stratum Below is the example on how to configure reference clock with stratum
8 8
<edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<target> <target>
<running/> <running/>
</target> </target>
<config> <config>
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<refclock-master> <refclock-master>
skipping to change at page 32, line 36 skipping to change at page 34, line 36
</get> </get>
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<refclock-master> <refclock-master>
<master-stratum>8</master-stratum> <master-stratum>8</master-stratum>
</refclock-master> </refclock-master>
</ntp> </ntp>
</data> </data>
6.3. Authentication configuration 8.3. Authentication configuration
Below is the example on how to enable authentication and configure Below is the example on how to enable authentication and configure
authentication key 10 with mode as md5 and password as abcd trusted authentication key 10 with mode as md5 and key as abcd
<edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<target> <target>
<running/> <running/>
</target> </target>
<config> <config>
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<authentication> <authentication>
<auth-enabled>true</auth-enabled> <auth-enabled>true</auth-enabled>
<authentication-keys> <authentication-keys>
<key-id>10</key-id> <key-id>10</key-id>
<algorithm>md5</algorithm> <algorithm>md5</algorithm>
<password>abcd</password> <key>abcd</key>
<istrusted>true</istrusted>
</authentication-keys> </authentication-keys>
</authentication> </authentication>
</ntp> </ntp>
</config> </config>
</edit-config> </edit-config>
Below is the example on how to get authentication related Below is the example on how to get authentication related
configuration configuration
<get> <get>
skipping to change at page 33, line 42 skipping to change at page 35, line 43
</get> </get>
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<authentication> <authentication>
<auth-enabled>false</auth-enabled> <auth-enabled>false</auth-enabled>
<trusted-keys/> <trusted-keys/>
<authentication-keys> <authentication-keys>
<key-id>10</key-id> <key-id>10</key-id>
<algorithm>md5</algorithm> <algorithm>md5</algorithm>
<password>abcd</password> <key>abcd</key>
<istrusted>true</istrusted>
</authentication-keys> </authentication-keys>
</authentication> </authentication>
</ntp> </ntp>
</data> </data>
6.4. Access configuration 8.4. Access configuration
Below is the example on how to configure acess type peer associated Below is the example on how to configure access mode "peer"
with acl 2000 associated with acl 2000.
<edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<target> <target>
<running/> <running/>
</target> </target>
<config> <config>
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<access-rules> <access-rules>
<access-rule> <access-rule>
<access-mode>peer</access-mode> <access-mode>peer</access-mode>
skipping to change at page 34, line 48 skipping to change at page 36, line 48
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<access-rules> <access-rules>
<access-rule> <access-rule>
<access-mode>peer</access-mode> <access-mode>peer</access-mode>
<acl>2000</acl> <acl>2000</acl>
</access-rule> </access-rule>
</access-rules> </access-rules>
</ntp> </ntp>
</data> </data>
6.5. Multicast configuration 8.5. Multicast configuration
Below is the example on how to configure multicast-server with Below is the example on how to configure multicast-server with
address as "224.1.1.1", port as 1025 and authentication keyid as 10 address as "224.1.1.1", port as 1025 and authentication keyid as 10
<edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<target> <target>
<running/> <running/>
</target> </target>
<config> <config>
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<interfaces> <interfaces>
skipping to change at page 38, line 5 skipping to change at page 40, line 5
<interface> <interface>
<name>Ethernet3/0/0</name> <name>Ethernet3/0/0</name>
<multicast-client> <multicast-client>
<address>224.1.1.1</address> <address>224.1.1.1</address>
</multicast-client> </multicast-client>
</interface> </interface>
</interfaces> </interfaces>
</ntp> </ntp>
</data> </data>
6.6. Manycast configuration 8.6. Manycast configuration
Below is the example on how to configure manycast-client with address Below is the example on how to configure manycast-client with address
as "224.1.1.1", port as 1025 and authentication keyid as 10 as "224.1.1.1", port as 1025 and authentication keyid as 10
<edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <edit-config xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<target> <target>
<running/> <running/>
</target> </target>
<config> <config>
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
skipping to change at page 41, line 5 skipping to change at page 43, line 5
<interface> <interface>
<name>Ethernet3/0/0</name> <name>Ethernet3/0/0</name>
<manycast-server> <manycast-server>
<address>224.1.1.1</address> <address>224.1.1.1</address>
</manycast-server> </manycast-server>
</interface> </interface>
</interfaces> </interfaces>
</ntp> </ntp>
</data> </data>
6.7. Clock state 8.7. Clock state
Below is the example on how to get clock current state Below is the example on how to get clock current state
<get> <get>
<filter type="subtree"> <filter type="subtree">
<sys:ntp xmlns:sys="urn:ietf:params:xml:ns:yang:ietf-ntp"> <sys:ntp xmlns:sys="urn:ietf:params:xml:ns:yang:ietf-ntp">
<sys:clock-state> <sys:clock-state>
</sys:clock-state> </sys:clock-state>
</sys:ntp> </sys:ntp>
</filter> </filter>
</get> </get>
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<clock-state> <clock-state>
<system-status> <system-status>
<clock-state>synchronized</clock-state> <clock-state>synchronized</clock-state>
<clock-stratum>7</clock-stratum> <clock-stratum>7</clock-stratum>
<clock-refid>192.0.2.1</clock-refid> <clock-refid>192.0.2.1</clock-refid>
<associations-address>192.0.2.1 <associations-address>192.0.2.1\
</associations-address> </associations-address>
<associations-local-mode>client <associations-local-mode>client\
</associations-local-mode> </associations-local-mode>
<associations-isConfigured>yes <associations-isconfigured>yes\
</associations-isConfigured> </associations-isconfigured>
<nominal-freq>100.0</nominal-freq> <nominal-freq>100.0</nominal-freq>
<actual-freq>100.0</actual-freq> <actual-freq>100.0</actual-freq>
<clock-precision>18</clock-precision> <clock-precision>18</clock-precision>
<clock-offset>0.025</clock-offset> <clock-offset>0.025</clock-offset>
<root-delay>0.5</root-delay> <root-delay>0.5</root-delay>
<root-dispersion>0.8</root-dispersion> <root-dispersion>0.8</root-dispersion>
<reference-time>10-10-2017 07:33:55.258 Z+05:30 <reference-time>10-10-2017 07:33:55.258 Z+05:30\
</reference-time> </reference-time>
<sync-state>clock-synchronized</sync-state> <sync-state>clock-synchronized</sync-state>
</system-status> </system-status>
</clock-state> </clock-state>
</ntp> </ntp>
</data> </data>
6.8. Get all association 8.8. Get all association
Below is the example on how to get all association present Below is the example on how to get all association present
<get> <get>
<filter type="subtree"> <filter type="subtree">
<sys:ntp xmlns:sys="urn:ietf:params:xml:ns:yang:ietf-ntp"> <sys:ntp xmlns:sys="urn:ietf:params:xml:ns:yang:ietf-ntp">
<sys:associations> <sys:associations>
</sys:associations> </sys:associations>
</sys:ntp> </sys:ntp>
</filter> </filter>
</get> </get>
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"> <data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<associations> <associations>
<address>192.0.2.1</address> <address>192.0.2.1</address>
<stratum>9</stratum> <stratum>9</stratum>
<refid>20.1.1.1</refid> <refid>20.1.1.1</refid>
<local-mode>client</local-mode> <local-mode>client</local-mode>
<isConfigured>true</isConfigured> <isconfigured>true</isconfigured>
<authentication-key>10</authentication-key> <authentication-key>10</authentication-key>
<prefer>true</prefer> <prefer>true</prefer>
<peer-interface>Ethernet3/0/0</peer-interface> <peer-interface>Ethernet3/0/0</peer-interface>
<minpoll>6</minpoll> <minpoll>6</minpoll>
<maxpoll>10</maxpoll> <maxpoll>10</maxpoll>
<port>1025</port> <port>1025</port>
<version>4</version> <version>4</version>
<reach>255</reach> <reach>255</reach>
<unreach>0</unreach> <unreach>0</unreach>
<poll>128</poll> <poll>128</poll>
<now>10</now> <now>10</now>
<offset>0.025</offset> <offset>0.025</offset>
<delay>0.5</delay> <delay>0.5</delay>
<dispersion>0.6</dispersion> <dispersion>0.6</dispersion>
<originate-time>10-10-2017 07:33:55.253 Z+05:30 <originate-time>10-10-2017 07:33:55.253 Z+05:30\
</originate-time> </originate-time>
<receive-time>10-10-2017 07:33:55.258 Z+05:30 <receive-time>10-10-2017 07:33:55.258 Z+05:30\
</receive-time> </receive-time>
<transmit-time>10-10-2017 07:33:55.300 Z+05:30 <transmit-time>10-10-2017 07:33:55.300 Z+05:30\
</transmit-time> </transmit-time>
<input-time>10-10-2017 07:33:55.305 Z+05:30 <input-time>10-10-2017 07:33:55.305 Z+05:30\
</input-time> </input-time>
<ntp-statistics> <ntp-statistics>
<packet-sent>20</packet-sent> <packet-sent>20</packet-sent>
<packet-sent-fail>0</packet-sent-fail> <packet-sent-fail>0</packet-sent-fail>
<packet-received>20</packet-received> <packet-received>20</packet-received>
<packet-dropped>0</packet-dropped> <packet-dropped>0</packet-dropped>
</ntp-statistics> </ntp-statistics>
</associations> </associations>
</ntp> </ntp>
</data> </data>
6.9. Global statistic 8.9. Global statistic
Below is the example on how to get clock current state Below is the example on how to get clock current state
<get> <get>
<filter type="subtree"> <filter type="subtree">
<sys:ntp xmlns:sys="urn:ietf:params:xml:ns:yang:ietf-ntp"> <sys:ntp xmlns:sys="urn:ietf:params:xml:ns:yang:ietf-ntp">
<sys:ntp-statistics> <sys:ntp-statistics>
</sys:ntp-statistics> </sys:ntp-statistics>
</sys:ntp> </sys:ntp>
</filter> </filter>
skipping to change at page 43, line 29 skipping to change at page 45, line 29
<ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp"> <ntp xmlns="urn:ietf:params:xml:ns:yang:ietf-ntp">
<ntp-statistics> <ntp-statistics>
<packet-sent>30</packet-sent> <packet-sent>30</packet-sent>
<packet-sent-fail>5</packet-sent-fail> <packet-sent-fail>5</packet-sent-fail>
<packet-received>20</packet-received> <packet-received>20</packet-received>
<packet-dropped>2</packet-dropped> <packet-dropped>2</packet-dropped>
</ntp-statistics> </ntp-statistics>
</ntp> </ntp>
</data> </data>
7. IANA Considerations 9. IANA Considerations
This document registers a URI in the "IETF XML Registry" [RFC3688]. This document registers a URI in the "IETF XML Registry" [RFC3688].
Following the format in RFC 3688, the following registration has been Following the format in RFC 3688, the following registration has been
made. made.
URI: urn:ietf:params:xml:ns:yang:ietf-ntp URI: urn:ietf:params:xml:ns:yang:ietf-ntp
Registrant Contact: The NETMOD WG of the IETF. Registrant Contact: The NETMOD WG of the IETF.
XML: N/A; the requested URI is an XML namespace. XML: N/A; the requested URI is an XML namespace.
skipping to change at page 44, line 5 skipping to change at page 46, line 5
registry [RFC6020]. registry [RFC6020].
Name: ietf-ntp Name: ietf-ntp
Namespace: urn:ietf:params:xml:ns:yang:ietf-ntp Namespace: urn:ietf:params:xml:ns:yang:ietf-ntp
Prefix: ntp Prefix: ntp
Reference: RFC XXXX Reference: RFC XXXX
8. Security Considerations 10. Security Considerations
The YANG module specified in this document defines a schema for data The YANG module specified in this document defines a schema for data
that is designed to be accessed via network management protocols such that is designed to be accessed via network management protocols such
as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer
is the secure transport layer, and the mandatory-to-implement secure is the secure transport layer, and the mandatory-to-implement secure
transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer
is HTTPS, and the mandatory-to-implement secure transport is TLS is HTTPS, and the mandatory-to-implement secure transport is TLS
[RFC5246]. [RFC8446].
The NETCONF access control model [RFC8341] provides the means to The NETCONF access control model [RFC8341] provides the means to
restrict access for particular NETCONF or RESTCONF users to a restrict access for particular NETCONF or RESTCONF users to a
preconfigured subset of all available NETCONF or RESTCONF protocol preconfigured subset of all available NETCONF or RESTCONF protocol
operations and content. operations and content.
There are a number of data nodes defined in this YANG module that are There are a number of data nodes defined in this YANG module that are
writable/creatable/deletable (i.e., config true, which is the writable/creatable/deletable (i.e., config true, which is the
default). These data nodes may be considered sensitive or vulnerable default). These data nodes may be considered sensitive or vulnerable
in some network environments. Write operations (e.g., edit-config) in some network environments. Write operations (e.g., edit-config)
to these data nodes without proper protection can have a negative to these data nodes without proper protection can have a negative
effect on network operations. These are the subtrees and data nodes effect on network operations. These are the subtrees and data nodes
and their sensitivity/vulnerability: and their sensitivity/vulnerability:
/ntp/port - This data node specify the port number to be used to /ntp/port - This data node specify the port number to be used to
send NTP packets. Unexpected changes could lead to disruption send NTP packets. Unexpected changes could lead to disruption
and/or network misbehavior. and/or network misbehavior.
/ntp/authentication and /ntp/access-rules - The entries in the /ntp/authentication and /ntp/access-rules - The entries in the
list include the authentication and access control configurations. list include the authentication and access control configurations.
Car should be taken while setting these parameters. Care should be taken while setting these parameters.
/ntp/unicast-configuration - The entries in the list include all /ntp/unicast-configuration - The entries in the list include all
unicast configurations (server or peer mode), and indirectly unicast configurations (server or peer mode), and indirectly
creates or modify the NTP associations. Unexpected changes could creates or modify the NTP associations. Unexpected changes could
lead to disruption and/or network misbehavior. lead to disruption and/or network misbehavior.
/ntp/interfaces/interface - The entries in the list inclide all /ntp/interfaces/interface - The entries in the list inclide all
per-interface configurations related to broadcast, multicast and per-interface configurations related to broadcast, multicast and
manycast mode, and indirectly creates or modify the NTP manycast mode, and indirectly creates or modify the NTP
associations. Unexpected changes could lead to disruption and/or associations. Unexpected changes could lead to disruption and/or
skipping to change at page 45, line 9 skipping to change at page 47, line 9
Some of the readable data nodes in this YANG module may be considered Some of the readable data nodes in this YANG module may be considered
sensitive or vulnerable in some network environments. It is thus sensitive or vulnerable in some network environments. It is thus
important to control read access (e.g., via get, get-config, or important to control read access (e.g., via get, get-config, or
notification) to these data nodes. These are the subtrees and data notification) to these data nodes. These are the subtrees and data
nodes and their sensitivity/vulnerability: nodes and their sensitivity/vulnerability:
/ntp/associations - The entries in the list includes all active /ntp/associations - The entries in the list includes all active
NTP associations of all modes. Unauthorized access to this needs NTP associations of all modes. Unauthorized access to this needs
to be curtailed. to be curtailed.
9. Acknowledgments 11. Acknowledgments
The authors would like to express their thanks to Sladjana Zoric, The authors would like to express their thanks to Sladjana Zoric,
Danny Mayer, Harlan Stenn, Ulrich Windl, Miroslav Lichvar, and Danny Mayer, Harlan Stenn, Ulrich Windl, Miroslav Lichvar, and
Maurice Angermann for their review and suggestions. Maurice Angermann for their review and suggestions.
10. References 12. References
10.1. Normative References 12.1. Normative References
[I-D.ietf-netmod-acl-model] [I-D.ietf-netmod-acl-model]
Jethanandani, M., Huang, L., Agarwal, S., and D. Blair, Jethanandani, M., Agarwal, S., Huang, L., and D. Blair,
"Network Access Control List (ACL) YANG Data Model", "Network Access Control List (ACL) YANG Data Model",
draft-ietf-netmod-acl-model-19 (work in progress), April draft-ietf-netmod-acl-model-20 (work in progress), October
2018. 2018.
[RFC1305] Mills, D., "Network Time Protocol (Version 3)
Specification, Implementation and Analysis", RFC 1305,
DOI 10.17487/RFC1305, March 1992,
<https://www.rfc-editor.org/info/rfc1305>.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997, DOI 10.17487/RFC2119, March 1997,
<https://www.rfc-editor.org/info/rfc2119>. <https://www.rfc-editor.org/info/rfc2119>.
[RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688,
DOI 10.17487/RFC3688, January 2004, DOI 10.17487/RFC3688, January 2004,
<https://www.rfc-editor.org/info/rfc3688>. <https://www.rfc-editor.org/info/rfc3688>.
[RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security
(TLS) Protocol Version 1.2", RFC 5246,
DOI 10.17487/RFC5246, August 2008,
<https://www.rfc-editor.org/info/rfc5246>.
[RFC5905] Mills, D., Martin, J., Ed., Burbank, J., and W. Kasch, [RFC5905] Mills, D., Martin, J., Ed., Burbank, J., and W. Kasch,
"Network Time Protocol Version 4: Protocol and Algorithms "Network Time Protocol Version 4: Protocol and Algorithms
Specification", RFC 5905, DOI 10.17487/RFC5905, June 2010, Specification", RFC 5905, DOI 10.17487/RFC5905, June 2010,
<https://www.rfc-editor.org/info/rfc5905>. <https://www.rfc-editor.org/info/rfc5905>.
[RFC5907] Gerstung, H., Elliott, C., and B. Haberman, Ed., [RFC5907] Gerstung, H., Elliott, C., and B. Haberman, Ed.,
"Definitions of Managed Objects for Network Time Protocol "Definitions of Managed Objects for Network Time Protocol
Version 4 (NTPv4)", RFC 5907, DOI 10.17487/RFC5907, June Version 4 (NTPv4)", RFC 5907, DOI 10.17487/RFC5907, June
2010, <https://www.rfc-editor.org/info/rfc5907>. 2010, <https://www.rfc-editor.org/info/rfc5907>.
skipping to change at page 46, line 18 skipping to change at page 48, line 18
<https://www.rfc-editor.org/info/rfc6241>. <https://www.rfc-editor.org/info/rfc6241>.
[RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure
Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011,
<https://www.rfc-editor.org/info/rfc6242>. <https://www.rfc-editor.org/info/rfc6242>.
[RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types",
RFC 6991, DOI 10.17487/RFC6991, July 2013, RFC 6991, DOI 10.17487/RFC6991, July 2013,
<https://www.rfc-editor.org/info/rfc6991>. <https://www.rfc-editor.org/info/rfc6991>.
[RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language",
RFC 7950, DOI 10.17487/RFC7950, August 2016,
<https://www.rfc-editor.org/info/rfc7950>.
[RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF
Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017,
<https://www.rfc-editor.org/info/rfc8040>. <https://www.rfc-editor.org/info/rfc8040>.
[RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
May 2017, <https://www.rfc-editor.org/info/rfc8174>. May 2017, <https://www.rfc-editor.org/info/rfc8174>.
[RFC8177] Lindem, A., Ed., Qu, Y., Yeung, D., Chen, I., and J. [RFC8177] Lindem, A., Ed., Qu, Y., Yeung, D., Chen, I., and J.
Zhang, "YANG Data Model for Key Chains", RFC 8177, Zhang, "YANG Data Model for Key Chains", RFC 8177,
skipping to change at page 47, line 5 skipping to change at page 49, line 5
[RFC8341] Bierman, A. and M. Bjorklund, "Network Configuration [RFC8341] Bierman, A. and M. Bjorklund, "Network Configuration
Access Control Model", STD 91, RFC 8341, Access Control Model", STD 91, RFC 8341,
DOI 10.17487/RFC8341, March 2018, DOI 10.17487/RFC8341, March 2018,
<https://www.rfc-editor.org/info/rfc8341>. <https://www.rfc-editor.org/info/rfc8341>.
[RFC8343] Bjorklund, M., "A YANG Data Model for Interface [RFC8343] Bjorklund, M., "A YANG Data Model for Interface
Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, Management", RFC 8343, DOI 10.17487/RFC8343, March 2018,
<https://www.rfc-editor.org/info/rfc8343>. <https://www.rfc-editor.org/info/rfc8343>.
10.2. Informative References [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol
Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018,
<https://www.rfc-editor.org/info/rfc8446>.
12.2. Informative References
[RFC7317] Bierman, A. and M. Bjorklund, "A YANG Data Model for [RFC7317] Bierman, A. and M. Bjorklund, "A YANG Data Model for
System Management", RFC 7317, DOI 10.17487/RFC7317, August System Management", RFC 7317, DOI 10.17487/RFC7317, August
2014, <https://www.rfc-editor.org/info/rfc7317>. 2014, <https://www.rfc-editor.org/info/rfc7317>.
[RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., [RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K.,
and R. Wilton, "Network Management Datastore Architecture and R. Wilton, "Network Management Datastore Architecture
(NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018, (NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018,
<https://www.rfc-editor.org/info/rfc8342>. <https://www.rfc-editor.org/info/rfc8342>.
Authors' Addresses Authors' Addresses
Nan Wu Nan Wu
Huawei Huawei
Huawei Bld., No.156 Beiqing Rd. Huawei Bld., No.156 Beiqing Rd.
Beijing 100095 Beijing 100095
China China
Email: eric.wu@huawei.com Email: eric.wu@huawei.com
Dhruv Dhody
Huawei
Divyashree Techno Park, Whitefield
Bangalore, Kanataka 560066
India
Email: dhruv.ietf@gmail.com
Ankit kumar Sinha
RtBrick Inc.
Bangalore, Kanataka
India
Email: ankit.ietf@gmail.com
Anil Kumar S N Anil Kumar S N
RtBrick Inc. RtBrick Inc.
Bangalore, Kanataka Bangalore, Kanataka
India India
Email: anil.ietf@gmail.com Email: anil.ietf@gmail.com
Yi Zhao Yi Zhao
Ericsson Ericsson
China Digital Kingdom Bld., No.1 WangJing North Rd. China Digital Kingdom Bld., No.1 WangJing North Rd.
Beijing 100102 Beijing 100102
China China
Email: yi.z.zhao@ericsson.com Email: yi.z.zhao@ericsson.com
Dhruv Dhody
Huawei
Divyashree Techno Park, Whitefield
Bangalore, Kanataka 560066
India
Email: dhruv.ietf@gmail.com
Ankit kumar Sinha
RtBrick Inc.
Bangalore, Kanataka
India
Email: ankit.ietf@gmail.com
 End of changes. 180 change blocks. 
1058 lines changed or deleted 1182 lines changed or added

This html diff was produced by rfcdiff 1.47. The latest version is available from http://tools.ietf.org/tools/rfcdiff/