Documentation ¶
Index ¶
- Variables
- func GetSNMPOjbect(managementSwitch switches.ManagementSwitch) (snmp *snmpgo.SNMP, err error)
- func MacAddressFromOID(OID string) (macAddress string, err error)
- type MockSNMP
- type RealSNMP
- func (snmpInterface RealSNMP) GetMACPortNameTable(portNumberIfIndexMap map[int]int, ifIndexPortNameMap map[int]string) (macPortMap map[string]string, err error)
- func (snmpInterface RealSNMP) GetPortMap() (portMap map[int]string, err error)
- func (snmpInterface RealSNMP) GetPortNumberMap() (portNumberMap map[int]int, err error)
- type SNMPInterface
Constants ¶
This section is empty.
Variables ¶
var OIDAuthFailure string = "1.3.6.1.6.3.15.1.1.5.0"
OID returned if an authentication fialure occurs.
var OIDMACAddressesNoVLAN = "1.3.6.1.2.1.17.4.3.1.2"
The OID for NON-VLAN mac address table. Only valid if the switch is configured with "enable-dot1d-mibwalk" first!
var OIDMacAddressSourceNoVLAN = "1.3.6.1.2.1.17.4.3.1.3"
The OID for non-VLAN learned-mac sources. Also only valid if configured with "enable-dot1d-mibwalk".
var OIDMacAddressSourceWithVLAN string = "1.3.6.1.2.1.17.7.1.2.2.1.3"
The OID for the source information for VLANs
var OIDMacAddressesWithVLAN string = "1.3.6.1.2.1.17.7.1.2.2.1.2"
The OID for the mac address table (with VLANs - should be there on all switches)
var OIDModelNumber string = "1.3.6.1.2.1.47.1.1.1.1.13.2"
The OID which has the model number of the switch
var OIDPortNumberifIndex string = "1.3.6.1.2.1.17.1.4.1.2"
The OID which maps physical port numbers to ifIndexes
var OIDSysDescr string = "1.3.6.1.2.1.1.1.0"
OID for querying the full name and version identification of a switches software operating-system and networking software.
var OIDifIndexPortNameMap string = "1.3.6.1.2.1.31.1.1.1.1"
The OID which maps ifIndexes to human-readable names
Functions ¶
func GetSNMPOjbect ¶
func GetSNMPOjbect(managementSwitch switches.ManagementSwitch) (snmp *snmpgo.SNMP, err error)
func MacAddressFromOID ¶
Types ¶
type MockSNMP ¶
type MockSNMP struct {
SwitchXname string
}
Generic mock interface for testing.