OpenSSH : Use SSH-Agent2024/12/19 |
Use SSH-Agent to automate inputting Passphrase on SSH Key Pair authentication. |
|
[1] | This is some example to use SSH-Agent. |
# run SSH-Agent [cent@dlp ~]$ eval $(ssh-agent) Agent pid 2069 # add passphrase [cent@dlp ~]$ ssh-add Enter passphrase for /home/cent/.ssh/id_ed25519: Identity added: /home/cent/.ssh/id_ed25519 (cent@dlp.srv.world) # verify [cent@dlp ~]$ ssh-add -l 256 SHA256:SDnILWXo7aKWGF4trcAUabqmjOkesMICFPHrFmotTo0 cent@dlp.srv.world (ED25519) # try to connect without inputting passphrase [cent@dlp ~]$ ssh node01.srv.world hostname node01.srv.world # stop SSH-Agent [cent@dlp ~]$ eval $(ssh-agent -k) Agent pid 2069 killed |
Sponsored Link |
|