When running Test Connectivity for an SSH asset in SOAR, the test may fail even though SSH login from the CLI works successfully using the same credentials.
This issue may occur because Paramiko (the SSH library used by the SSH app) searches for and attempts to use any private key files located under the phantom user’s home directory (/home/phantom/.ssh/) before trying the configured password.
If any of those local keys are invalid or unrelated, the target server rejects the key-based authentication, and Paramiko never proceeds to the password step — resulting in the authentication failure. Removing or renaming these leftover SSH keys resolves the issue.
Run Test Connectivity on the SSH asset. The action output will look like this:
App 'SSH' started successfully (id: 1757584212645) on asset: 'test_router_connection'(id: 188)
Loaded action execution configuration
Testing SSH Connection
Connecting to 10.200.100.56...
Test Connectivity failed
1 action failed Authentication failed, please verify your credentials
Inspect /opt/phantom/var/log/phantom/spawn.log, you should see output similar to:
2025-09-16T11:57:34.516801 PID:617974 TID:617974 : DEBUG: SPAWN3 : Input JSON to the py module:
{
"action" : "test connectivity",
"asset_id" : "188",
"config" : {
"app_version" : "2.4.9",
"ip_hostname" : "10.200.100.56",
"username" : "mysoc"
}
}
2025-09-16T11:57:34.763339 PID:617974 TID:617974 : DEBUG: SPAWN3 : Connecting to 10.200.100.56...
2025-09-16T11:57:37.249316 PID:617974 TID:617974 : DEBUG: SPAWN3 : Test Connectivity failed
2025-09-16T11:57:37.249316 PID:617974 TID:617974 : ERROR: SPAWN3 : Authentication failed, please verify your credentials
Create two new test assets that connect to other reachable hosts, which can prove that the SSH connector is functioning as normal.
If only the connection to 10.200.100.56 fails, this confirms the issue is not with Paramiko or network routing in general, but with how Paramiko authenticates to that specific target.
List the .ssh directory contents for the phantom user:
sudo -u phantom ls -la /home/phantom/.ssh/
If private keys exist, Paramiko will automatically attempt to use them (look_for_keys=True by default).
Confirm that the same credentials work manually:
sudo -u phantom ssh mysoc@10.200.100.56
If this succeeds, the credentials and network are valid — the issue lies in Paramiko’s authentication order.
Rename or remove the .ssh folder for the phantom user to prevent Paramiko from loading keys:
Edit phssh_connector.py to disable automatic key lookup:
self._ssh_client.connect(
hostname=self._hostname,
username=self._username,
password=self._password,
look_for_keys=False,
allow_agent=False,
)
⚠️ Note: This modification is not supported and will be overwritten during app upgrades. Use only for temporary troubleshooting.
| Revision | Publish Date | Comments |
|---|---|---|
1.0 |
01-Oct-2026
|
Initial Release |