-- Copyright 2021 Grandstream Networks, Inc. All Rights Reserved.

GRANDSTREAM-GWN-PRODUCTS-SWITCH-MIB DEFINITIONS ::= BEGIN

IMPORTS
    gwnProducts
	FROM GRANDSTREAM-GWN-ROOT-MIB
	MODULE-IDENTITY,
	NOTIFICATION-TYPE,
	OBJECT-TYPE,
	Integer32,
	Counter32,
	Unsigned32
			FROM SNMPv2-SMI
	TEXTUAL-CONVENTION,
	DisplayString,
	TimeStamp,
	TruthValue,
	RowStatus,MacAddress
			FROM SNMPv2-TC
	MODULE-COMPLIANCE,
	OBJECT-GROUP,
	NOTIFICATION-GROUP
			FROM SNMPv2-CONF
	SnmpAdminString
			FROM SNMP-FRAMEWORK-MIB;


gwnSwitchMIB MODULE-IDENTITY
        LAST-UPDATED    "202312231201Z"
        ORGANIZATION    "Grandstream Networks, Inc."
        CONTACT-INFO 	""
        DESCRIPTION     "Grandstream product switch mib."
        ::= { gwnProducts 4 }

-- 1.3.6.1.4.1.42397.1.4.1
gwnSwitchSyslogMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "Grandstream switch syslog module mib"
    ::= { gwnSwitchMIB 1 }

-- Textual Conventions

SyslogSeverity ::= TEXTUAL-CONVENTION
       STATUS  current
       DESCRIPTION
               "The severity of a syslog message.

                 'emergency' : system is unusable
                 'alert'     : action must be taken immediately
                 'critical'  : critical conditions
                 'error'     : error conditions
                 'warning'   : warning conditions
                 'notice'    : normal but significant condition
                 'informational': informational messages
                 'debug'        : debug-level messages."
       REFERENCE
           "RFC 3164, Section 4.1 - syslog Message Parts"
       SYNTAX  INTEGER {    emergency(0),
                            alert(1),
                            critical(2),
                            error(3),
                            warning(4),
                            notice(5),
                            info(6),
                            debug(7)
                }

-- Textual Conventions

EnableValue ::= TEXTUAL-CONVENTION
       STATUS  current
       DESCRIPTION
               "Indicates whether the function is enabled or the
			   current running status"
       REFERENCE
           ""
       SYNTAX  INTEGER {    disable(0),
                            enable(1)}

logInfoObjects     OBJECT IDENTIFIER
    ::= { gwnSwitchSyslogMIB 1 }

logInfoFacility OBJECT-TYPE
        SYNTAX     DisplayString (SIZE (1..20))
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                "Name of the facility that generated this message.
                 For example: 'SYS'."
        ::= { logInfoObjects 2 }

logInfoSeverity OBJECT-TYPE
        SYNTAX     SyslogSeverity
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                "The severity of the message."
        ::= { logInfoObjects 3 }

logInfotMsgText OBJECT-TYPE
        SYNTAX     DisplayString (SIZE (1..255))
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                "The text of the message.  If the text of the message
                 exceeds 255 bytes, the message will be truncated to
                 254 bytes and a '*' character will be appended -
                 indicating that the message has been truncated."
        ::= { logInfoObjects 4 }

logInfoTimestamp OBJECT-TYPE
        SYNTAX     DisplayString (SIZE (1..20))
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                "The time of the message."
        ::= { logInfoObjects 5 }

-- notifications

syslogMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSwitchSyslogMIB 2 }
syslogMIBNotifications         OBJECT IDENTIFIER
                              ::= { syslogMIBNotificationPrefix 0 }

logMessageGenerated NOTIFICATION-TYPE
        OBJECTS { logInfoFacility,
                  logInfoSeverity,
                  logInfoMsgText,
                  logInfoTimestamp
        }
        STATUS     current
        DESCRIPTION
                "When a syslog message is generated by the device a
                 logMessageGenerated notification is sent.  The
                 sending of these notifications can be enabled/disabled
                 via the clogNotificationsEnabled object."
        ::= { syslogMIBNotifications 1 }

-- 1.3.6.1.4.1.42397.1.4.2
gwnSwitchAlarmMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "Grandstream switch alarm module mib"
    ::= { gwnSwitchMIB 2 }


-- Textual Conventions

AlarmEntryName ::= TEXTUAL-CONVENTION
       STATUS  current
       DESCRIPTION
               "Alarm item Name:
				cpu-high 		- The cpu usage
				memory-high 	- The memory usage
				poe-poweruse 	- The poe total power usage
				mac-limit 		- L2 MAC address table entry usage
				temp-high 		- Device temperature is too high
				fan-fault 		- Fan failure
				poe-chipfault 	- poe chip is faulty,Unable to operate
				mainpowerfault 	- The main power supply of the dual-power device is faulty
			   "
       REFERENCE
			""
       SYNTAX  INTEGER {    cpu-high(1),
					memory-high(2),
					poe-poweruse(3),
					mac-limit(4),
					temp-high(5),
					fan-fault(6),
					poe-chipfault(7),
					mainpowerfault(8)
				}

alarmBasic  OBJECT IDENTIFIER
    ::= { gwnSwitchAlarmMIB 1 }

alarmConfigTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF alarmConfigEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
            ""
    ::= { alarmBasic 1 }

alarmConfigEntry OBJECT-TYPE
        SYNTAX     alarmConfigEntry
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                ""
        INDEX   { alarmCfgIndex }
        ::= { alarmConfigTable 1 }

alarmConfigEntry ::=
    SEQUENCE {
        alarmCfgIndex 	      	 AlarmEntryName,
        alarmCfgEnable    		 EnableValue,
        alarmCfgSeverity  		 SyslogSeverity,
        alarmCfgAlarmThreshold   Integer32,
        alarmCfgAlarmDelay       Integer32,
        alarmCfgNormalThreshold  Integer32,
		alarmCfgNormalDelay  	 Integer32
    }

alarmCfgIndex OBJECT-TYPE
	SYNTAX      	AlarmEntryName
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION     ""
    ::= { alarmConfigEntry 1 }

alarmCfgEnable OBJECT-TYPE
    SYNTAX          EnableValue
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmConfigEntry 2 }

alarmCfgSeverity OBJECT-TYPE
    SYNTAX          SyslogSeverity
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmConfigEntry 3 }

alarmCfgAlarmThreshold OBJECT-TYPE
    SYNTAX          Integer32 (1..65535)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmConfigEntry 4 }

alarmCfgAlarmDelay OBJECT-TYPE
    SYNTAX          Integer32 (1..600)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmConfigEntry 5 }

alarmCfgNormalThreshold OBJECT-TYPE
    SYNTAX          Integer32 (1..65535)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmConfigEntry 6 }

alarmCfgNormalDelay OBJECT-TYPE
    SYNTAX          Integer32 (1..600)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmConfigEntry 7 }

alarmStatusTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF alarmStatusEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
            ""
    ::= { alarmBasic 2 }

alarmStatusEntry OBJECT-TYPE
        SYNTAX     alarmStatusEntry
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                ""
        INDEX   { alarmCfgIndex }
        ::= { alarmStatusTable 1 }

alarmStatusEntry ::=
    SEQUENCE {
        alarmStatusNow   		     EnableValue,
        LastAlarmTime  		 		 DisplayString,
        LastAlarmValue    			 Integer32,
        LastNormalTime        		 DisplayString,
        LastNormalValue   			 Integer32,
		AlarmCount  	 		     Integer32
    }

alarmStatusNow OBJECT-TYPE
    SYNTAX          EnableValue
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmStatusEntry 1 }

LastAlarmTime OBJECT-TYPE
    SYNTAX          DisplayString (SIZE (1..20))
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmStatusEntry 2 }

LastAlarmValue OBJECT-TYPE
    SYNTAX          Integer32 (1..65535)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmStatusEntry 3 }

LastNormalTime OBJECT-TYPE
    SYNTAX          DisplayString (SIZE (1..20))
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmStatusEntry 4 }

LastNormalValue OBJECT-TYPE
    SYNTAX          Integer32 (1..65535)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmStatusEntry 5 }

AlarmCount OBJECT-TYPE
    SYNTAX          Integer32 (1..2147483647)
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION  	""
    ::= { alarmStatusEntry 6 }

-- notifications

alarmMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSwitchAlarmMIB 2 }
alarmMIBNotifications         OBJECT IDENTIFIER
                              ::= { alarmMIBNotificationPrefix 0 }

alarmMessageGenerated NOTIFICATION-TYPE
        OBJECTS { alarmCfgSeveritys,
				  alarmCfgAlarmThreshold,
				  LastAlarmTime,
                  LastAlarmValue,
                  AlarmCount
        }
        STATUS     current
        DESCRIPTION
                "When an alarm is generated, a trap is generated"
        ::= { alarmMIBNotifications 1 }

normalMessageGenerated NOTIFICATION-TYPE
        OBJECTS { alarmCfgSeveritys,
				  alarmCfgNormalThreshold,
				  LastNormalTime,
                  LastNormalValue,
                  AlarmCount
        }
        STATUS     current
        DESCRIPTION
                "When the alarm is cleared, a trap is generated"
        ::= { alarmMIBNotifications 2 }


-- Textual Conventions

ErrDisableFeatureID ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
        "An integer-value assigned to various features/events
		that can error disable a system entity"
    SYNTAX          INTEGER  {
						bpdu(1),
                        udld(2),
						selfLoop(3),
						bcastFlood(4),
						mcastFlood(5),
						ucastFlood(6),
						acl(7),
						portSec(8),
						dhcpRate(9),
						arpInspect(10),
						dhcpv6Rate(11),
						selfloopDetect(12)
                    }

-- 1.3.6.1.4.1.42397.1.4.3
gwnSwitchErrDisableMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "Grandstream switch syslog module mib"
    ::= { gwnSwitchMIB 3 }

errDisableIfStatusTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF errDisableIfStatusEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "This table provides interface (port) specific
        error-disable status information. Each conceptual row
        provides status information about a {interface}
        disabled by a feature."
    ::= { gwnSwitchErrDisableMIB 1 }

errDisableIfStatusEntry OBJECT-TYPE
    SYNTAX          errDisableIfStatusEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "A collection of objects that specify the status of an
        error-disabled Interface"
    INDEX           {ifIndex}
    ::= { errDisableIfStatusTable 1 }

errDisableIfStatusEntry ::= SEQUENCE {
        errDisableIfStatusCause        ErrDisableFeatureID,
}

errDisableIfStatusCause OBJECT-TYPE
    SYNTAX          ErrDisableFeatureID
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "This object specifies the feature/event that caused the
        interface to be error-disabled."
    ::= { errDisableIfStatusEntry 1 }

-- notifications

errDisableMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSwitchErrDisableMIB 2 }
errDisableMIBNotifications         OBJECT IDENTIFIER
                              ::= { errDisableMIBNotificationPrefix 0 }

alarmMessageGenerated NOTIFICATION-TYPE
        OBJECTS { errDisableIfStatusCause        }
        STATUS     current
        DESCRIPTION
                ""
        ::= { errDisableMIBNotifications 1 }

-- Textual Conventions

VlanIndex ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
        "The VLAN-id of a VLAN on ISL or 802.1q trunks."
    SYNTAX          Integer32 (0..4095)

-- 1.3.6.1.4.1.42397.1.4.4
gwnSwitchvlanMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "Grandstream switch vlan module mib"
    ::= { gwnSwitchMIB 4 }

vlanTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF vlanEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "This table contains information on the VLANs which
        currently exist."
    ::= { gwnSwitchvlanMIB 1 }

vlanEntry OBJECT-TYPE
    SYNTAX          vlanEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        ""
    INDEX           {vlanIndex}
    ::= { vlanTable 1 }

vlanEntry ::= SEQUENCE {
       vlanIndex              	 VlanIndex,
       vlanName               	DisplayString
}

vlanIndex OBJECT-TYPE
    SYNTAX          VlanIndex
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "The VLAN-id of this VLAN on ISL or 802.1q trunks."
    ::= { vlanEntry 1 }

vlanName OBJECT-TYPE
    SYNTAX          DisplayString (SIZE  (1..32))
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "The name of this VLAN."
    ::= { vlanEntry 2 }

-- notifications

vlanMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSwitchvlanMIB 2 }
vlanMIBNotifications         OBJECT IDENTIFIER
                              ::= { vlanMIBNotificationPrefix 0 }

vlanCreated NOTIFICATION-TYPE
        OBJECTS { vlanName       }
        STATUS     current
        DESCRIPTION
                ""
        ::= { vlanMIBNotifications 1 }

vlanDeleted NOTIFICATION-TYPE
        OBJECTS { vlanName       }
        STATUS     current
        DESCRIPTION
                ""
        ::= { vlanMIBNotifications 2 }

-- 1.3.6.1.4.1.42397.1.4.5
gwnSportSecurityMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "Grandstream switch port Security  module mib"
    ::= { gwnSwitchMIB 5}

portSecurityBasic  OBJECT IDENTIFIER
    ::= { gwnSportSecurityMIB 1 }

psIfConfigTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF psIfConfigEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
            ""
    ::= { portSecurityBasic 1 }

psIfConfigEntry OBJECT-TYPE
        SYNTAX     psIfConfigEntry
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                ""
        INDEX   { ifIndex }
        ::= { psIfConfigTable 1 }

psIfConfigEntry ::=
    SEQUENCE {
        psIfSecureLastMacAddress       MacAddress,
    }

psIfSecureLastMacAddress OBJECT-TYPE
        SYNTAX        MacAddress
        MAX-ACCESS    not-accessible
        STATUS        current
        DESCRIPTION   "This object indicates the last MAC
                      address that is seen on this interface.

                      This object is also used as a variable in
                      the psSecureMacAddrViolation notification
                      to contain the value of the MAC address
                      which caused the violation."
        ::= { psIfConfigEntry 1 }

-- notifications

psMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSportSecurityMIB 2 }
psMIBNotifications         OBJECT IDENTIFIER
                              ::= { psMIBNotificationPrefix 0 }

psSecureMacAddrViolation NOTIFICATION-TYPE
        OBJECTS { psIfSecureLastMacAddress }
        STATUS     current
        DESCRIPTION
                ""
        ::= { psMIBNotifications 1 }

-- 1.3.6.1.4.1.42397.1.4.6
gwnSmacNotificationMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "This MIB module is for configuration of the MAC notification
 	feature. MAC notification is a mechanism to inform monitoring
 	devices when there are MAC addresses learnt or removed from
 	the forwarding database of the monitored devices"
    ::= { gwnSwitchMIB 6}

macNotificationBasic  OBJECT IDENTIFIER
    ::= { gwnSmacNotificationMIB 1 }

macNotificationObjects     OBJECT IDENTIFIER
    ::= { macNotificationBasic 1 }

mnEventMACAddress OBJECT-TYPE
     SYNTAX          MacAddress
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { macNotificationObjects 1 }

mnEventFromPort OBJECT-TYPE
     SYNTAX          Integer32 (1..128)
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { macNotificationObjects 2 }

mnEventToPort OBJECT-TYPE
     SYNTAX          Integer32 (1..128)
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { macNotificationObjects 3 }

mnEventVlan OBJECT-TYPE
    SYNTAX          VlanIndex
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "The VLAN-id of this VLAN on ISL or 802.1q trunks."
    ::= { macNotificationObjects 4 }

-- notifications

mnMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSmacNotificationMIB 2 }
mnMIBNotifications         OBJECT IDENTIFIER
                              ::= { mnMIBNotificationPrefix 0 }

mnMacLearnNotification NOTIFICATION-TYPE
        OBJECTS {
				   mnEventFromPort,
				   mnEventMACAddress,
				   mnEventVlan
				}
        STATUS     current
        DESCRIPTION
                ""
        ::= { mnMIBNotifications 1 }

mnMacRemovedNotification NOTIFICATION-TYPE
        OBJECTS {
				    mnEventFromPort,
				    mnEventMACAddress,
				    mnEventVlan
				}
        STATUS     current
        DESCRIPTION
                ""
        ::= { mnMIBNotifications 2 }

mnMacMoveNotification NOTIFICATION-TYPE
        OBJECTS {
					mnEventFromPort,
					mnEventToPort,
				    mnEventMACAddress,
					mnEventVlan
				}
        STATUS     current
        DESCRIPTION
                ""
        ::= { mnMIBNotifications 3 }




-- Textual Conventions

ConfigEventMedium ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
            "The source or destination of a configuration change,
            save, or copy.

            erase            erasing destination (source only)
            running          live operational data
            commandSource    the command source itself
            startup          what the system will use next reboot
            local            local NVRAM or flash
            networkTftp      network host via Trivial File Transfer
            "
    SYNTAX          INTEGER  {
                        erase(1),
                        commandSource(2),
                        running(3),
                        startup(4),
                        local(5),
                        networkTftp(6)
                    }

ConfigEventChannel ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
            "Configure the operation channel.

            cli     Use the command line to perform operations
            web     Configure using the cgi interface
            snmp    Using snmp configuration
            "
    SYNTAX          INTEGER  {
                        cli(1),
                        web(2),
                        snmp(3)
                    }

-- 1.3.6.1.4.1.42397.1.4.7
gwnSwitchConfigMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "Configuration management MIB"
    ::= { gwnSwitchMIB 7}

configBasicObjects     OBJECT IDENTIFIER
    ::= { gwnSwitchConfigMIB 1 }

configEventObjects     OBJECT IDENTIFIER
    ::= { configBasicObjects 1 }

configEventChannel OBJECT-TYPE
     SYNTAX          ConfigEventChannel
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { configEventObjects 1 }

configEventSource OBJECT-TYPE
     SYNTAX          ConfigEventMedium
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { configEventObjects 2 }

configEventDest OBJECT-TYPE
     SYNTAX          ConfigEventMedium
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { configEventObjects 3 }


-- notifications

configMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnSwitchConfigMIB 2 }
configMIBNotifications         OBJECT IDENTIFIER
                              ::= { configMIBNotificationPrefix 0 }

cfgEventNotification NOTIFICATION-TYPE
        OBJECTS {
					configEventChannel,
				    configEventSource,
					configEventDest
				}
        STATUS     current
        DESCRIPTION
                ""
        ::= { configMIBNotifications 1 }


-- Textual Conventions

poePortEventType ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
            "Indicates the type of the event that causes the status of the POE port to change.

				disconnect 		A device disconnect is detected
				disconnect 		The device starts to supply power to PD
				currentOver 	The power supply stops because the port current is too high
				mainPowerOver   If the total device power usage exceeds the threshold,
								power off the port with a lower priority
            "
    SYNTAX          INTEGER  {
                        disconnect(1),
                        powerOn(2),
                        currentOver(3),
						mainPowerOver(4)
                    }

-- 1.3.6.1.4.1.42397.1.4.8
gwnPowerEthernetExtMIB MODULE-IDENTITY
    LAST-UPDATED "202312231201Z"
    ORGANIZATION "Grandstream Networks, Inc."
    CONTACT-INFO ""
    DESCRIPTION
    "A MIB module for extending the POWER-ETHERNET-MIB
	(RFC3621) to add objects which provide additional management
	information about Power Sourcing Equipment (PSE)
	not available in POWER-ETHERNET-MIB."
    ::= { gwnSwitchMIB 8}

poeExtObjects     OBJECT IDENTIFIER
    ::= { gwnPowerEthernetExtMIB 1 }

poeExtPortEventTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF poeExtPortEventEntry
    MAX-ACCESS      not-accessible
	STATUS          current
    DESCRIPTION
            ""
    ::= { poeExtObjects 1 }

poeExtPortEventEntry OBJECT-TYPE
        SYNTAX     poeExtPortEventEntry
        MAX-ACCESS not-accessible
        STATUS     current
        DESCRIPTION
                ""
        INDEX   { ifIndex }
        ::= { poeExtPortEventTable 1 }

poeExtPortEventEntry ::=
    SEQUENCE {
        poeExtPortEventType       poePortEventType,
    }

poeExtPortEventType OBJECT-TYPE
     SYNTAX          poePortEventType
     MAX-ACCESS      not-accessible
     STATUS          current
     DESCRIPTION
         ""
    ::= { poeExtPortEventEntry 1 }

-- notifications

poeMIBNotificationPrefix    OBJECT IDENTIFIER
                              ::= { gwnPowerEthernetExtMIB 2 }
poeMIBNotifications         OBJECT IDENTIFIER
                              ::= { poeMIBNotificationPrefix 0 }

cfgEventNotification NOTIFICATION-TYPE
        OBJECTS {
					poeExtPortEventType
				}
        STATUS     current
        DESCRIPTION
                ""
        ::= { poeMIBNotifications 1 }

gwnSwitchOpticalMIB MODULE-IDENTITY
        LAST-UPDATED    "202403201201Z"
        ORGANIZATION    "Grandstream Networks, Inc."
        CONTACT-INFO 	""
        DESCRIPTION     "Grandstream product switch optical mib."
        ::= { gwnSwitchMIB 9 }

-- 1.3.6.1.4.1.42397.1.4.9.1
gwnEntityState OBJECT IDENTIFIER ::= { gwnSwitchOpticalMIB 1 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1
gwnOpticalModuleInfoTable OBJECT-TYPE
	SYNTAX SEQUENCE OF GwnOpticalModuleInfoEntry
	MAX-ACCESS not-accessible
	STATUS current
	DESCRIPTION
		"Table of optical module properties."
	::= { gwnEntityState 1 }
	
-- 1.3.6.1.4.1.42397.1.4.9.1.1.1
gwnOpticalModuleInfoEntry OBJECT-TYPE
	SYNTAX GwnOpticalModuleInfoEntry
	MAX-ACCESS not-accessible
	STATUS current
	DESCRIPTION
		"An entry in the table of optical module properties for each optical module."
	INDEX { ifIndex }
	::= { gwnOpticalModuleInfoTable 1 }

GwnOpticalModuleInfoEntry ::=
	SEQUENCE { 
		gwnEntityOpticalOEpresent
			DisplayString,
		gwnEntityOpticalSignalStatus
			DisplayString,
		gwnEntityOpticalTransceiverType
			DisplayString,
		gwnEntityOpticalConnectorType
			DisplayString,
		gwnEntityOpticalEcc
			DisplayString,
		gwnEntityOpticalTransMedia
			DisplayString,
		gwnEntityOpticalWavelength
			Integer32,
		gwnEntityOpticalBitRate
			Integer32,
		gwnEntityOpticalVendorOUI
			DisplayString,
		gwnEntityOpticalVenderName
			DisplayString,
		gwnEntityOpticalVenderPn
			DisplayString,
		gwnEntityOpticalVenderRevision
			DisplayString,
		gwnEntityOpticalVendorSn
			DisplayString,
		gwnEntityOpticalTemperature
			DisplayString,
		gwnEntityOpticalTemThreshold
			DisplayString,
		gwnEntityOpticalVoltage
			DisplayString,
		gwnEntityOpticalVoltageThreshold
			DisplayString,
		gwnEntityOpticalBiasCurrent
			DisplayString,
		gwnEntityOpticalBiasCurrentThreshold
			DisplayString,
		gwnEntityOpticalTxPower
			DisplayString,
		gwnEntityOpticalTxPowerThreshold
			DisplayString,
		gwnEntityOpticalRxPower
			DisplayString,
		gwnEntityOpticalRxPowerThreshold
			DisplayString
}

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.1
gwnEntityOpticalOEpresent OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The OE present of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 1 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.2
gwnEntityOpticalSignalStatus OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The signal status of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 2 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.3
gwnEntityOpticalTransceiverType OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The transceiver Type of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 3 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.4
gwnEntityOpticalConnectorType OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The connector Type of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 4 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.5
gwnEntityOpticalEcc OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The ethernet Compliance Code of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 5 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.6
gwnEntityOpticalTransMedia OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The transmission media of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 6 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.7
gwnEntityOpticalWavelength OBJECT-TYPE
	SYNTAX Integer32
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The wave length of the optical module. Unit: nm"
	::= { gwnOpticalModuleInfoEntry 7 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.8
gwnEntityOpticalBitRate OBJECT-TYPE
	SYNTAX Integer32
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The bit rate of the optical module. Unit: bit"
	::= { gwnOpticalModuleInfoEntry 8 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.9
gwnEntityOpticalVendorOUI OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The vender OUI of the optical module. Unit: bit"
	::= { gwnOpticalModuleInfoEntry 9 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.10
gwnEntityOpticalVenderName OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The Vender Name of the optical module."
	::= { gwnOpticalModuleInfoEntry 10 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.11
gwnEntityOpticalVenderPn OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The Vender PN of the optical module."
	::= { gwnOpticalModuleInfoEntry 11 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.12
gwnEntityOpticalVenderRevision OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The vender revision of the optical module."
	::= { gwnOpticalModuleInfoEntry 12 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.13
gwnEntityOpticalVendorSn OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The vendor serial number (vendor SN) of the optical module. Length: 16 bytes."
	::= { gwnOpticalModuleInfoEntry 13 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.14
gwnEntityOpticalTemperature OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The current temperature of the optical module. Unit: C"
	::= { gwnOpticalModuleInfoEntry 14 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.15
gwnEntityOpticalTemThreshold OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The current temperature threshold of the optical module. Unit: C"
	::= { gwnOpticalModuleInfoEntry 15 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.16
gwnEntityOpticalVoltage OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The current voltage of the optical module. Unit: V"
	::= { gwnOpticalModuleInfoEntry 16 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.17
gwnEntityOpticalVoltageThreshold OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The current voltage threshold of the optical module. Unit: V"
	::= { gwnOpticalModuleInfoEntry 17 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.18
gwnEntityOpticalBiasCurrent OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The bias current of the optical module. Unit: mA"
	::= { gwnOpticalModuleInfoEntry 18 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.19
gwnEntityOpticalBiasCurrentThreshold OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The bias current threshold of the optical module. Unit: mA"
	::= { gwnOpticalModuleInfoEntry 19 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.20
gwnEntityOpticalTxPower OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The transmit power of the optical module. Unit: dBm"
	::= { gwnOpticalModuleInfoEntry 20 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.21
gwnEntityOpticalTxPowerThreshold OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The transmit power threshold of the optical module. Unit: dBm"
	::= { gwnOpticalModuleInfoEntry 21 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.22
gwnEntityOpticalRxPower OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The receive power of the optical module. Unit: dBm"
	::= { gwnOpticalModuleInfoEntry 22 }

-- 1.3.6.1.4.1.42397.1.4.9.1.1.1.23
gwnEntityOpticalRxPowerThreshold OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The receive power threshold of the optical module. Unit: dBm"
	::= { gwnOpticalModuleInfoEntry 23 }

gwnSwitchFanMIB MODULE-IDENTITY
        LAST-UPDATED    "202403201201Z"
        ORGANIZATION    "Grandstream Networks, Inc."
        CONTACT-INFO 	""
        DESCRIPTION     "Grandstream product switch fan mib."
        ::= { gwnSwitchMIB 10 }

-- 1.3.6.1.4.1.42397.1.4.10.1
gwnFanInfo OBJECT IDENTIFIER ::= { gwnSwitchFanMIB 1 }

-- 1.3.6.1.4.1.42397.1.4.10.1.1
gwnFan1 OBJECT-TYPE
    SYNTAX DisplayString
    MAX-ACCESS read-only
    STATUS current
    DESCRIPTION "gwnFan 1."
    ::= { gwnFanInfo 1 }

-- 1.3.6.1.4.1.42397.1.4.10.1.2
gwnFan2 OBJECT-TYPE
    SYNTAX DisplayString
    MAX-ACCESS read-only
    STATUS current
    DESCRIPTION "gwnFan 2."
    ::= { gwnFanInfo 2 }

-- 1.3.6.1.4.1.42397.1.4.10.1.3
gwnFan3 OBJECT-TYPE
    SYNTAX DisplayString
    MAX-ACCESS read-only
    STATUS current
    DESCRIPTION "gwnFan 3."
    ::= { gwnFanInfo 3 }

-- 1.3.6.1.4.1.42397.1.4.10.1.4
gwnFan4 OBJECT-TYPE
    SYNTAX DisplayString
    MAX-ACCESS read-only
    STATUS current
    DESCRIPTION "gwnFan 4."
    ::= { gwnFanInfo 4 }

gwnSwitchPortTrafficStatusMIB MODULE-IDENTITY
        LAST-UPDATED    "202403201201Z"
        ORGANIZATION    "Grandstream Networks, Inc."
        CONTACT-INFO 	""
        DESCRIPTION     "Grandstream product switch port traffic status mib."
        ::= { gwnSwitchMIB 11 }

-- 1.3.6.1.4.1.42397.1.4.11.1
gwnTrafficStatusEntityState OBJECT IDENTIFIER ::= { gwnSwitchPortTrafficStatusMIB 1 }

-- 1.3.6.1.4.1.42397.1.4.11.1.1
gwnPortTrafficStatusModuleInfoTable OBJECT-TYPE
	SYNTAX SEQUENCE OF GwnPortTrafficStatusModuleInfoEntry
	MAX-ACCESS not-accessible
	STATUS current
	DESCRIPTION
		"Table of port traffic status."
	::= { gwnTrafficStatusEntityState 1 }

-- 1.3.6.1.4.1.42397.1.4.11.1.1.1
gwnPortTrafficStatusModuleInfoEntry OBJECT-TYPE
	SYNTAX GwnPortTrafficStatusModuleInfoEntry
	MAX-ACCESS not-accessible
	STATUS current
	DESCRIPTION
		"An entry in the traffic status module table for each port."
	INDEX { ifIndex }
	::= { gwnPortTrafficStatusModuleInfoTable 1 }

GwnPortTrafficStatusModuleInfoEntry ::=
	SEQUENCE {
		gwnEntityPortInRate     DisplayString,
		gwnEntityPortInPktRate  DisplayString,
        gwnEntityPortOutRate    DisplayString,
		gwnEntityPortOutPktRate DisplayString
}

-- 1.3.6.1.4.1.42397.1.4.11.1.1.1.1
gwnEntityPortInRate OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The input rate of the port traffic status module. Length :8 bytes."
	::= { gwnPortTrafficStatusModuleInfoEntry 1 }

-- 1.3.6.1.4.1.42397.1.4.11.1.1.1.2
gwnEntityPortInPktRate OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The value of the incoming packet rate of the port traffic status module. Length :8 bytes."
	::= { gwnPortTrafficStatusModuleInfoEntry 2 }

-- 1.3.6.1.4.1.42397.1.4.11.1.1.1.3
gwnEntityPortOutRate OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"Output rate of the port traffic status module. Length :8 bytes."
	::= { gwnPortTrafficStatusModuleInfoEntry 3 }

-- 1.3.6.1.4.1.42397.1.4.11.1.1.1.4
gwnEntityPortOutPktRate OBJECT-TYPE
	SYNTAX DisplayString (SIZE (0..120))
	MAX-ACCESS read-only
	STATUS current
	DESCRIPTION
		"The value of the output packet rate of the port traffic status module. Length :8 bytes."
	::= { gwnPortTrafficStatusModuleInfoEntry 4 }

gwnSystemTemperMIB MODULE-IDENTITY
        LAST-UPDATED    "202403201201Z"
        ORGANIZATION    "Grandstream Networks, Inc."
        CONTACT-INFO 	""
        DESCRIPTION     "Grandstream product switch system temperature mib."
        ::= { gwnSwitchMIB 12 }

-- 1.3.6.1.4.1.42397.1.4.12.1
gwnSystemTemperEntityState OBJECT IDENTIFIER ::= { gwnSystemTemperMIB 1 }

-- 1.3.6.1.4.1.42397.1.4.12.1.1
gwnSystemTemper OBJECT-TYPE
    SYNTAX DisplayString
    MAX-ACCESS read-only
    STATUS current
    DESCRIPTION "Gwn System temperature."
    ::= { gwnSystemTemperEntityState 1 }

END
