mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2025-12-07 01:26:11 -08:00
chore: fixed mtscan
This commit is contained in:
@@ -75,19 +75,21 @@ def get_entries(plugin_objects: Plugin_Objects) -> Plugin_Objects:
|
|||||||
host_name = lease.get('host-name')
|
host_name = lease.get('host-name')
|
||||||
comment = lease.get('comment')
|
comment = lease.get('comment')
|
||||||
last_seen = lease.get('last-seen')
|
last_seen = lease.get('last-seen')
|
||||||
|
status = lease.get('status')
|
||||||
|
|
||||||
mylog('verbose', [f"ID: {lease_id}, Address: {address}, MAC Address: {mac_address}, Host Name: {host_name}, Comment: {comment}, Last Seen: {last_seen}"])
|
mylog('verbose', [f"ID: {lease_id}, Address: {address}, MAC Address: {mac_address}, Host Name: {host_name}, Comment: {comment}, Last Seen: {last_seen}, Status: {status}"])
|
||||||
|
|
||||||
plugin_objects.add_object(
|
if (status == "bound"):
|
||||||
primaryId = mac_address,
|
plugin_objects.add_object(
|
||||||
secondaryId = '',
|
primaryId = mac_address,
|
||||||
watched1 = address,
|
secondaryId = '',
|
||||||
watched2 = host_name,
|
watched1 = address,
|
||||||
watched3 = last_seen,
|
watched2 = host_name,
|
||||||
watched4 = '',
|
watched3 = last_seen,
|
||||||
extra = '',
|
watched4 = '',
|
||||||
helpVal1 = comment,
|
extra = '',
|
||||||
foreignKey = mac_address)
|
helpVal1 = comment,
|
||||||
|
foreignKey = mac_address)
|
||||||
|
|
||||||
except TrapError as e:
|
except TrapError as e:
|
||||||
mylog('error', [f"An error occurred: {e}"])
|
mylog('error', [f"An error occurred: {e}"])
|
||||||
|
|||||||
Reference in New Issue
Block a user