From 8faf8de4dd18af632d76462e253ce38e40469172 Mon Sep 17 00:00:00 2001 From: Mike Salvatore Date: Wed, 14 Sep 2022 12:57:40 -0400 Subject: [PATCH] Agent: Use HardwareID as the return type for get_machine_id() --- monkey/infection_monkey/utils/ids.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/monkey/infection_monkey/utils/ids.py b/monkey/infection_monkey/utils/ids.py index 04f9aea29..a53672b93 100644 --- a/monkey/infection_monkey/utils/ids.py +++ b/monkey/infection_monkey/utils/ids.py @@ -1,5 +1,7 @@ from uuid import UUID, getnode, uuid4 +from common.types import HardwareID + def get_agent_id() -> UUID: """ @@ -17,6 +19,6 @@ def get_agent_id() -> UUID: get_agent_id._id = None -def get_machine_id() -> int: +def get_machine_id() -> HardwareID: """Get an integer that uniquely defines the machine the agent is running on""" return getnode()