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 eb6b1fe0 authored by thl-cmk's avatar thl-cmk :flag_na:
Browse files

update project

parent 289fad3d
No related branches found
No related tags found
No related merge requests found
...@@ -9,4 +9,6 @@ ...@@ -9,4 +9,6 @@
2021-02-08: renamed to inv_checkpoint_base 2021-02-08: renamed to inv_checkpoint_base
transfered license/support info to seperate plugin transfered license/support info to seperate plugin
2021-02-22: code cleanup 2021-02-22: code cleanup
2021-03-05: added hostlabel section 2021-03-05: added hostlabel section
\ No newline at end of file 2021-03-18: fixed missing update agent snmp section.
2021-07-24: fixed parse function for empty string_table
\ No newline at end of file
...@@ -5,16 +5,17 @@ ...@@ -5,16 +5,17 @@
# #
# Check Point base inventory # Check Point base inventory
# #
# 2016-06-29 : inventory Check Point Appliance # 2016-06-29: inventory Check Point Appliance
# 2018-03-05 : added Patches, Deployment Agent Build # 2018-03-05: added Patches, Deployment Agent Build
# 2018-03-07 : added Licenses # 2018-03-07: added Licenses
# 2020-06-01 : cleanup, prepared for cmk1.7x, rename from inv_checkpoint_svn to checkpoint_inv_base # 2020-06-01: cleanup, prepared for cmk1.7x, rename from inv_checkpoint_svn to checkpoint_inv_base
# 2020-11-27 : rewrite for CMK check API 1.0 (CMK 2.0) # 2020-11-27: rewrite for CMK check API 1.0 (CMK 2.0)
# 2020-11-28 : added available updates # 2020-11-28: added available updates
# 2021-02-08 : transfered license/support info to seperate plugin # 2021-02-08: transfered license/support info to seperate plugin
# 2021-02-22 : code cleanup # 2021-02-22: code cleanup
# 2021-03-05 : added hostlabel section # 2021-03-05: added hostlabel section
# 2021-03-18 : fixed missing update agent snmp section. # 2021-03-18: fixed missing update agent snmp section.
# 2021-07-24: fixed parse function for empty string_table
# #
# sample string_table # sample string_table
# [ # [
...@@ -27,7 +28,7 @@ ...@@ -27,7 +28,7 @@
# ] # ]
# #
from typing import List, NamedTuple from typing import List, NamedTuple, Optional
from cmk.base.plugins.agent_based.agent_based_api.v1.type_defs import ( from cmk.base.plugins.agent_based.agent_based_api.v1.type_defs import (
HostLabelGenerator, HostLabelGenerator,
...@@ -46,7 +47,7 @@ from cmk.base.plugins.agent_based.agent_based_api.v1 import ( ...@@ -46,7 +47,7 @@ from cmk.base.plugins.agent_based.agent_based_api.v1 import (
) )
def parse_inv_checkpoint_base(string_table: List[StringTable]) -> List: def parse_inv_checkpoint_base(string_table: List[StringTable]) -> Optional[List]:
class CheckpointInvBaseInfo(NamedTuple): class CheckpointInvBaseInfo(NamedTuple):
serialnumber: str serialnumber: str
productname: str productname: str
...@@ -58,6 +59,9 @@ def parse_inv_checkpoint_base(string_table: List[StringTable]) -> List: ...@@ -58,6 +59,9 @@ def parse_inv_checkpoint_base(string_table: List[StringTable]) -> List:
osmajorver: str osmajorver: str
osminorver: str osminorver: str
if string_table == [[], []]:
return
section = [] section = []
baseinfo = CheckpointInvBaseInfo(*string_table[0][0]) baseinfo = CheckpointInvBaseInfo(*string_table[0][0])
......
No preview for this file type
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
'name': 'inv_checkpoint_base', 'name': 'inv_checkpoint_base',
'num_files': 2, 'num_files': 2,
'title': 'Check Point appliance base inventory plugin', 'title': 'Check Point appliance base inventory plugin',
'version': '20210318.v.0.1a', 'version': '202100724.v.0.1a',
'version.min_required': '2.0.0b8', 'version.min_required': '2.0.0b8',
'version.packaged': '2021.07.14', 'version.packaged': '2021.07.14',
'version.usable_until': None} 'version.usable_until': None}
\ No newline at end of file
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