まぬけすぎますな。
いままではパスワード認証にしてました。
公開鍵認証に変えようとしたんですが。
syasuda@uno:~/.ssh$ ssh -l syasuda -vvv 192.168.22.45 -2
・・・debug3: remaining preferred: keyboard-interactive,password
debug3: authmethod_is_enabled publickey
debug1: Next authentication method: publickey
debug1: Offering public key: /home/syasuda/.ssh/id_rsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug3: Wrote 368 bytes for a total of 1495
debug1: Authentications that can continue: publickey
debug1: Offering public key: /home/syasuda/.ssh/id_dsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug3: Wrote 528 bytes for a total of 2023
debug1: Authentications that can continue: publickey
debug2: we did not send a packet, disable method
debug1: No more authentication methods to try.
Permission denied (publickey).
というようなよくある現象でつながらず。
sshd_configはどこぞのテンプレぽい設定を丸写しなので問題なさそう。
RSA公開鍵認証の有効化とパスワード認証の無効化 - Gentoo Linuxで自宅サーバ
原因は鍵のオーナーでした。
-rw------- 1 root root 619 2011-08-25 11:15 authorized_keys
パーミションしか見てなかったよ(泣
最初に
$ sudo emacs authorized_keys
しちゃったのが原因ぽいですな。sudoが癖になってます。
コメント