반응형

CentOS7 SSH 공개키 자동 로그인 처리.

/etc/securetty/etc/ssh/sshd_config

PasswordAuthentication yes

RSAAuthentication yes
PubkeyAuthentication yes
AuthorizedKeysFile     .ssh/authorized_keys

sshd 재시작 
# systemctl restart sshd


# ssh-keygen -t rsa 

# .ssh/id_rsa
# .ssh/id_rsa_pub

# id_rsa_pub를 .ssh/authorized_keys 로 복사하여 전달.

유효한 파일 권한으로 부여
# chmod 0700 ~/.ssh
# chmod 0600 ~/.ssh/authorized_keys

반응형
Posted by 공간사랑
,