From f295c0346a60bc4e8ebe2245426ca968a0b6e40d Mon Sep 17 00:00:00 2001 From: dLoProdz <74804659+dLoProdz@users.noreply.github.com> Date: Mon, 26 Aug 2024 10:47:09 -0600 Subject: [PATCH] Minor changes to the funtionality of Sophos module allowing the user to interact with the main interactive prompt. (#3489) --- netmiko/sophos/sophos_sfos_ssh.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/netmiko/sophos/sophos_sfos_ssh.py b/netmiko/sophos/sophos_sfos_ssh.py index 3d44a7069..df8c8460b 100644 --- a/netmiko/sophos/sophos_sfos_ssh.py +++ b/netmiko/sophos/sophos_sfos_ssh.py @@ -15,7 +15,7 @@ class SophosSfosSSH(NoEnable, NoConfig, CiscoSSHConnection): def session_preparation(self) -> None: """Prepare the session after the connection has been established.""" - self._test_channel_read(pattern=r"Main Menu") + self._test_channel_read(pattern=r"Select Menu Number") """ Sophos Firmware Version SFOS 18.0.0 GA-Build339 @@ -32,9 +32,7 @@ def session_preparation(self) -> None: Select Menu Number [0-7]: """ - self.write_channel(SOPHOS_MENU_DEFAULT + self.RETURN) - self._test_channel_read(pattern=r"[#>]") - self.set_base_prompt() + self.send_command_expect("\r", expect_string=r"Select Menu Number") # Clear the read buffer time.sleep(0.3 * self.global_delay_factor) self.clear_buffer()