forked from p15670423/monkey
Agent: Fix ssh string to include proper user and ip
This commit is contained in:
parent
ccb0337aef
commit
1b9bbfe752
|
@ -60,7 +60,7 @@ class SSHExploiter(HostExploiter):
|
||||||
for user, ssh_key_pair in ssh_key_pairs_iterator:
|
for user, ssh_key_pair in ssh_key_pairs_iterator:
|
||||||
# Creating file-like private key for paramiko
|
# Creating file-like private key for paramiko
|
||||||
pkey = io.StringIO(ssh_key_pair["private_key"])
|
pkey = io.StringIO(ssh_key_pair["private_key"])
|
||||||
ssh_string = "%s@%s" % (ssh_key_pair["user"], ssh_key_pair["ip"])
|
ssh_string = "%s@%s" % (user, self.host.ip_addr)
|
||||||
|
|
||||||
ssh = paramiko.SSHClient()
|
ssh = paramiko.SSHClient()
|
||||||
ssh.set_missing_host_key_policy(paramiko.WarningPolicy())
|
ssh.set_missing_host_key_policy(paramiko.WarningPolicy())
|
||||||
|
|
Loading…
Reference in New Issue