Cisco-IOS-XR-types

This module contains a collection of IOS-XR derived YANG data types. Copyright (c) 2013-2020 by Cisco Systems, Inc. All rights ...

  • Version: 2020-11-18

    Cisco-IOS-XR-types@2020-11-18


    
      module Cisco-IOS-XR-types {
    
        yang-version 1;
    
        namespace
          "http://cisco.com/ns/yang/cisco-xr-types";
    
        prefix xr;
    
        import cisco-semver {
          prefix semver;
        }
        import ietf-inet-types {
          prefix inet;
        }
    
        organization "Cisco Systems, Inc.";
    
        contact
          "Cisco Systems, Inc.
    Customer Service
    
    Postal: 170 W Tasman Drive
    San Jose, CA 95134
    
    Tel: +1 1800 553-NETS
    
    E-mail: cs-yang@cisco.com";
    
        description
          "This module contains a collection of IOS-XR derived YANG data
    types.
    
    Copyright (c) 2013-2020 by Cisco Systems, Inc.
    All rights reserved.";
    
        revision "2020-11-18" {
          description
            "Added a new type Hex-integer-8
    2020-07-24
      Added a new type Controller-name
    2020-06-25
      Added string match pattern of Docker app name";
        }
    
        revision "2019-12-03" {
          description
            "Modified string match pattern of Interface-name";
        }
    
        revision "2019-04-05" {
          description
            "Establish semantic version baseline.";
        }
    
        revision "2019-01-18" {
          description
            "This revision adds the following new data types:
    - Type10-password";
        }
    
        revision "2018-06-29" {
          description
            "Modified string match pattern of Interface-name";
        }
    
        revision "2017-12-01" {
          description
            "Modified string match pattern of Tty-escape-char-num";
        }
    
        revision "2017-03-07" {
          description
            "This revision adds the following new data types:
    - Type8-password
    - Type9-password";
        }
    
        revision "2015-06-29" {
          description
            "This revision adds the following new data types:
    - Rpl-policy
    - Rpl-set";
        }
    
        revision "2015-05-18" {
          description
            "Updated Node-id string pattern to match also shorter ncs4k
    node names.";
        }
    
        revision "2015-01-19" {
          description
            "This revision adds the following new data types:
    - Bgp-ipv4-flowspec-address
    - Bgp-ipv6-flowspec-address";
        }
    
        revision "2013-07-22" {
          description "Initial revision.";
        }
    
        semver:module-version "2.1.0";
        semver:module-version "2.0.0";
        semver:module-version "1.0.0";
    
        extension xr-cli-map {
          argument "cli-command" {
            yin-element false;
          }
          description
            "The xr-cli-map statement takes as an argument
    relevant CLI configuration command.";
        }
    
        extension xr-xml-map {
          argument "xr-xml-node" {
            yin-element false;
          }
          description
            "The xr-xml-map statement takes as an argument
    relevant Cisco XML Schema node name.";
        }
    
        extension cli-command {
          argument "command" {
            yin-element false;
          }
          description
            "Corresponding CLI command for this RPC node";
        }
    
        extension cli-name {
          argument "keyword" {
            yin-element false;
          }
          description
            "Corresponding CLI keyword for this node";
        }
    
        extension xr-task {
          argument "task" {
            yin-element false;
          }
          description
            "XR task-id required for operating the yang node";
        }
    
        extension event-telemetry {
          argument "description" {
            yin-element false;
          }
          description
            "Node eligible for telemetry event subscription";
        }
    
        typedef Route-dist {
          type string {
            pattern '[a-fA-F0-9]{16}';
          }
          description
            "Route distinguisher in hexadecimal notation.";
        }
    
        typedef Bgp-l2vpn-evpn-addrs {
          type string {
            pattern '[a-fA-F0-9]{58}';
          }
          description
            "L2VPN EVPN Address in hexadecimal notation.";
        }
    
        typedef Bgp-ls-addr {
          type string {
            pattern '[a-fA-F0-9]+';
          }
          description
            "BGP link state unicast address in hexadecimal
    notation.";
        }
    
        typedef Bgp-ipv6-mvpn-addr {
          type string {
            pattern '[a-fA-F0-9]{104}';
          }
          description
            "An IPV6 MVPN address in hexadecimal notation.";
        }
    
        typedef Bgp-ipv4-mvpn-addr {
          type string {
            pattern '[a-fA-F0-9]{56}';
          }
          description
            "An IPV4 MVPN address in hexadecimal notation.";
        }
    
        typedef Bgp-rt-constrt-addr {
          type string {
            pattern '[a-fA-F0-9]{24}';
          }
          description
            "An IPV4 RTConstraint address in hexadecimal notation.";
        }
    
        typedef Bgp-ipv4-mdt-addr {
          type string {
            pattern
              '(([a-f0-9]{16}-)(([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]))';
          }
          description
            "An IPV4 MDT address in dotted decimal notation.
    An IPv4 MDT address should be of the form
    0000006400000065-129.29.83.45. This datatype
    restricts the value of each field 16 digits in
    hexadecimal for RD field and between 0 and 255
    for IPv4 address field, i.e.
    [0000000000000000-ffffffffffffffff]-
    [0-255].[0-255].[0-255].[0-255].";
        }
    
        typedef Bgp-ipv4-tunnel-addr {
          type string {
            pattern
              '((0:|[1-9][0-9]{0,4}:)(([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]))';
          }
          description
            "An IPV4 tunnel address in dotted decimal notation.
    An IPv4 tunnel address should be of the form
    65535:129.29.83.45. This datatype restricts the
    value of each field between 0 and 65535 for prefix
    field and 0 and 255 for IPv4 address field, i.e.
    [0-65535]:[0-255].[0-255].[0-255].[0-255]";
        }
    
        typedef Cisco-ios-xr-port-number {
          type uint16 {
            range "1..65535";
          }
          description
            "Port number of range from 1 to 65535";
        }
    
        typedef Interface-name {
          type string {
            pattern '[a-zA-Z0-9.:_/-]+';
          }
          description
            "An interface name specifying an interface type and
    instance.
    Interface represents a string defining an interface
    type and instance, e.g. MgmtEth0/4/CPU1/0 or
    TenGigE0/2/0/0.2 or Bundle-Ether9 or
    Bundle-Ether9.98 or Serial0/0/0/0/3/1:1";
        }
    
        typedef Controller-name {
          type string {
            pattern '[a-zA-Z0-9.:_/-]+';
          }
          description
            "A controller name specifying a controller type and
    instance.
    Controller represents a string defining a controller
    type and instance, e.g. dwdm0/4/0/0 or
    GigabitEthCtrlr0/2/0/0 or T10/0/0/0";
        }
    
        typedef Cisco-ios-xr-string {
          type string {
            pattern '[\w\-\.:,_@#%$\+=\|;]+';
          }
          description
            "Special characters are not allowed.";
        }
    
        typedef Ipv4-prefix-length {
          type uint8 {
            range "0..32";
          }
          description
            "An IPv4 address prefix length.
    Must lie between 0 and 32 inclusive.";
        }
    
        typedef Ipv6-prefix-length {
          type uint8 {
            range "0..128";
          }
          description
            "An IPv6 address prefix length.
    Must lie between 0 and 32 inclusive.";
        }
    
        typedef Rack-id {
          type string {
            pattern '[a-zA-Z0-9_]*\d+';
          }
          description
            "Names the rack portion of a NodeID
    Rack/Slot/Instance triple";
        }
    
        typedef Slot-id {
          type string {
            pattern '[a-zA-Z0-9_]*\d+';
          }
          description
            "Names the slot portion of a NodeID
    Rack/Slot/Instance triple";
        }
    
        typedef Instance-id {
          type string {
            pattern '[a-zA-Z0-9_]*\d+';
          }
          description
            "Names the instance portion of a NodeID
    Rack/Slot/Instance triple";
        }
    
        typedef Sub-instance-id {
          type string {
            pattern '[a-zA-Z0-9_]*\d+';
          }
          description
            "Names the sub-instance portion of an extended
    NodeID Rack/Slot/Instance/SubInstance";
        }
    
        typedef Encryption-type {
          type enumeration {
            enum "none" {
              value 0;
              description
                "The password string is clear text.";
            }
            enum "md5" {
              value 1;
              description
                "The password is encrypted to an MD5 digest.";
            }
            enum "proprietary" {
              value 2;
              description
                "The password is encrypted using Cisco type 7
    password encryption.";
            }
            enum "type6" {
              value 3;
              description
                "The password is encrypted using Cisco type 6
    password encryption.";
            }
          }
          description
            "The type of encryption used on a password string.";
        }
    
        typedef Hex-integer {
          type string {
            pattern '[0-9a-fA-F]{1,8}';
          }
          description
            "An unsigned 32-bit integer represented in
    hexadecimal format.";
        }
    
        typedef Hex-integer-16 {
          type string {
            pattern '[0-9a-fA-F]{1,4}';
          }
          description
            "An unsigned 16-bit integer represented in
    hexadecimal format.";
        }
    
        typedef Hex-integer-8 {
          type string {
            pattern '[0-9a-fA-F]{1,2}';
          }
          description
            "An unsigned 8-bit integer represented in
    hexadecimal format.";
        }
    
        typedef Osi-system-id {
          type string {
            pattern
              '[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}';
          }
          description
            "An OSI system ID should be of the form
    0123.4567.89ab. This data type restricts each
    character to a hex character.";
        }
    
        typedef Osi-area-address {
          type string {
            pattern
              '[a-fA-F0-9]{2}(\.[a-fA-F0-9]{4}){0,6}';
          }
          description
            "An OSI area address should consist of an odd number
    of octets, and be of the form 01 or 01.2345 etc up
    to 01.2345.6789.abcd.ef01.2345.6789. This data type
    restricts each character to a hex character.";
        }
    
        typedef Isis-node-id {
          type string {
            pattern
              '[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}\.[a-fA-F0-9]{2}';
          }
          description
            "An ISIS node ID should be of the form
    0123.4567.89ab.cd. This data type restricts each
    character to a hex character.";
        }
    
        typedef Isis-snpa {
          type string {
            pattern
              '[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}';
          }
          description
            "String representation of a SNPA, 802.2 MAC address
    in canonical format, e.g. 0123.4567.89ab";
        }
    
        typedef Isis-lsp-id {
          type string {
            pattern
              '[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}\.[a-fA-F0-9]{2}\-[a-fA-F0-9]{2}';
          }
          description
            "An ISIS LSP ID should be of the form
    0123.4567.89ab.cd-ef. This data type restricts each
    character to a hex character.";
        }
    
        typedef Osi-net {
          type string {
            pattern
              '[a-fA-F0-9]{2}(\.[a-fA-F0-9]{4}){3,9}\.[a-fA-F0-9]{2}';
          }
          description
            "An OSI NET should consist of an even number of
    octets, and be of the form 01.2345.6789.abcd.ef etc
    up to
    01.2345.6789.abcd.ef01.2345.6789.abcd.ef01.2345.67.
    This data type restricts each character to a hex
    character.";
        }
    
        typedef String-identifier {
          type string {
            pattern '[a-zA-Z0-9_\-]+';
          }
          description
            "A string for specifying identifier.";
        }
    
        typedef Char-num {
          type union {
            type string {
              pattern
                '(0x[0-9A-Fa-f]{1,2}|\p{IsBasicLatin}|\p{IsLatin-1Supplement})';
            }
            type uint8;
          }
          description
            "Takes a character or its ASCII decimal equivalent
    (0-255).";
        }
    
        typedef Tty-escape-char-num {
          type union {
            type string {
              pattern
                '(0x[0-9A-Fa-f]{1,2}|\p{IsBasicLatin}|\p{IsLatin-1Supplement}|DEFAULT|BREAK|NONE)';
            }
            type uint8;
          }
          description
            "Escape character or its ASCII decimal equivalent
    (0-255) or one of the three string DEFAULT, BREAK,
    NONE.";
        }
    
        typedef Extended-node-id {
          type string {
            pattern
              '([a-zA-Z0-9_]*\d+/){3}([a-zA-Z0-9_]*\d+)';
          }
          description
            "A location used as value information and specified
    as a Rack/Slot/Instance/SubInstance, e.g.
    0/1/CPU0/NPU0";
        }
    
        typedef Node-id {
          type string {
            pattern
              '([a-zA-Z0-9_]*\d+/){1,2}([a-zA-Z0-9_]*\d+)';
          }
          description
            "A location used as value information and specified
    as a Rack/Slot/Instance triple, e.g. F0/SC1/0.";
        }
    
        typedef Pq-node-id {
          type string {
            pattern
              '((([a-zA-Z0-9_]*\d+)|(\*))/){2}(([a-zA-Z0-9_]*\d+)|(\*))';
          }
          description
            "Partially qualified location which is used for
    wildcarding location specifications, e.g. 1/*/*";
        }
    
        typedef Md5-password {
          type string {
            pattern '(!.+)|([^!].+)';
          }
          description
            "The Md5-password type is used to store password using the MD5
    hash function.
    When a clear text value is set to a leaf of this type, the
    server calculates a password hash and stores the result
    in the datastore. The password is never stored in clear text.
    
    When a leaf of this type is read, the stored password hash is
    returned.
    
    A value of this type matches one of the forms:
    
      !<clear text password>
      <password hash>
    
    The '!' prefix signals that the value is clear text. When
    such a value is received by the server, a hash value is
    calculated. This value is stored in the configuration data
    store.
    
    If a value starting without '!' is received, the server knows
    that the value already represents a hashed value, and stores
    it as is in the data store.";
        }
    
        typedef Type8-password {
          type string {
            pattern '(!.+)|([^!].+)';
          }
          description
            "The Type8-password type is used to store password using the
    SHA-256 encryption.
    When a clear text value is set to a leaf of this type, the
    server calculates a password hash and stores the result
    in the datastore. The password is never stored in clear text.
    
    When a leaf of this type is read, the stored password hash is
    returned.
    
    A value of this type matches one of the forms:
    
      !<clear text password>
      <password hash>
    
    The '!' prefix signals that the value is clear text. When
    such a value is received by the server, a hash value is
    calculated. This value is stored in the configuration data
    store.
    
    If a value starting without '!' is received, the server knows
    that the value already represents a hashed value, and stores
    it as is in the data store.";
        }
    
        typedef Type9-password {
          type string {
            pattern '(!.+)|([^!].+)';
          }
          description
            "The Type9-password type is used to store password using the
    Script algorithmic encryption.
    When a clear text value is set to a leaf of this type, the
    server calculates a password hash and stores the result
    in the datastore. The password is never stored in clear text.
    
    When a leaf of this type is read, the stored password hash is
    returned.
    
    A value of this type matches one of the forms:
    
      !<clear text password>
      <password hash>
    
    The '!' prefix signals that the value is clear text. When
    such a value is received by the server, a hash value is
    calculated. This value is stored in the configuration data
    store.
    
    If a value starting without '!' is received, the server knows
    that the value already represents a hashed value, and stores
    it as is in the data store.";
        }
    
        typedef Type10-password {
          type string {
            pattern '(!.+)|([^!].+)';
          }
          description
            "The Type10-password type is used to store password using the
    Script algorithmic encryption.
    When a clear text value is set to a leaf of this type, the
    server calculates a password hash and stores the result
    in the datastore. The password is never stored in clear text.
    
    When a leaf of this type is read, the stored password hash is
    returned.
    
    A value of this type matches one of the forms:
    
      !<clear text password>
      <password hash>
    
    The '!' prefix signals that the value is clear text. When
    such a value is received by the server, a hash value is
    calculated. This value is stored in the configuration data
    store.
    
    If a value starting without '!' is received, the server knows
    that the value already represents a hashed value, and stores
    it as is in the data store.";
        }
    
        typedef Proprietary-password {
          type string {
            pattern '(!.+)|([^!].+)';
          }
          description
            "The Proprietary-password type is used to store password
    using the Cisco proprietary hash function.
    When a clear text value is set to a leaf of this type, the
    server calculates a password hash and stores the result
    in the datastore. The password is never stored in clear text.
    
    When a leaf of this type is read, the stored password hash is
    returned.
    
    A value of this type matches one of the forms:
    
      !<clear text password>
      <password hash>
    
    The '!' prefix signals that the value is clear text. When
    such a value is received by the server, a hash value is
    calculated. This value is stored in the configuration data
    store.
    
    If a value starting without '!' is received, the server knows
    that the value already represents a hashed value, and stores
    it as is in the data store.";
        }
    
        typedef Type6-password {
          type string {
            pattern '(!.+)|([^!].+)';
          }
          description
            "The Type6-password type is used to store password
    using the Cisco type 6 hash function.
    When a clear text value is set to a leaf of this type, the
    server calculates a password hash and stores the result
    in the datastore. The password is never stored in clear text.
    
    When a leaf of this type is read, the stored password hash is
    returned.
    
    A value of this type matches one of the forms:
    
      !<clear text password>
      <password hash>
    
    The '!' prefix signals that the value is clear text. When
    such a value is received by the server, a hash value is
    calculated. This value is stored in the configuration data
    store.
    
    If a value starting without '!' is received, the server knows
    that the value already represents a hashed value, and stores
    it as is in the data store.";
        }
    
        typedef Bgp-ipv4-flowspec-address {
          type string {
            pattern '[a-fA-F0-9]{4096}';
          }
          description
            "An IPV4 Flowspec address in hexadecimal notation.";
        }
    
        typedef Bgp-ipv6-flowspec-address {
          type string {
            pattern '[a-fA-F0-9]{4096}';
          }
          description
            "An IPV6 Flowspec address in hexadecimal notation.";
        }
    
        typedef Rpl-policy {
          type string;
          description "RPL Policy info";
        }
    
        typedef Rpl-set {
          type string;
          description "RPL Set info";
        }
    
        typedef Physical-allowed-node-id {
          type uint32;
          description
            "A physical location encoded as a 32-bit value.";
        }
    
        typedef Physical-allowed-node-id-string {
          type string;
          description
            "A physical location which is represented internallyusing string format (eg: 0_6_CPU0).";
        }
    
        typedef Bgp-as-number {
          type union {
            type uint32 {
              range "1..65535";
            }
            type string {
              pattern
                '([1-9][0-9]{0,4}).([0-9]{1,5})';
            }
            type uint32 {
              range "65536..4294967295";
            }
          }
          description "BGP AS number type";
        }
    
        typedef Route-policy-name {
          type string {
            length "1..255";
          }
          description
            "Datatype for route policy name";
        }
    
        typedef Ospf-area-id {
          type union {
            type uint32 {
              range "0..4294967295";
            }
            type inet:ip-address;
          }
          description
            "OSPF area ID. Either OSPF area ID as a decimal value or OSPF area ID in IP address format";
        }
    
        typedef Vpn-id {
          type string {
            pattern
              '([0-9a-f]{1,8}):([0-9a-f]{1,8})';
          }
          description
            "VPN ID format (OUI:VPN-Index in hex integer)";
        }
    
        typedef Mpls-label-space-id {
          type string {
            pattern
              '(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]):0';
          }
          description
            "MPLS-LDP labe-space ID format";
        }
    
        typedef Bgp-route-distinguisher {
          type union {
            type string {
              pattern
                '([0-9]{1,5}):([0-9]{1,10})';
            }
            type string {
              pattern
                '([0-9]{5,10}):([0-9]{1,10})';
            }
            type string {
              pattern
                '(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]):([0-9]{1,10})';
            }
          }
          description
            "BGP route distinguisher number format";
        }
    
        typedef Evpn-esi-value {
          type string {
            pattern
              '[0-9a-f]{1,2}(\.[0-9a-f]{1,2}){8}';
          }
          description "EVPN 9-octet ESI value";
        }
    
        typedef Docker-app-id {
          type string {
            pattern '[a-zA-Z0-9][a-zA-Z0-9_.-]+';
          }
          description
            "A Docker container name format.";
        }
      }  // module Cisco-IOS-XR-types
    

© 2024 YumaWorks, Inc. All rights reserved.