Collection of CheckMK checks (see https://checkmk.com/). All checks and plugins are provided as is. Absolutely no warranty. Send any comments to thl-cmk[at]outlook[dot]com

Skip to content
Snippets Groups Projects
Commit 40409221 authored by thl-cmk's avatar thl-cmk :flag_na:
Browse files

update project

parent f1dca09e
No related branches found
No related tags found
No related merge requests found
......@@ -75,8 +75,8 @@ def parse_inv_lldp_cache(string_table: List[StringTable]) -> list:
8: 'WLAN AP',
16: 'Router',
32: 'Phone',
64: 'DOCSIS',
128: 'Station',
64: 'DOCSIS cable device',
128: 'Station only',
}
def render_mac_address(bytestring):
......@@ -88,16 +88,17 @@ def parse_inv_lldp_cache(string_table: List[StringTable]) -> list:
def render_capabilities(bytestring):
if len(bytestring) == 0:
return []
cpapabilites = []
capabilities = []
bytestring = int(ord(bytestring[0]))
# bytestring = bytestring >> 1 # capabilities are one bit of (e.g. L3-Switch has Phone/WLAN instead of Bridge/Router)
for x in lldp_capabilities:
tempcap = lldp_capabilities.get(bytestring & x)
if tempcap != '':
cpapabilites.append(tempcap)
capabilities.append(tempcap)
cpapabilites = str(', '.join(cpapabilites))
# print (bytestring , '/' , cpapabilites)
return cpapabilites
capabilities = str(', '.join(capabilities))
# print (bytestring , '/' , capabilities)
return capabilities
def get_short_if_name(st):
names = {'ethernet': 'Eth',
......
No preview for this file type
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment