From e647ff5af76d3d9c519be38fcaac11f045cd5de6 Mon Sep 17 00:00:00 2001 From: mpana Date: Tue, 12 Jun 2018 11:47:51 +0300 Subject: [PATCH] removed inv for selinux; fixed modedisabled nagios status code --- checks/selinux | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/checks/selinux b/checks/selinux index fa70920..65d654f 100644 --- a/checks/selinux +++ b/checks/selinux @@ -3,7 +3,7 @@ # Author: Marius Pana factory_settings["selinux_default_levels"] = { - "modedisabled" : 0, + "modedisabled" : 2, "curmodepermissive" : 1, "filemodepermissive" : 2, } @@ -12,7 +12,8 @@ def inventory_selinux(info): inventory = [] for line in info: # inventory.append( (line[0], "selinux_default_levels") ) - yield line[0], selinux_default_levels + # yield line[0], selinux_default_levels + yield None # return inventory def check_selinux(item, params, info): @@ -34,7 +35,7 @@ check_info["selinux"] = { "inventory_function" : inventory_selinux, "check_function" : check_selinux, "has_perfdata" : False, - "service_description" : "SELinux status", + "service_description" : "SELinux state", "default_levels_variable" : "selinux_default_levels", 'group': 'selinux', } \ No newline at end of file