DNOS-LDAP-CLIENT-MIB DEFINITIONS ::= BEGIN

IMPORTS
    MODULE-IDENTITY, OBJECT-TYPE, Unsigned32   FROM SNMPv2-SMI
    InetAddress, InetAddressType               FROM INET-ADDRESS-MIB
    RowStatus, TruthValue                      FROM SNMPv2-TC
    SnmpAdminString                            FROM SNMP-FRAMEWORK-MIB
    dnOS                                   FROM DELL-REF-MIB;

agentLdapClientMIB MODULE-IDENTITY
    LAST-UPDATED "201712151200Z" -- 15 Dec 2017 12:00:00 GMT 
    ORGANIZATION "Dell EMC"
    CONTACT-INFO ""

    DESCRIPTION
        "The Broadcom Private MIB for DNOS LDAP client configuration."

      -- Revision history.
    REVISION 
        "201712151200Z"  -- Fri Dec 15 12:00 GMT 2017
    DESCRIPTION 
        "Initial version."

    ::= { dnOS 73 }

    --***********************************************************************
    -- MIB Objects
    --***********************************************************************

    agentLdapClientObjects   OBJECT IDENTIFIER ::= { agentLdapClientMIB 1 }

    --***********************************************************************
    -- agentLdapGlobalConfigGroup -> objects in this group are GlobalConfig 
    -- of the LDAP client. 
    --***********************************************************************
    agentLdapGlobalConfigGroup OBJECT IDENTIFIER
                         ::= { agentLdapClientObjects 1 }

    agentLdapBindFirst OBJECT-TYPE
       SYNTAX      TruthValue
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
          "This is object is set to bind first and then search.
           Default method is to search first and then bind."
       DEFVAL { false }
       ::= { agentLdapGlobalConfigGroup 1 }

    agentLdapAppendWithBaseDN OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(0..255))
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
          "Prefix used to form user DN for bind
           operation."
       DEFVAL { "cn=$userid" }
       ::= { agentLdapGlobalConfigGroup 2 }

    --***********************************************************************
    -- agentLdapGlobalConfigGroup -> objects in this table are for LDAP
    -- server configuration
    --***********************************************************************
    agentLdapServerTable   OBJECT-TYPE
       SYNTAX      SEQUENCE OF  AgentLdapServerEntry
       MAX-ACCESS  not-accessible
       STATUS      current
       DESCRIPTION
           "Table of LDAP server entries"
       ::= { agentLdapClientObjects 2 }

    agentLdapServerEntry OBJECT-TYPE
       SYNTAX      AgentLdapServerEntry
       MAX-ACCESS  not-accessible
       STATUS      current
       DESCRIPTION
           "An entry in the LDAP Server table."
       INDEX     {agentLdapServerIpAddrType, agentLdapServerIpAddress}
       ::= { agentLdapServerTable 1 }

    AgentLdapServerEntry ::=
       SEQUENCE {
          agentLdapServerIpAddrType
              InetAddressType,
          agentLdapServerIpAddress
              InetAddress,
          agentLdapServerStatus
              RowStatus,
          agentLdapServerPort
              Unsigned32,
          agentLdapServerTimeOut
              Unsigned32,
          agentLdapServerSSLMode
              TruthValue,
          agentLdapServerRootDN
              SnmpAdminString,
          agentLdapServerRootDNPassword
              SnmpAdminString
      } 
   
    agentLdapServerIpAddrType OBJECT-TYPE
       SYNTAX      InetAddressType
       MAX-ACCESS  not-accessible
       STATUS      current
       DESCRIPTION
                "The type of address of the LDAP server. 
                 IPv4(1), IPv6(2) and DNS(16) types are supported"
       ::= { agentLdapServerEntry 1 }

    agentLdapServerIpAddress OBJECT-TYPE
       SYNTAX      InetAddress
       MAX-ACCESS  not-accessible
       STATUS      current
       DESCRIPTION
                "The IP address or HostName of the LDAP server."
       ::= { agentLdapServerEntry 2 }

    agentLdapServerStatus OBJECT-TYPE
       SYNTAX      RowStatus 
       MAX-ACCESS  read-create
       STATUS      current
       DESCRIPTION
               "The row status of this entry .
               Supported values:
                   active(1)      - valid entry
                   createAndGo(4) - used to create a new entry
                   destroy(6)     - removes the entry."
       ::= { agentLdapServerEntry 3 }

    agentLdapServerPort OBJECT-TYPE
       SYNTAX      Unsigned32(1..65535)
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
               "The port number of the LDAP server."
       DEFVAL { 389 }
       ::= { agentLdapServerEntry 4 }

    agentLdapServerTimeOut OBJECT-TYPE
       SYNTAX      Unsigned32(1..60)
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
               "The timeout value in seconds for the LDAP server." 
       DEFVAL { 5 }
       ::= { agentLdapServerEntry 5 }

    agentLdapServerSSLMode OBJECT-TYPE
       SYNTAX      TruthValue
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
               "Whether to enable TLS for communicating with LDAP server.
                 true --- Enable TLS
                 false --- Disable TLS"
       DEFVAL { false }
       ::= { agentLdapServerEntry 6 }

    agentLdapServerRootDN OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(0..255))
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
                   "Specifies the root designated name(DN) for LDAP server
                    database."
       ::= { agentLdapServerEntry 7 }

    agentLdapServerRootDNPassword OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(0..64))
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
                   "Specifies the bind password for root DN. This object will  
                    return an empty string even if a password is set."
       ::= { agentLdapServerEntry 8 }

    --***********************************************************************
    -- agentLdapGlobalConfigGroup -> objects in this table are for LDAP
    -- search map configuration
    --***********************************************************************
    agentLdapSearchMapTable  OBJECT-TYPE
      SYNTAX      SEQUENCE OF  AgentLdapSearchMapEntry
      MAX-ACCESS  not-accessible
      STATUS      current
      DESCRIPTION
          "Table of search map entries"
      ::= { agentLdapClientObjects 3 }

    agentLdapSearchMapEntry OBJECT-TYPE
      SYNTAX     AgentLdapSearchMapEntry
      MAX-ACCESS  not-accessible
      STATUS      current
      DESCRIPTION
          "An entry in the search map table."
      INDEX     {agentLdapSearchMapName, agentLdapSearchMapMode}
      ::= { agentLdapSearchMapTable 1 }

    AgentLdapSearchMapEntry ::=
       SEQUENCE {
           agentLdapSearchMapName
                SnmpAdminString,
           agentLdapSearchMapMode
                INTEGER,
           agentLdapSearchMapStatus 
                RowStatus,
           agentLdapSearchMapAttribute
                SnmpAdminString,
           agentLdapSearchMapFilter
                SnmpAdminString,
           agentLdapSearchMapBaseDN
                SnmpAdminString
       }
   
    agentLdapSearchMapName OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(1..64))
       MAX-ACCESS  not-accessible
       STATUS      current
       DESCRIPTION
               "Name of the search map."
       ::= { agentLdapSearchMapEntry 1 }

    agentLdapSearchMapMode OBJECT-TYPE
       SYNTAX      INTEGER {
                             userprofile(1)
                           }
       MAX-ACCESS  not-accessible
       STATUS      current
       DESCRIPTION
               "Search map entry type in the search map. Possible values are :
                userprofile(1)  -  Userprofile."
       DEFVAL { userprofile }
       ::= { agentLdapSearchMapEntry 2 }

    agentLdapSearchMapStatus OBJECT-TYPE
       SYNTAX      RowStatus 
       MAX-ACCESS  read-create
       STATUS      current
       DESCRIPTION
               "The row status of this entry .
               Supported values:
                   active(1)      - valid entry
                   createAndGo(4) - used to create a new entry
                   destroy(6)     - removes the entry."
       ::= { agentLdapSearchMapEntry 3 }

    agentLdapSearchMapAttribute OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(1..64))
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
               "Specifies the LDAP attribute name to be searched."
       ::= { agentLdapSearchMapEntry 4 }

    agentLdapSearchMapFilter OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(0..255))
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
               "Specifies the search filter used in limiting the search result."
       ::= { agentLdapSearchMapEntry 5 }

    agentLdapSearchMapBaseDN OBJECT-TYPE
       SYNTAX      SnmpAdminString (SIZE(0..255))
       MAX-ACCESS  read-write
       STATUS      current
       DESCRIPTION
               "This specifies the base entry in LDAP directory tree where server
                should search. This is used while searching attribute."
       ::= { agentLdapSearchMapEntry 6 }

END
