「Xserver VPSでDebianサーバ構築/SSHサーバ設定」の版間の差分
ナビゲーションに移動
検索に移動
(同じ利用者による、間の2版が非表示) | |||
15行目: | 15行目: | ||
</nowiki> |
</nowiki> |
||
= SSHクライアント設定 = |
|||
= その他 = |
|||
== SSHキー作成 == |
== SSHキー作成 == |
||
21行目: | 21行目: | ||
<nowiki> |
<nowiki> |
||
$ ssh-keygen -t ed25519 -C "example@example.com" -f id_ed25519_example |
$ ssh-keygen -t ed25519 -C "example@example.com" -f id_ed25519_example |
||
$ ssh-copy-id -i identity_file example.com |
|||
</nowiki> |
</nowiki> |
||
27行目: | 28行目: | ||
<nowiki> |
<nowiki> |
||
$ eval `ssh-agent` |
$ eval `ssh-agent` |
||
$ ssh-add |
|||
</nowiki> |
</nowiki> |
||
2024年6月1日 (土) 14:08時点における最新版
パスワード認証を無効化
次のファイルに、以下の設定を行う。
- /etc/ssh/sshd_config
PasswordAuthentication no
次のコマンドを実行する。
$ sudo systemctl reload sshd
SSHクライアント設定
SSHキー作成
$ ssh-keygen -t ed25519 -C "example@example.com" -f id_ed25519_example $ ssh-copy-id -i identity_file example.com
ssh-agent
$ eval `ssh-agent` $ ssh-add
known_hosts
削除
$ ssh-keygen -f "/home/mede/.ssh/known_hosts" -R "HOST"