If you are having problems getting key authentication in JuiceSSH working, here are some troubleshooting steps to check:
- You have the following lines configured in the /etc/ssh/sshd_config file on your server:
- RSAAuthentication yes
- PubkeyAuthentication yes
- You have the following permissions on your home directory:
- Only your user has write/execute permissions on your home directory
chmod 700 ~
- Only your user has write/execute permissions on your ssh configuration directory
chmod 700 ~/.ssh
- Only your user has write permissions on your ssh authorized keys file
chmod 600 ~/.ssh/authorized_keys
- Your ~/.ssh/authorized_keys file contains one public key per line, each beginning with ssh-rsa or ssh-dsa
- Your public keys in ~/.ssh/authorized_keys have not been wrapped over multiple lines
You should also check the following log files for any error messages that sshd might be giving:
- /var/log/secure (RedHat)
- /var/log/auth.log (Ubuntu/Debian)
If you do not see anything relevant in the logs, you can try increasing the logging verbosity of sshd by setting LogLevel DEBUG3 in your /etc/ssh/sshd_config and restarting the ssh daemon.