ssh password less authentication
Md. Habibur Rahman
Oracle DBA, System & Network Administrator | B.Sc in CSE | Vendor: RHCE EX294V9K; RHCSA EX200V9K; CCNA 200-301; MTCRE; MTCNA | Courses: CKA, CKAD
[root@workstation ~]# ssh-keygen?
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):?
Enter passphrase (empty for no passphrase):?
Enter same passphrase again:?
Your identification has been saved in /root/.ssh/id_rsa
Your public key has been saved in /root/.ssh/id_rsa.pub
The key fingerprint is:
SHA256:QPiGTK1JYF1CP+X5IQshXH8Oi3rn2O36olrvWxIiKWc root@workstation
The key's randomart image is:
+---[RSA 3072]----+
|?o=+== .????|
| .?*=.= .????|
|??+ == * o???|
|??=.o= O .???|
|?. E.o S o???|
|??+ o . .????|
|??. o o .???|
|???o *.+????|
|??..ooB*+???|
+----[SHA256]-----+
[root@workstation ~]# ssh-copy-id root@servera
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "/root/.ssh/id_rsa.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out any that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted now it is to install the new keys
root@servera's password:?
Number of key(s) added: 1
Now try logging into the machine, with:??"ssh 'root@servera'"
and check to make sure that only the key(s) you wanted were added.
[root@workstation ~]# ssh root@servera
Last login: Wed Jul 19 15:48:27 2023 from 192.168.122.59
[root@servera ~]#
Enterprise Architect | Leading AI-Driven Innovation, Cloud Transformation, Enterprise Integration, and Business Modernization
1 年Vision of a #passwordless future