From db75806a083478bed864fdf5f9a43b218b7f6b7f Mon Sep 17 00:00:00 2001 From: Mike Salvatore Date: Mon, 19 Sep 2022 12:13:03 -0400 Subject: [PATCH] Agent: Rename _get_server() -> _connect_to_island_api() --- monkey/infection_monkey/monkey.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/monkey/infection_monkey/monkey.py b/monkey/infection_monkey/monkey.py index b1a222af0..034f47295 100644 --- a/monkey/infection_monkey/monkey.py +++ b/monkey/infection_monkey/monkey.py @@ -111,7 +111,7 @@ class InfectionMonkey: self._opts = self._get_arguments(args) # TODO: Revisit variable names - server, island_api_client = self._get_server() + server, island_api_client = self._connect_to_island_api() # TODO: `address_to_port()` should return the port as an integer. self._cmd_island_ip, self._cmd_island_port = address_to_ip_port(server) self._cmd_island_port = int(self._cmd_island_port) @@ -137,7 +137,7 @@ class InfectionMonkey: return opts - def _get_server(self) -> Tuple[str, IIslandAPIClient]: + def _connect_to_island_api(self) -> Tuple[str, IIslandAPIClient]: logger.debug(f"Trying to wake up with servers: {', '.join(self._opts.servers)}") server, island_api_client = find_server(self._opts.servers) if server: