netconfcentral logo

ietf-snmp-target@2014-05-06



  submodule ietf-snmp-target {

    yang-version 1;

    belongs-to ietf-snmp {
        prefix snmp;
    }

    import ietf-inet-types {
      prefix inet;
    }

    include ietf-snmp-common;

    organization
      "IETF NETMOD (NETCONF Data Modeling Language) Working Group";

    contact
      "WG Web:   <http://tools.ietf.org/wg/netmod/>
     WG List:  <mailto:netmod@ietf.org>

     WG Chair: Thomas Nadeau
               <mailto:tnadeau@lucidvision.com>

     WG Chair: Juergen Schoenwaelder
               <mailto:j.schoenwaelder@jacobs-university.de>

     Editor:   Martin Bjorklund
               <mailto:mbj@tail-f.com>
     Editor:   Juergen Schoenwaelder
               <mailto:j.schoenwaelder@jacobs-university.de>";

    description
      "This submodule contains a collection of YANG definitions
     for configuring SNMP targets.

     Copyright (c) 2014 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.";

    reference
      "RFC3413: Simple Network Management Protocol (SNMP)
      	 Applications";


    revision "2014-05-06" {
      description "Initial revision.";
      reference
        "RFC XXXX: A YANG Data Model for SNMP Configuration";

    }


    augment /snmp:snmp {
      list target {
        key "name";
        description "List of targets.";
        reference
          "SNMP-TARGET-MIB.snmpTargetAddrTable";

        leaf name {
          type identifier;
          description
            "Identifies the target.";
          reference
            "SNMP-TARGET-MIB.snmpTargetAddrName";

        }

        choice transport {
          mandatory true;
          description
            "Transport address of the target.

           The snmpTargetAddrTDomain and snmpTargetAddrTAddress
           objects are mapped to transport-specific YANG nodes.  Each
           transport is configured as a separate case in this
           choice. Submodules providing configuration for additional
           transports are expected to augment this choice.";
          reference
            "SNMP-TARGET-MIB.snmpTargetAddrTDomain
            SNMP-TARGET-MIB.snmpTargetAddrTAddress";

          case udp {
            reference
              "SNMPv2-TM.snmpUDPDomain
              TRANSPORT-ADDRESS-MIB.transportDomainUdpIpv4
              TRANSPORT-ADDRESS-MIB.transportDomainUdpIpv4z
              TRANSPORT-ADDRESS-MIB.transportDomainUdpIpv6
              TRANSPORT-ADDRESS-MIB.transportDomainUdpIpv6z";

            container udp {
              leaf ip {
                type inet:ip-address;
                mandatory true;
                reference
                  "SNMP-TARGET-MIB.snmpTargetAddrTAddress";

              }

              leaf port {
                type inet:port-number;
                default '162';
                description
                  "UDP port number";
                reference
                  "SNMP-TARGET-MIB.snmpTargetAddrTAddress";

              }

              leaf prefix-length {
                type uint8;
                description
                  "The value of this leaf must match the value of
                 ../snmp:ip. If ../snmp:ip contains an ipv4 address,
                 this leaf must be less than or equal to 32.  If it
                 contains an ipv6 address, it must be less than or
                 equal to 128.

                 Note that the prefix-length is currently only used
                 by the Community-based Security Model to filter
                 incoming messages. Furthermore, the prefix-length
                 filtering does not cover all possible filters
                 supported by the corresponding MIB object.";
                reference
                  "SNMP-COMMUNITY-MIB.snmpTargetAddrTMask";

              }
            }  // container udp
          }  // case udp
        }  // choice transport

        leaf-list tag {
          type tag-value;
          description
            "List of tag values used to select target address.";
          reference
            "SNMP-TARGET-MIB.snmpTargetAddrTagList";

        }

        leaf timeout {
          type uint32;
          units "0.01 seconds";
          default '1500';
          description
            "Needed only if this target can receive
           InformRequest-PDUs.";
          reference
            "SNMP-TARGET-MIB.snmpTargetAddrTimeout";

        }

        leaf retries {
          type uint8;
          default '3';
          description
            "Needed only if this target can receive
           InformRequest-PDUs.";
          reference
            "SNMP-TARGET-MIB.snmpTargetAddrRetryCount";

        }

        leaf target-params {
          type identifier;
          mandatory true;
          reference
            "SNMP-TARGET-MIB.snmpTargetAddrParams";

        }
      }  // list target

      list target-params {
        key "name";
        description
          "List of target parameters.";
        reference
          "SNMP-TARGET-MIB.snmpTargetParamsTable";

        leaf name {
          type identifier;
        }

        choice params {
          description
            "This choice is augmented with case nodes containing
           security model specific configuration parameters.";
        }  // choice params
      }  // list target-params
    }
  }  // submodule ietf-snmp-target