0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

ssh初回接続時にknown_hostsに登録される情報って何?

Posted at

はじめに

known_hostsに登録される情報がふと気になったので、備忘用にまとめました。

known_hostsとは

  • sshサーバ側の公開鍵の指紋(finger print)が登録されるファイル
  • sshクライアント側の.sshディレクトリに格納されている
  • 登録されるタイミングはsshサーバに初回接続するタイミング
接続時メッセージ例
The authenticity of host 'SSHサーバのホスト名' can't be established.
RSA key fingerprint is "実際のfinger print"
Are you sure you want to continue connecting (yes/no)? 

sshサーバの公開鍵

  • sshサーバ自身の公開鍵
  • sshがインストールされる時に生成される(つまりOSインストール時と考えてよい)
  • 公開鍵認証の接続時に、サーバ側に登録する必要のあるクライアント側の公開鍵のことではないので注意
  • Linuxとかの場合、以下に格納されている
公開鍵の格納場所
/etc/ssh/ssh_host_rsa_key.pub
0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?