Internet Engineering Task Force Y. Huang Internet Draft Ericsson Intended status: Standards Track July 29, 2016 Expires: January 2017 Yang Data Model for L2TP Protocol draft-huang-l2tpext-l2tp-yang-00.txt Abstract This document defines a YANG data model that can be used to configure and manage L2TP. 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), its areas, and its working groups. Note that other groups may also distribute working documents as Internet- Drafts. 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." The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html This Internet-Draft will expire on January 29, 2009. Copyright Notice Copyright (c) 2016 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 Huang Expires January 29, 2017 [Page 1] Internet-Draft L2TP Yang Data Model July 2016 (http://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Table of Contents 1. Introduction ................................................ 2 1.1. Terminology ............................................ 2 1.2. Tree Diagrams .......................................... 3 2. Design of Data Model......................................... 3 2.1. Overview ............................................... 4 2.2. L2TP Group ............................................. 4 2.3. L2TP Peer .............................................. 5 3. L2TP YANG Module ............................................ 6 4. Security Considerations..................................... 25 5. IANA Considerations ........................................ 26 6. Normative References........................................ 26 1. Introduction This document defines a YANG [RFC6020] data model for the management of L2TP protocol. This data model includes configuration data and state data (status information and counters for the collection of statistics). 1.1. Terminology The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119]. The following terms are used within this document: The following terms are defined in [RFC6241] and are not redefined here: o client Huang Expires January 29, 2017 [Page 2] Internet-Draft L2TP Yang Data Model July 2016 o configuration data o server o state data The following terms are defined in [RFC6020] and are not redefined here: o augment o data model o data node o presence container 1.2. Tree Diagrams A simplified graphical representation of the data model is used in this document. The meaning of the symbols in these diagrams is as follows: o Brackets "[" and "]" enclose list keys. o Abbreviations before data node names: "rw" means configuration (read-write), and "ro" means state data (read-only). o Symbols after data node names: "?" means an optional node, "!" means a presence container, and "*" denotes a list and leaf-list. o Parentheses enclose choice and case nodes, and case nodes are also marked with a colon (":"). o Ellipsis ("...") stands for contents of subtrees that are not shown. 2. Design of Data Model The goal of this document is to define a data model that provides a common user interface to the L2TP protocol. There is very information that is designated as "mandatory", providing freedom for vendors to adapt this data model to their respective product implementations. Huang Expires January 29, 2017 [Page 3] Internet-Draft L2TP Yang Data Model July 2016 2.1. Overview The L2TP YANG module defined in this document has all the common building blocks for the L2TP protocol. module: ietf-l2tp +--rw l2tp | . | . | +--rw l2tp-group* [name] | | . | | . | +--rw l2tp-peer* [name] | . | . +--ro l2tp-state +--ro l2tp-summary* [peer-name] | . | . +--ro l2tp-group* [name] | . | . +--ro l2tp-peer* [remote-name] . . +--ro tunnel* [local-id] . . +--ro session* [local-id] . . 2.2. L2TP Group L2TP Group is a group of L2TP tunnels to L2TP network servers (LNSs), among which Point-to-Point Protocol (PPP) sessions are parceled out. module: ietf-l2tp +--rw l2tp . . +--rw l2tp-group* [name] | +--rw name string | +--rw (algrithm)? | | +--:(load-balance) | | | +--rw load-balance? empty | | +--:(priority) Huang Expires January 29, 2017 [Page 4] Internet-Draft L2TP Yang Data Model July 2016 | | | +--rw priority? empty | | +--:(weighted-round-robin) | | +--rw weighted-round-robin? empty | +--rw deadtime? uint16 | +--rw descripton? string | +--rw domain? string | +--rw peers* [peer-name] | +--rw peer-name -> ../../../l2tp-peer/name | +--rw preference? uint16 | +--rw weight? uint16 2.3. L2TP Peer L2TP Peer is either an L2TP access concentrator (LAC) or L2TP network server (LNS). module: ietf-l2tp +--rw l2tp . . +--rw l2tp-group* [name] . . +--rw l2tp-peer* [name] +--rw name string +--rw (media)? | +--:(udp-ip) | +--rw (remote)? | | +--:(dns) | | | +--rw dns? string | | +--:(ip) | | +--rw ip? inet:ipv4-address | +--rw local-ip-addr? inet:ipv4-address +--rw description? string +--rw cleanup-timer? uint16 +--rw dnis? dnis-state-type +--rw domain? string +--rw (tunnel-type)? | +--:(lac-only) | +--:(lns-only) +--rw hello-timer? uint16 +--rw local-name? string +--rw max-sessions? uint16 +--rw max-tunnels? uint16 +--rw message-reordering | +--rw message-queue? uint8 Huang Expires January 29, 2017 [Page 5] Internet-Draft L2TP Yang Data Model July 2016 +--rw retry? uint8 +--rw session-auth +--rw chap? chap-state-type +--rw pap? pap-state-type +--rw timeout? uint8 +--rw tunnel-auth? string +--rw tunnel-window? uint16 3. L2TP YANG Module file "ietf-l2tp@2016-07-29.yang" module ietf-l2tp { yang-version "1"; namespace "urn:ietf:params:xml:ns:yang:ietf-l2tp"; prefix "l2tp"; import ietf-inet-types { prefix "inet"; } import ietf-yang-types { prefix yang; } organization "Ericsson (China) Communications Company Ltd. Ericsson Tower, No. 5 Lize East Street, Chaoyang District Beijing 100102, P.R. China"; contact "Editor: Yang Huang "; description "This YANG module defines the generic configuration and operational state for the L2TP protocol common to all vendor implementations. It is intended that the module will be extended by vendors to define vendor-specific L2TP configuration parameters and policies."; revision 2016-07-29 { description "Initial revision."; reference "RFC XXXX: A YANG Data Model for L2TP."; Huang Expires January 29, 2017 [Page 6] Internet-Draft L2TP Yang Data Model July 2016 } typedef dnis-state-type { type enumeration { enum enable { description "enable dnis "; } enum disable { description "disable dnis "; } } description "Dnis state type"; } typedef chap-state-type { type enumeration { enum enable { description "enable chap"; } enum disable { description "disable chap"; } } description "CHAP state"; } typedef pap-state-type { type enumeration { enum enable { description "enable pap"; } enum disable { description "disable pap"; } } description "PAP state"; } container l2tp { description "l2tp configuration parameters."; leaf accm { type empty; description "ACCM for LNS only"; } Huang Expires January 29, 2017 [Page 7] Internet-Draft L2TP Yang Data Model July 2016 leaf clear-radius-peer { type uint16 { range "5..300"; } units minute; description "Time to cleanup RADIUS peers when no sessions are active"; } leaf deadtime { type uint16 { range "1..100"; } units minute; default 2; description "Time to ignore a non-responsive peer"; } container fragment { description "Fragmentation algorithm"; choice fragment-type { case l2tp-packet { leaf l2tp-packet { type empty; description "Fragment l2tp packet"; } } case user-packet { leaf user-packet { type empty; description "Fragment user packet"; } } default l2tp-packet; description "Fragmentation algorithm type"; } } leaf proxy-auth { type empty; description "Enable proxy authentication"; } Huang Expires January 29, 2017 [Page 8] Internet-Draft L2TP Yang Data Model July 2016 container radius-peer { description "Radius attribute configurations"; leaf use-server-auth-id { type empty; description "Use server-auth-id as peer name if assignment-id not present"; } } leaf reconfig-ses { type empty; description "Enable reconfiguration of sessions on peer reconfig"; } container renegotiate { description "LNS PPP renegotiation"; leaf mru { type uint32 { range "256..12800"; } description "Renegotiate MRU"; } container lcp { description "LCP renegotiation"; choice lcp { case always { leaf always { type empty; description "Always renegotiate LCP"; } } case never { leaf never { type empty; description "Never renegotiate LCP"; } } case on-mismatch { leaf on-mismatch { type empty; description "Renegotiate LCP only on mismatch"; } } default on-mismatch; Huang Expires January 29, 2017 [Page 9] Internet-Draft L2TP Yang Data Model July 2016 description "LCP renegotiation"; } } } leaf strict-deadtime { type empty; description "If strict deadtime is enabled, no connection attempt is made until the deadtime for at least one candidate peer has expired, even if all L2TP peers are labeled dead."; } list l2tp-group { key name; description "Configure an L2TP group"; leaf name { type string; description "L2TP group name"; } choice algrithm { description "Algorithm for distributing sessions among peers"; case load-balance { leaf load-balance { type empty; description "Distribute sessions among peers equally"; } } case priority { leaf priority { type empty; description "Distribute sessions among peers by priority"; } } case weighted-round-robin { leaf weighted-round-robin { type empty; description "Distribute sessions among peers by weighted round robin"; } } Huang Expires January 29, 2017 [Page 10] Internet-Draft L2TP Yang Data Model July 2016 } leaf deadtime { type uint16 { range "1..300"; } units minute; default 2; description "Time to ignore a peer that is not responding"; } leaf description { type string; description "Add descriptive text for this group"; } leaf domain { type string; description "L2TP group domain name"; } list peers { key "peer-name"; description "L2TP peers in this group"; leaf peer-name { type leafref{ path "../../../l2tp-peer/name"; } description "L2TP peer name"; } leaf preference { type uint16 { range "1..100"; } description "Set the priority of the peer for priority algorithm"; } leaf weight { type uint16 { range "1..100"; } description Huang Expires January 29, 2017 [Page 11] Internet-Draft L2TP Yang Data Model July 2016 "Set the weight of the peer for weighted round robin algorithm"; } } } list l2tp-peer { key name; description "Configure an L2TP tunnel"; leaf name { type string { length "1..64"; } description "The remote peer name"; } choice media { case udp-ip { description "Tunnel to peer via UDP"; choice remote { description "Set the remote peer identity"; case dns { leaf dns { type string; description "Set the DNS name of the remote peer"; } } case ip { leaf ip { type inet:ipv4-address; description "Tunnel peer IP address"; } } } leaf local-ip-addr { type inet:ipv4-address; description "Set the Tunnel local IP address"; } } default udp-ip; description "Set the tunnel media"; } leaf description { type string; Huang Expires January 29, 2017 [Page 12] Internet-Draft L2TP Yang Data Model July 2016 description "Add descriptive text for this peer"; } leaf cleanup-timer { type uint16 { range "1..28800"; } units seconds; description "Clear tunnels when peer has no sessions"; } leaf dnis { type dnis-state-type; default disable; description "Directs the Layer 2 Tunneling Protocol (L2TP) process to transmit the Calling-Number AVP (22) Incoming-Call- Requests (ICRQs)."; } leaf domain { type string; description "Set tunnel domain name"; } choice tunnel-type { case lac-only { description "LAC functionality only"; } case lns-only { description "LNS functionality only"; } default lac-only; description "Tunnel functionality"; } leaf hello-timer { type uint16 { range "30..3600"; } units seconds; description "Set hello control message timer"; } leaf local-name { type string; description "Set tunnel local name"; } Huang Expires January 29, 2017 [Page 13] Internet-Draft L2TP Yang Data Model July 2016 leaf max-sessions { type uint16 { range "1..65535"; } description "Set maximum number of sessions per tunnel"; } leaf max-tunnels { type uint16 { range "1..64000"; } description "Set maximum number of tunnels"; } container message-reordering { description "Accept out of order control messages"; leaf message-queue { type uint8 { range "1..32"; } description "Queue size to store out-of-order control messages"; } } leaf retry { type uint8 { range "1..100"; } default 5; description "Set tunnel control message retransmit count"; } container session-auth { description "PPP authentication type on LNS"; leaf chap { type chap-state-type; default enable; description "Use CHAP authentication protocol"; } leaf pap { type pap-state-type; default enable; description "Use PAP authentication protocol"; Huang Expires January 29, 2017 [Page 14] Internet-Draft L2TP Yang Data Model July 2016 } leaf timeout { type uint8 { range "1..30"; } default 3; description "Set tunnel control message timeout"; } leaf tunnel-auth { type string; description "Specify key (shared secret) to use with this peer"; } leaf tunnel-window { type uint16 { range "1..2000"; } default 8; description "Set tunnel control channel window size"; } } } } container l2tp-state { config false; description "Data nodes for the operational state of L2TP."; list l2tp-summary { key peer-name; description "L2TP summary information"; leaf peer-name { type string; description "The tunnel remote peer name"; } leaf local-name { type string; description "The tunnel local name"; } Huang Expires January 29, 2017 [Page 15] Internet-Draft L2TP Yang Data Model July 2016 leaf tunnel-count { type uint16 { range "1..65534"; } description "Number of active tunnel"; } leaf session-count { type uint16 { range "1..65534"; } description "Number of active session"; } } list l2tp-group { key name; description "L2TP group status information"; leaf name { type string; description "L2TP group name"; } choice algrithm { description "Algorithm for distributing sessions among peers"; case load-balance { leaf load-balance { type empty; description "Distribute sessions among peers equally"; } } case priority { leaf priority { type empty; description "Distribute sessions among peers by priority"; } } case weighted-round-robin { leaf weighted-round-robin { type empty; description "Distribute sessions among peers by weighted round robin"; Huang Expires January 29, 2017 [Page 16] Internet-Draft L2TP Yang Data Model July 2016 } } } leaf deadtime { type uint16 { range "1..300"; } units minute; description "Time to ignore a peer that is not responding"; } leaf domain { type string; description "L2TP group domain name"; } list peers { key "peer-name"; description "L2TP peers in this group"; leaf peer-name { type string; description "L2TP peer name"; } leaf preference { type uint16 { range "1..100"; } description "The priority of the peer for priority algorithm"; } leaf weight { type uint16 { range "1..100"; } description "The weight of the peer for weighted round robin algorithm"; } leaf status { type enumeration { Huang Expires January 29, 2017 [Page 17] Internet-Draft L2TP Yang Data Model July 2016 enum "PROBE" { description "PROBE"; } enum "ALIVE" { description "ALIVE"; } enum "DEAD"{ description "DEAD"; } } description "Status of this peer"; } leaf session-count { type uint16 { range "1..65534"; } description "Number of active session"; } } leaf last-use { type union { type enumeration { enum "Never" { description "Never"; } enum "Forever" { description "Forever"; } } type yang:date-and-time; } description "The interval between now and last used time of this peer"; } } list l2tp-peer { key remote-name; description "L2TP peer status information"; leaf remote-name { type string { length "1..64"; Huang Expires January 29, 2017 [Page 18] Internet-Draft L2TP Yang Data Model July 2016 } description "The peer remote name"; } leaf local-name { type string; description "The peer local name"; } leaf admin-state { type enumeration { enum "Down" { description "Down"; } enum "UP" { description "UP"; } } description "The desired state of the peer"; } leaf vendor { type string; description "The verdor of this peer"; } leaf description { type string; description "Add descriptive text for this peer"; } leaf cleanup-timer { type uint16 { range "1..28800"; } units seconds; description "Clear tunnels when peer has no sessions"; } leaf dnis { type dnis-state-type; default disable; description "Directs the Layer 2 Tunneling Protocol (L2TP) process to transmit the Calling-Number AVP (22) in Incoming-Call-Requests (ICRQs)."; } Huang Expires January 29, 2017 [Page 19] Internet-Draft L2TP Yang Data Model July 2016 leaf domain { type string; description "Tunnel domain name"; } choice tunnel-type { case lac-only { description "LAC functionality only"; } case lns-only { description "LNS functionality only"; } default lac-only; description "Tunnel functionality"; } leaf hello-timer { type uint16 { range "30..3600"; } units seconds; description "Hello control message timer"; } leaf max-sessions { type uint16 { range "1..65535"; } description "Maximum number of sessions per tunnel"; } leaf max-tunnels { type uint16 { range "1..64000"; } description "Maximum number of tunnels"; } container message-reordering { leaf message-queue { type uint8 { range "1..32"; } description "Queue size to store out-of-order control messages"; } Huang Expires January 29, 2017 [Page 20] Internet-Draft L2TP Yang Data Model July 2016 description "Accept out of order control messages"; } leaf retry { type uint8 { range "1..100"; } default 5; description "Tunnel control message retransmit count"; } leaf timeout { type uint8 { range "1..30"; } units seconds; description "Tunnel control message timeout value in seconds"; } list tunnel { key local-id; description "Tunnel status information"; leaf local-id { type uint16; description "Tunnel local id"; } leaf local-ip { type inet:ipv4-address; description "Tunnel local ip address"; } leaf local-name { type string; description "Tunnel local name"; } leaf remote-id { type uint16; description "Tunnel remote id"; } leaf remote-ip { type inet:ipv4-address; Huang Expires January 29, 2017 [Page 21] Internet-Draft L2TP Yang Data Model July 2016 description "Tunnel remote ip address"; } leaf remote-port { type inet:port-number; description "Tunnel remote port"; } leaf remote-name { type string; description "Tunnel remote name"; } container window { description "Tunnel control window"; leaf current-tx { type uint16 { range "1..2000"; } description "Current tunnel control window for transmitting"; } leaf max-tx { type uint16 { range "1..2000"; } description "Maximum tunnel control window for transmitting"; } leaf rx { type uint16 { range "1..2000"; } description "Current tunnel control window for receiving"; } } leaf active-sessions { type uint16 { range "1..65534"; } Huang Expires January 29, 2017 [Page 22] Internet-Draft L2TP Yang Data Model July 2016 description "Number of active sessions"; } leaf state { type enumeration { enum "Deleted" { description "Deleted"; } enum "Idle" { description "Idle"; } enum "Created" { description "Created"; } enum "Wait-Open" { description "Wait-Open"; } enum "Wait-SCCRP" { description "Wait-SCCRP"; } enum "Wait-Route-Up" { description "Wait-Route-Up"; } enum "Wait-SCCCN" { description "Wait-SCCCN"; } enum "Established" { description "Established"; } enum "Unknown"{ description "Unknown"; } } description "The operational state of the tunnel"; } list session { key local-id; description "Session status information"; leaf local-id { type uint16; description "Session local id"; } leaf remote-id { type uint16; Huang Expires January 29, 2017 [Page 23] Internet-Draft L2TP Yang Data Model July 2016 description "Session remote id"; } leaf in-octets { type yang:counter64; description "The total number of octets received on the session."; } leaf in-pkts { type yang:counter64; description "The total number of packets received on the session."; } leaf out-octets { type yang:counter64; description "The total number of octets transmitted out of the session."; } leaf out-pkts { type yang:counter64; description "The total number of packets transmitted out of the session."; } leaf state { type enumeration { enum "Deleted" { description "Deleted"; } enum "Idle" { description "Idle"; } enum "Created" { description "Created"; } enum "Wait-Tun" { Huang Expires January 29, 2017 [Page 24] Internet-Draft L2TP Yang Data Model July 2016 description "Wait-Tun"; } enum "Wait-LNS-Ready" { description "Wait-LNS-Ready"; } enum "Wait-ICRP"{ description "Wait-ICRP"; } enum "Wait-LAC-Ready" { description "Wait-LAC-Ready"; } enum "Wait-ICCN" { description "Wait-ICCN"; } enum "Established"{ description "Established"; } enum "Unknown" { description "Unknown"; } } description "The operational state of the session"; } } } } } } 4. Security Considerations The data model defined does not create any security implications. Huang Expires January 29, 2017 [Page 25] Internet-Draft L2TP Yang Data Model July 2016 5. IANA Considerations This draft does not request any IANA action. 6. Normative References [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997. [RFC2661] Townsley, W., Valencia, A., Rubens, A., Pall, G., Zorn, G., and Palter, B., "Layer Two Tunneling Layer Two Tunneling Protocol (L2TP)", DOI 10.17487/RFC2661, RFC 2661, August 1999, . [RFC3931] Lau, J., Ed., Townsley, M., Ed., and I. Goyret, Ed., "Layer Two Tunneling Protocol - Version 3 (L2TPv3)", RFC 3931, DOI 10.17487/RFC3931, March 2005, . [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for the Network Configuration Protocol (NETCONF)", RFC 6020, DOI 10.17487/RFC6020, October 2010, . [RFC6021] Schoenwaelder, J., Ed., "Common YANG Data Types", RFC 6021, DOI 10.17487/RFC6021, October 2010, . Authors' Addresses Yang Huang Ericsson (China) Communications Company Ltd. Ericsson Tower, No. 5 Lize East Street, Chaoyang District Beijing 100102, P.R. China Email: harry.huang@ericsson.com Huang Expires January 29, 2017 [Page 26]