ELTEX-DHCP DEFINITIONS ::= BEGIN

-- Title:      ELTEX DHCP Extension Private
-- Version:    1.3
-- Date:       29-Jun-2018

IMPORTS
    MODULE-IDENTITY, OBJECT-TYPE                    FROM SNMPv2-SMI
    TEXTUAL-CONVENTION, TruthValue                  FROM SNMPv2-TC
    DisplayString, PhysAddress                      FROM SNMPv2-TC
    rlDhcpSrvConfParamsEntry, rlDhcpSrvIpAddrEntry  FROM RADLAN-DHCP-MIB
    eltMesDhcp                                      FROM ELTEX-MES
    VlanList1, VlanList2, VlanList3, VlanList4      FROM RADLAN-BRIDGEMIBOBJECTS-MIB
    rlDhcpRelayNextServerEntry                      FROM RADLAN-DHCP-MIB;

--
-- Common types
--

EltDhcpRelayOption82PolicyType ::= TEXTUAL-CONVENTION
    STATUS current
    DESCRIPTION     "Specifies DHCP relay option 82 reforwarding policy"
    SYNTAX INTEGER{
       replace(1),
       drop(2),
       keep(3)
    }

EltDhcpRelayOption82SuboptionType ::= TEXTUAL-CONVENTION
    STATUS current
    DESCRIPTION    "Specifies global format of option 82 suboptions."
    SYNTAX INTEGER{
       tr101(1),
       custom(2)
    }

EltDhcpRelayOption82CombinationType ::= TEXTUAL-CONVENTION
    STATUS current
    DESCRIPTION    "Specifies circuit id suboption that will be inserted to a option 82."
    SYNTAX INTEGER{
       sv(2),
       pv(3),
       spv(4),
       bin(5)
    }

EltDhcpRelayOption82DelimiterType ::= TEXTUAL-CONVENTION
    STATUS current
    DESCRIPTION    "Specifies circuit id suboption delimeter that will be inserted to a option 82."
    SYNTAX INTEGER{
       tr101(1),
       dot(2),
       comma(3),
       semicolon(4),
       hash(5),
       slash(6),
       space(7)
    }

--
-- DHCP Relay
--

eltMesDhcpRelay OBJECT IDENTIFIER ::= { eltMesDhcp  1}

--
-- DHCP Relay Option 82
--

eltMesDhcpRelayOption82 OBJECT IDENTIFIER ::= { eltMesDhcpRelay  1}

eltDhcpRelayOption82Policy OBJECT-TYPE
    SYNTAX EltDhcpRelayOption82PolicyType
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION
        "Specifies global DHCP relay option 82 reforwarding policy"
    ::= { eltMesDhcpRelayOption82 1 }

eltDhcpRelayOption82IfPolicyTable OBJECT-TYPE
    SYNTAX  SEQUENCE OF EltDhcpRelayOption82IfPolicyEntry
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION
        "A table of DHCP relay option 82 reforwarding policy for each port
        in the system. Policy stated in an entry of this table has a higher
        priority than global option."
    ::= { eltMesDhcpRelayOption82 2 }

eltDhcpRelayOption82IfPolicyEntry OBJECT-TYPE
    SYNTAX  EltDhcpRelayOption82IfPolicyEntry
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
        "Specifies DHCP relay option 82 policy for port."
    INDEX { eltDhcpRelayOption82IfIndex }
    ::= { eltDhcpRelayOption82IfPolicyTable 1 }

EltDhcpRelayOption82IfPolicyEntry ::= SEQUENCE {
        eltDhcpRelayOption82IfIndex         INTEGER,
        eltDhcpRelayOption82IfPolicy        INTEGER
    }

eltDhcpRelayOption82IfIndex OBJECT-TYPE
    SYNTAX  INTEGER
    MAX-ACCESS  read-only
    STATUS  current
    DESCRIPTION  
        "Port number."
    ::= { eltDhcpRelayOption82IfPolicyEntry 1 }

eltDhcpRelayOption82IfPolicy OBJECT-TYPE
    SYNTAX      INTEGER {
                    replace (1),
                    drop (2),
                    keep (3),
                    global (4)
                }
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
        "DHCP relay option 82 reforwarding policy."
    DEFVAL { 4 }
    ::= {  eltDhcpRelayOption82IfPolicyEntry 2 }

eltDhcpRelayOption82AccessNodeIdentifier OBJECT-TYPE
    SYNTAX DisplayString(SIZE(1..48))
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION    "Specifies an access node identifier"
    ::= { eltMesDhcpRelayOption82 3 }

eltDhcpRelayOption82CircuitIdSuboptionsCombination OBJECT-TYPE
    SYNTAX EltDhcpRelayOption82CombinationType
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION       "Specifies circuit id suboption that will be inserted to packet."
    ::= { eltMesDhcpRelayOption82 4 }

eltDhcpRelayOption82CircuitIdSuboptionsDelimeter OBJECT-TYPE
    SYNTAX EltDhcpRelayOption82DelimiterType
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION       "Specifies a char symbol that will delimit circuit id suboption."
    ::= { eltMesDhcpRelayOption82 5 }

eltDhcpRelayOption82SuboptionType OBJECT-TYPE
    SYNTAX EltDhcpRelayOption82SuboptionType
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION       "Specifies global format of option 82 suboption."
    ::= { eltMesDhcpRelayOption82 6 }

eltDhcpRelayOption82RemoteIdentifier OBJECT-TYPE
    SYNTAX DisplayString(SIZE(1..63))
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION       "Specifies global remote Identifier suboption for Option 82."
    ::= { eltMesDhcpRelayOption82 7 }

eltDhcpRelayOption82CircuitIdSuboptionsUserDefinedTemplate OBJECT-TYPE
    SYNTAX OCTET STRING (SIZE (0..128))
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION
        "An octet string template for user-defined format of
        circuit id suboption that will be inserted to packet."
    ::= { eltMesDhcpRelayOption82 8 }

--
-- DHCP Relay Broadcast Enable
--
--eltDhcpRelayBroadcastEnable OBJECT-TYPE
--    SYNTAX TruthValue
--    MAX-ACCESS read-write
--    STATUS current
--    DESCRIPTION
--        "Enable or disable the of the DHCP relay broadcast subnet forwarding."
--    ::= { eltMesDhcpRelay 2 }


--
-- DHCP Relay Source Port
--

eltDhcpRelaySourcePort OBJECT-TYPE
    SYNTAX INTEGER(0..65535)
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION    "Specifies a DHCP-relay UDP source port"
    DEFVAL {67}
    ::= { eltMesDhcpRelay 3 }
    
--
-- DHCP Relay server table
--
eltDhcpRelayNextServerTable OBJECT-TYPE
    SYNTAX      SEQUENCE OF EltDhcpRelayNextServerEntry
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION
        "The DHCP Relay Next Servers configuration Table."
    ::= { eltMesDhcpRelay 4 }

eltDhcpRelayNextServerEntry OBJECT-TYPE
    SYNTAX      EltDhcpRelayNextServerEntry
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
        "The row definition for this table.
        Parameters of DHCP requests are relayed to the
        specified next server according to vlan interface."
    AUGMENTS    { rlDhcpRelayNextServerEntry }
    ::= { eltDhcpRelayNextServerTable 1 }

EltDhcpRelayNextServerEntry ::= SEQUENCE {
    eltDhcpRelayNextServerListVlanId1To1024      VlanList1,
    eltDhcpRelayNextServerListVlanId1025To2048   VlanList2,
    eltDhcpRelayNextServerListVlanId2049To3072   VlanList3,
    eltDhcpRelayNextServerListVlanId3073To4094   VlanList4
}

eltDhcpRelayNextServerListVlanId1To1024 OBJECT-TYPE
    SYNTAX  VlanList1
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
       " DHCP relay server VlanId List 1."
    ::= { eltDhcpRelayNextServerEntry 1 }

eltDhcpRelayNextServerListVlanId1025To2048 OBJECT-TYPE
    SYNTAX  VlanList2
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
       " DHCP relay server VlanId List 2."
    ::= { eltDhcpRelayNextServerEntry 2 }

eltDhcpRelayNextServerListVlanId2049To3072 OBJECT-TYPE
    SYNTAX  VlanList3
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
       " DHCP relay server VlanId List 3."
    ::= { eltDhcpRelayNextServerEntry 3 }

eltDhcpRelayNextServerListVlanId3073To4094 OBJECT-TYPE
    SYNTAX  VlanList4
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
       " DHCP relay server VlanId List 4."
    ::= { eltDhcpRelayNextServerEntry 4 }

--
-- DHCP Server
--

eltMesDhcpSrv OBJECT IDENTIFIER ::= { eltMesDhcp  2}

--
-- DHCP Server Configuration Parameters
--

--eltDhcpSrvConfParamsTable OBJECT-TYPE
--    SYNTAX  SEQUENCE OF EltDhcpSrvConfParamsEntry
--    MAX-ACCESS read-write
--    STATUS current
--    DESCRIPTION
--        "The DHCP Configuration Parameters Table."
--    ::= { eltMesDhcpSrv 1 }


eltDhcpSrvIpAddrTable OBJECT-TYPE
    SYNTAX      SEQUENCE OF EltDhcpSrvIpAddrEntry
    MAX-ACCESS read-write
    STATUS current
    DESCRIPTION
        "Table of IP Addresses allocated by DHCP Server by static
      and dynamic allocations."
    ::= { eltMesDhcpSrv 2 }
    
eltDhcpSrvIpAddrEntry OBJECT-TYPE
    SYNTAX      EltDhcpSrvIpAddrEntry
    MAX-ACCESS  read-write
    STATUS  current
    DESCRIPTION
        "The row definition for this table.
        Parameters of DHCP allocated IP Addresses table."
    AUGMENTS    { rlDhcpSrvIpAddrEntry }
    ::= { eltDhcpSrvIpAddrTable 1 }

EltDhcpSrvIpAddrEntry ::= SEQUENCE {
    eltDhcpSrvIpAddrHardwareAddress                  PhysAddress
}

eltDhcpSrvIpAddrHardwareAddress OBJECT-TYPE
    SYNTAX PhysAddress 
    MAX-ACCESS read-only
    STATUS current
    DESCRIPTION
        "Physical address of the client."
    ::= { eltDhcpSrvIpAddrEntry 1 }
    
    
--
-- DHCP Route
--

eltDhcpRouteType OBJECT-TYPE
     SYNTAX INTEGER  {
        none(0),
        connected(1),
        static(2)
     }
     MAX-ACCESS      read-write
     STATUS          current
     DESCRIPTION
         "The type of route with which it's added to route table"
    DEFVAL { none }
    ::= { eltMesDhcp 3 } 

END

