-- HP Enterprise Switch UDP Forwarder configuration MIB 

HP-ICF-UDP-FORWARD DEFINITIONS ::= BEGIN

    IMPORTS
        Integer32,Counter32, MODULE-IDENTITY, OBJECT-TYPE
            FROM SNMPv2-SMI
        RowStatus
            FROM SNMPv2-TC
        VlanId
            FROM Q-BRIDGE-MIB
        hpSwitch
            FROM HP-ICF-OID
        InetAddressType, InetAddress, InetPortNumber
            FROM INET-ADDRESS-MIB
        MODULE-COMPLIANCE, OBJECT-GROUP
              FROM SNMPv2-CONF;

    hpicfUdpFwd MODULE-IDENTITY
        LAST-UPDATED "201706130630Z" -- June 13, 2017
        ORGANIZATION "HP Networking"
        CONTACT-INFO "Hewlett-Packard Company
                      8000 Foothills Blvd.
                      Roseville, CA 95747"
        DESCRIPTION  "This MIB module defines objects for configuring
                     the UDP Broadcast Forwarding of HP networking
                     devices."

        REVISION     "201706130630Z" -- June 13, 2017
        DESCRIPTION  "The Mib object hpicfUdpFwdDhcpRelayAdminStatus description
                      has been updated."

        REVISION     "201301040630Z" -- Jan 04, 2013
        DESCRIPTION  "Added Mib Objects for DHCP Relay Agent configuration 
	              and policies."

        REVISION     "200908040630Z" -- Aug 04, 2009
        DESCRIPTION  "Added Mib Objects that display DHCP Relay Agent 
	              packet statistics."

        REVISION     "200405190630Z" -- May 19, 2004
        DESCRIPTION  "Initial version of this MIB module."
        
        ::= { hpSwitch 23 }


hpicfUdpFwdNotification         OBJECT IDENTIFIER ::= {hpicfUdpFwd 0}
hpicfUdpFwdObjects         OBJECT IDENTIFIER ::= { hpicfUdpFwd 1 }

-- General UDP broadcast forwarding group

hpicfUdpBcastFwdAdminStatus         OBJECT-TYPE
        SYNTAX      INTEGER {
                        enabled(1),
                        disabled(2)
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "The operational status of the UDP Broadcast Forward
                    feature"
        DEFVAL     { disabled }
        ::= { hpicfUdpFwdObjects 1 }

-- UDP broadcast forwarding table

hpicfUdpFwdServersTable  OBJECT-TYPE
        SYNTAX  SEQUENCE OF HpicfUdpFwdServersEntry
        MAX-ACCESS  not-accessible
        STATUS  current
        DESCRIPTION
                "This table contains a list of UDP Server Address and 
                 associated port numbers for which forwarding 
                 is enabled."
        ::= { hpicfUdpFwdObjects 2}

hpicfUdpFwdServersEntry  OBJECT-TYPE
        SYNTAX  HpicfUdpFwdServersEntry
        MAX-ACCESS  not-accessible
        STATUS  current
        DESCRIPTION
                "An entry of the UDP broadcast forwarding
                table."
        INDEX   {hpicfUdpFwdVlanId,
                 hpicfUdpFwdServerIndex}

        ::= { hpicfUdpFwdServersTable 1 }

HpicfUdpFwdServersEntry ::= SEQUENCE {
        hpicfUdpFwdVlanId                 VlanId,
        hpicfUdpFwdServerIndex            Integer32,
        hpicfUdpFwdServerAddressType      InetAddressType,
        hpicfUdpFwdServerAddress          InetAddress,
        hpicfUdpFwdPortNumber             InetPortNumber,
        hpicfUdpFwdRowStatus              RowStatus
        }

hpicfUdpFwdVlanId OBJECT-TYPE
        SYNTAX      VlanId
        MAX-ACCESS  not-accessible
        STATUS      current
        DESCRIPTION "The VLAN index which uniquely identifies a row  
                    in this table."
        ::= { hpicfUdpFwdServersEntry 1 }

hpicfUdpFwdServerIndex OBJECT-TYPE
        SYNTAX      Integer32 (1..4094)
        MAX-ACCESS  not-accessible
        STATUS      current
        DESCRIPTION "Server table index which uniquely identifies a
                    position in table of servers (for VlanIndex)."
        ::= { hpicfUdpFwdServersEntry 2 }

hpicfUdpFwdServerAddressType       OBJECT-TYPE
        SYNTAX      InetAddressType
        MAX-ACCESS  read-create
        STATUS      current
        DESCRIPTION "The type of IP address for the configured server"
        ::= { hpicfUdpFwdServersEntry 3 }

hpicfUdpFwdServerAddress OBJECT-TYPE
        SYNTAX      InetAddress (SIZE(0..36))
        MAX-ACCESS  read-create
        STATUS      current
        DESCRIPTION " This object contains the server IP address. The
                  type of address specified by this object is 
              indicated by the corresponding instance of the 
              hpicfUdpFwdServerAddressType. 

                    An attempt to create a row in which the length
                    of this object is not consistent with the type
                    specified by hpicfUdpFwdServerAddressType must
                    be rejected."

        ::= { hpicfUdpFwdServersEntry 4 }

hpicfUdpFwdPortNumber     OBJECT-TYPE
        SYNTAX  InetPortNumber
        MAX-ACCESS  read-create
        STATUS      current
        DESCRIPTION " UDP port number for which UDP broadcast forwarding
                is enabled."
        ::= { hpicfUdpFwdServersEntry 5}


hpicfUdpFwdRowStatus  OBJECT-TYPE
        SYNTAX      RowStatus
        MAX-ACCESS  read-create
        STATUS      current
        DESCRIPTION "Status of table row."              
        ::= { hpicfUdpFwdServersEntry 6 }


-- DHCP Relay statistics mib 

hpicfUdpFwdDhcpRelayClientDiscards OBJECT-TYPE
        SYNTAX        Counter32
        MAX-ACCESS read-only
        STATUS     current
        DESCRIPTION "The number of DHCP client packets discarded
		     by the relay agent for any reason."
        ::= { hpicfUdpFwdObjects 3}

hpicfUdpFwdDhcpRelayClientForwards OBJECT-TYPE
        SYNTAX        Counter32
        MAX-ACCESS read-only
        STATUS     current
        DESCRIPTION "The number of DHCP client packets relayed 
	             successfully to the DHCP server by the relay agent."
        ::= { hpicfUdpFwdObjects 4}

hpicfUdpFwdDhcpRelayServerDiscards OBJECT-TYPE
        SYNTAX        Counter32
        MAX-ACCESS read-only
        STATUS     current
        DESCRIPTION "The number of DHCP server packets discarded 
	             by the relay agent for any reason."
        ::= { hpicfUdpFwdObjects 5 }

hpicfUdpFwdDhcpRelayServerForwards OBJECT-TYPE
        SYNTAX        Counter32
        MAX-ACCESS read-only
        STATUS     current
        DESCRIPTION "The number of DHCP server packets relayed 
	            successfully to the DHCP server by the relay agent."
        ::= { hpicfUdpFwdObjects 6 }

hpicfUdpFwdDhcpRelayAdminStatus OBJECT-TYPE
        SYNTAX      INTEGER{
                        enable(1),
                        disable(2)
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "The operational status of the DHCP Relay protocol."
        ::= { hpicfUdpFwdObjects 7 }

hpicfUdpFwdDhcpRelayOption82Objects OBJECT IDENTIFIER ::= { hpicfUdpFwdObjects 8 }

hpicfUdpFwdDhcpRelayOption82AdminStatus OBJECT-TYPE
        SYNTAX      INTEGER{
                        enable(1),
                        disable(2)
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "The operational status of the option 82 in the 
                     DHCP Relay Agent protocol. This mib object has a direct
                     dependency on the hpicfUdpFwdDhcpRelayOption82Policy object 
                     and should be present when operational status of this 
                     object is changed to enable. 
                     The status disable will reset the option 82 parameters
                     to default values."
        ::= { hpicfUdpFwdDhcpRelayOption82Objects 1 }

hpicfUdpFwdDhcpRelayOption82Policy OBJECT-TYPE
        SYNTAX      INTEGER{
                        replace(1),
                        keep(2),
                        drop(3)
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "The operational policies for option 82. This mib object 
              can be configured only when 
              hpicfUdpFwdDhcpRelayOption82AdminStatus is in enable state. 
              This is the required parameter during configuration of option 82.
              The policies currently supported are:
              Keep    --- Append the option 82 field to the client request 
                          only if not already present before forwarding 
                          to the server.
              Replace --- Replace the option 82 field(s) with switch 
                          option 82 if present else add the option 82 
                          field to the client
                          request before forwarding to server.
              Drop    --- Drop the request if option 82 field exists in the 
                          client request else add the option 82 field to the 
                          client request before forwarding to server."
        ::= { hpicfUdpFwdDhcpRelayOption82Objects 2 }

hpicfUdpFwdDhcpRelayOption82ResponseValidate OBJECT-TYPE
        SYNTAX      INTEGER{
                        enable(1),
                        disable(2)
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Validate the server response for the 
                     option 82 field before forwarding to client. This 
              mib object can be configured only when 
              hpicfUdpFwdDhcpRelayOption82AdminStatus is in enable state. This 
              is an optional parameter during configuration of option 82 
              and the default value in the switch is disable"
        ::= { hpicfUdpFwdDhcpRelayOption82Objects 3 }

hpicfUdpFwdDhcpRelayOption82RemoteId OBJECT-TYPE
        SYNTAX      INTEGER{
                        mac(1),
                        ip(2),
                        mgmtvlan(3) 
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION  "Remote ID sub option that will be filled while 
          forwarding the client request to the server. This mib object 
          can be configured only when hpicfUdpFwdDhcpRelayOption82AdminStatus 
          is in enable state. The default value for this mib object is mac.
                     
           mac ---  the switch MAC address is filled 
                    as remote id sub option.
           ip ---  IP address of the VLAN on which the client request is 
                   received is filled as remote id sub option.
           mgmtvlan ---   the management VLAN IP address will be filled for
                           remote id sub option."

        ::= { hpicfUdpFwdDhcpRelayOption82Objects 4 }

hpicfUdpFwdDhcpRelayHopCount OBJECT-TYPE
        SYNTAX      INTEGER{
                        enable(1),
                        disable(2)
                    }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "If this mib object is disabled then DHCP Relay
                     Agent will not increment the hop count field of
                     the DHCP packet while transmitting packet to the
                     DHCP server. If this mib object is enabled then
                     DHCP Relay Agent will increment the hop count 
                     field while transmitting the DHCP packet to the
                     server. By default it is set to enabled."
        ::= { hpicfUdpFwdObjects 9}

-- Conformance information

hpicfUdpFwdConformance OBJECT IDENTIFIER ::= { hpicfUdpFwd  2 }

hpicfUdpFwdCompliances OBJECT IDENTIFIER ::= { hpicfUdpFwdConformance 1 }
hpicfUdpFwdGroups      OBJECT IDENTIFIER ::= { hpicfUdpFwdConformance 2 }



-- compliance statements


hpicfUdpFwdCompliance MODULE-COMPLIANCE
        STATUS      current
        DESCRIPTION "
                A compliance statement for HP Routing switches with UDP 
                packet forwarding"
        MODULE
        MANDATORY-GROUPS {  hpicfUdpFwdCfgGroup,
                            hpicfUdpFwdServerTableGroup}

        GROUP       hpicfUdpFwdCfgGroup
        DESCRIPTION "A Collection of Object(s) that allow  
                     configuration of UDP Forwarder"

        GROUP       hpicfUdpFwdServerTableGroup
        DESCRIPTION "A Collection of Object(s) that allow  
                     configuration of Server Addresses"

        ::= { hpicfUdpFwdCompliances 1 }

hpicfUdpFwdStatCompliance MODULE-COMPLIANCE
        STATUS      current
        DESCRIPTION "
                A compliance statement for HP Routing switches with UDP 
                packet forwarding statistics"
        MODULE
        MANDATORY-GROUPS { hpicfUdpFwdDhcpRelayStatsGroup }

       
        GROUP       hpicfUdpFwdDhcpRelayStatsGroup
        DESCRIPTION "A collection of objects that give statistics 
		     on packet processing done by the DHCP Relay."

        ::= { hpicfUdpFwdCompliances 2 }

hpicfUdpFwdDhcpRelayCfgCompliance MODULE-COMPLIANCE
        STATUS      current
        DESCRIPTION "
                A compliance statement for HP Routing switches with DHCP
                Relay agent."
        MODULE
        MANDATORY-GROUPS {  hpicfUdpFwdDhcpRelayCfgGroup }

        GROUP       hpicfUdpFwdDhcpRelayCfgGroup
        DESCRIPTION "A Collection of Object(s) that allow
                     configuration of DHCP Relay Agent and its policies."

        ::= { hpicfUdpFwdCompliances 3 }

hpicfUdpFwdCfgGroup OBJECT-GROUP
        OBJECTS     { hpicfUdpBcastFwdAdminStatus}
        STATUS      current
        DESCRIPTION "Enable/Disable the UDP Forwarder in the routing switch"
        ::= { hpicfUdpFwdGroups 1 }

hpicfUdpFwdServerTableGroup OBJECT-GROUP
        OBJECTS     { 
                      hpicfUdpFwdServerAddressType,
                      hpicfUdpFwdServerAddress,
                      hpicfUdpFwdPortNumber,
                      hpicfUdpFwdRowStatus }
        STATUS      current
        DESCRIPTION "A collection of objects allowing configuration of
                    UDP Forwarder Server Address table"
        ::= { hpicfUdpFwdGroups 2 }

hpicfUdpFwdDhcpRelayStatsGroup OBJECT-GROUP
        OBJECTS     {
	              hpicfUdpFwdDhcpRelayClientDiscards,
                      hpicfUdpFwdDhcpRelayClientForwards,
                      hpicfUdpFwdDhcpRelayServerDiscards,
                      hpicfUdpFwdDhcpRelayServerForwards}
        STATUS      current
        DESCRIPTION "A collection of statistics objects for DHCP Relay agent"
        ::= { hpicfUdpFwdGroups 3 }

hpicfUdpFwdDhcpRelayCfgGroup OBJECT-GROUP
        OBJECTS     { hpicfUdpFwdDhcpRelayAdminStatus,
                      hpicfUdpFwdDhcpRelayOption82AdminStatus,
                      hpicfUdpFwdDhcpRelayOption82Policy,
                      hpicfUdpFwdDhcpRelayOption82ResponseValidate,
                      hpicfUdpFwdDhcpRelayOption82RemoteId,
                      hpicfUdpFwdDhcpRelayHopCount}
        STATUS      current
        DESCRIPTION "A Collection of Object(s) that allow
                     configuration of DHCP Relay Agent and its policies."
        ::= { hpicfUdpFwdGroups 4 }

END

