Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion framework/core/commandModules/serialClass.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,5 +200,5 @@ def flush(self) -> bool:
True if can successfully clear the serial console.
"""
self.log.info("Clearing Serial console log")
self.serialCon.flushInput()
self.serialCon.reset_input_buffer()
return True
24 changes: 23 additions & 1 deletion framework/core/commandModules/sshConsole.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,29 @@ def open(self) -> bool:
"""Open the SSH session.
"""
try:
self.console.connect(self.address, username = self.username, password = self.password, key_filename=self.key, port=self.port)
# Prepare password (convert None to empty string for password-less auth)
password = self.password or ''

# Only use key-based auth if a key file is explicitly provided
if self.key:
self.console.connect(
self.address,
username=self.username,
password=password,
key_filename=self.key,
port=self.port
)
else:
# No key file - use password-only auth (disable automatic key discovery)
self.console.connect(
self.address,
username=self.username,
password=password,
port=self.port,
look_for_keys=False, # Don't try to use SSH keys from ~/.ssh
allow_agent=False # Don't try to use SSH agent
)

self.is_open = True
return True
except Exception as e:
Expand Down
Loading