Hi, I recently found an article on using sshpass with gpg to script the process of connecting to a remote host using a password, while also encrypting that password in a file using gpg.
$ gpg -d -q .sshpasswd.gpg | sshpass ssh user@srv1.example.com
https://www.redhat.com/sysadmin/ssh-automation-sshpass
However, I think it requires having previously stored your key passphrase into the keyring stored in memory, correct? So this script would not work as advertised for this reason. Is that correct?
Also, I'm not new to Linux administration, but somewhat new to sshpass. Does it only work with ssh passwords or public keys as well?