Linux/SSH

[SSH] Host based Authentication

변익수 2013. 6. 10. 15:33
반응형

C : client.local

S : server.local


C,S# ssh-keygen -t rsa

C,S# cp ~/.ssh/id_rsa /etc/ssh/ssh_host_rsa_key

C,S# cp ~/.ssh/id_rsa.pub /etc/ssh/ssh_host_rsa_key.pub 


C,S# echo "192.168.64.133    client.local" >> /etc/hosts

C,S# echo "192.168.64.134    server.local" >> /etc/hosts


S# ssh-keyscan -t rsa client.local


S# ssh client.local


S# cp ~/.ssh/known_hosts /etc/ssh/ssh_known_hosts


S# vi /etc/ssh/sshd_config

HostbasedAuthentication yes

IgnoreRhosts no


MaxStartups 512


Match User root

       HostbasedAuthentication no


C# vi /etc/ssh/ssh_config

Host *

        HostbasedAuthentication yes

        EnableSSHKeysign        yes

        GSSAPIAuthentication yes


S# vi /etc/hosts.equiv

client.local


C,S# service sshd restart

C# su - isbyeon

C$ ssh server.local

반응형