Closed mariobranco closed 6 years ago
@mariobranco you have to supply a target, like this...
$ ssh_scan -t sshscan.rubidus.com
If you have a specific example case, please let me know
Hello @claudijd,
I encounter the same issue as was mentioned above when I specify some non-standard port, e.g.:
$ ssh_scan -t 192.168.2.219 -p 5022
Output after executing this command:
/var/lib/gems/2.3.0/gems/ssh_scan-0.0.32/lib/ssh_scan/scan_engine.rb:138:in
scan_target': undefined method
split' for nil:NilClass (NoMethodError) from /var/lib/gems/2.3.0/gems/ssh_scan-0.0.32/lib/ssh_scan/scan_engine.rb:191:in `block (2 levels) in scan'
If I am not mistaken, the problem could be with ssh-keyscan in scan_engine.rb, line 127:
stdin, stdout, stderr, wait_thr = Open3.popen3('ssh-keyscan', '-t', 'rsa,dsa', target)
If other port is specified, ssh-keyscan ignores it and there is no output to parse. I tried to resolve this, as can be seen bellow, and it seems to be working.
stdin, stdout, stderr, wait_thr = Open3.popen3('ssh-keyscan', '-t', 'rsa,dsa', '-p', port.to_s, target)
Thank you for looking into it.
props to @jinankjain to beating me to the punch on this!
Also, thanks @ondrejkelemen and @mariobranco for reporting, I'll try to get a fixed release out today.
33 has been released to fix this => https://twitter.com/claudijd/status/963443576238723072
Command: ssh_scan -t [TARGET] Output: /var/lib/gems/2.3.0/gems/ssh_scan-0.0.32/lib/ssh_scan/scan_engine.rb:138:in
scan_target': undefined method
split' for nil:NilClass (NoMethodError) from /var/lib/gems/2.3.0/gems/ssh_scan-0.0.32/lib/ssh_scan/scan_engine.rb:191:in `block (2 levels) in scan'Can't find the solution for my problem. Any tip please ?