Trap¶
Trap¶
-
class
Trap
(id_unique, name, oid, manufacturer)¶ This class represents a trap
- Parameters
id_unique (int) – ID of the trap
name (str) – Name of the trap
oid (str) – OID of the trap
manufacturer (str) – Manufacturer of the trap
TrapParam¶
-
class
TrapParam
¶ This class represents the parameter of a trap
-
COMMENTS
= 'comments'¶ Comments linked to the trap (str)
-
EXECUTION_COMMAND
= 'execution_command'¶ Command to be executed when trap is received (str)
-
EXECUTION_COMMAND_ENABLE
= 'execution_command_enable'¶ Enable/disable execution command (bool)
-
MATCHING_MODE
= 'matching_mode'¶ Enable/disable the advanced regexp matching mode (bool)
-
NAME
= 'name'¶ Name of the trap (str)
-
OID
= 'oid'¶ OID of the trap (str)
-
OUTPUT
= 'output'¶ Output of the trap (str)
-
RESCHEDULE_SVC_ENABLE
= 'reschedule_svc_enable'¶ Enable/disable rescheduling the service check if trap is received (bool)
-
STATUS
= 'status'¶ Status of the trap (TrapMatchingParam)
-
SUBMIT_RESULT_ENABLE
= 'submit_result_enable'¶ Enable/disable submitting result to service (bool)
-
VENDOR
= 'vendor'¶ Name of the vendor (str)
-
TrapMatching¶
-
class
TrapMatching
(id_unique, string, regexp, status, order)¶ This class represents a matching rule of a trap
- Parameters
id_unique (int) – ID of the matching rule
string (str) – String of the matching rule
regexp (str) – Matching regular expression
status (str) – Status to submit
order (int) – Priority order of the matching rule