Thank you for the quick response, Henning.
2016-12-08 1:07 GMT+09:00 Henning Follmann
<hfollmann@itcfollmann.com>:
> Please revert to your original configs. Key login works be default and
> requires no change.
By reverting to my original configs :
PasswordAuthentication yes
I was able to ssh.
$ ssh -p 9999
testac@192.168.0.5testac@192.168.0.5's password:
Last login: Thu Dec 8 10:56:31 2016 from 192.168.0.3
>
> first generate a key:
> ssh-keygen
>
> By default it creats both id_rsa and id_rsa.pub in your ~/.ssh directory.
> id_rsa contains the private key and it should remain on the client machine
> in your ~/.ssh directory.
I already did as the debug output in my last email showed.
> Transfer the id_rsa.pub to the server you want to logon to.there append it
> to
> cat id_rsa.pub >> <homedirectory of user>/.ssh/authorized_keys
>
Sorry. I forgot writing about having done this.
> debug1: Authentications that can continue: publickey,keyboard-interactive
> debug1: Trying private key: /home/emmm/.ssh/id_rsa
> debug1: Trying private key: /home/emmm/.ssh/id_dsa
> debug1: Trying private key: /home/emmm/.ssh/id_ecdsa
> debug1: Trying private key: /home/emmm/.ssh/id_ed25519
> debug1: Next authentication method: keyboard-interactive
I'm now going to comprehend the debugging output.
On the client ssh tried to use my private key, but failed?
> now you should be able to ssh into that server with pk authorization.
>
> If that works you can go on and disable the password authorization by
> setting on the server sshd config
>
> PasswordAuthentication no
By changing only this line of sshd config, the result is
$ ssh -p 9999
testac@192.168.0.5Permission denied (publickey,keyboard-interactive).
$ ssh -p 9801 -l testac -i ~/.ssh/id_rsa_for_test 192.168.0.5
Permission denied (publickey,keyboard-interactive).
I'll try further and am consulting
http://unix.stackexchange.com/questions/36540/why-am-i-still-getting-a-password-prompt-with-ssh-with-public-key-authenticationand so on.