4 ms·
I'm curious why this tool wouldn't use all the settings in the ssh config to attempt to connect to hosts.. instead it only picks a subset of those settings. For
by pcthrowaway 3y ago
I'm curious why this tool wouldn't use all the settings in the ssh config to attempt to connect to hosts.. instead it only picks a subset of those settings. For example, of the config file specifies a port besides 22, it won't be able to connect to that host (or for example, if the config file sets `PubkeyAcceptedAlgorithms=+ssh-rsa` which is necessary, albeit insecure, if using an older private key file on a newer version of ssh which disables RSA key exchange)
I see no downside to just using the hostname from the config file instead of trying to apply a few select options from the config, and non-standard ports are extremely common
- chaps 3y agoMy theory's that it's to ensure backwards compatibility with ooooold hosts.
- mmsc 3y agoor for example, if the config file sets `PubkeyAcceptedAlgorithms=+ssh-rsa` which is necessary It already does this: https://github.com/MegaManSec/SSH-Snake/blob/7ae7ef0afe0e067a1b96f69e508df52831a08b8b/Snake.sh#L216 https://github.com/MegaManSec/SSH-Snake/blob/7ae7ef0afe0e067... and https://github.com/MegaManSec/SSH-Snake/blob/7ae7ef0afe0e067a1b96f69e508df52831a08b8b/Snake.sh#L639C3-L639C3 https://github.com/MegaManSec/SSH-Snake/blob/7ae7ef0afe0e067... I see no downside to just using the hostname from the config file It already does this: https://github.com/MegaManSec/SSH-Snake/blob/main/Snake.sh#L1225 https://github.com/MegaManSec/SSH-Snake/blob/main/Snake.sh#L... the config file specifies a port besides 22, it won't be able to connect to that host This shouldn't be hard to implement and can certainly be added in a later version.