| Interesting attack, but likely impractical. - Iterating over all internal IPv4 addresses to try attacking them isn't that expensive, there are about 16 million IP addresses, and there are likely patterns in their allocation if your goal is an internal network. - `HashKnownHosts yes` is not the default setting. - Shell history likely leaks the hosts anyway if you enable this SSH setting. - You could substitute `ssh` with a malicious version of it. |
1) Iterating over the network:
The point of this type of attack is to stay under the radar of NIDS which should (if configured correctly) detect someone trying to knock on port 22 of every server in your private address space.
2) `HashKnownHosts yes` is not the default setting:
True. But it is an available setting and since some would enable it assuming it would provide them with extra security then the strength of that extra security does still need to be proven. Hence why this research was done.
3) Shell history likely leaks the hosts anyway if you enable this SSH setting:
Indeed. However it's also not that uncommon for people to disable shell history on bastion servers. Plus if that particular user hasn't SSH'ed in a little while it's possible the history file has rolled over to reveal fewer servers in its log.
4) You could substitute `ssh` with a malicious version of it:
You could. That's probably the most likely attack to try first but it's not without it's problems as well:
* You'd either need root access to replace the ssh client, or to be damn sure you updated the right user shell profile to update the $PATH variable to include the location of your preferred ssh client (ie putting export PATH=~/boobytrapped:$PATH ) and the user not noticing either the modification to their profile nor the new folder in a user writable directory (it's worth referencing an earlier point about how a network scan was dismissed because it is a detectable attack)
* It's a longer term attack since you wouldn't get a list of servers until after a user has connected to them (on the plus side, you could glean more detail about the target).