![]() When trying keys, it doesn’t try the correct key (dropbear) despite it being in ~/.ssh with the others. ![]() Looking into it, I ran this to get logs: ssh -vvv indicated the SSH client is using id_rsa by default, but that key is for a different system. I suppose I can set a bash alias tied to the IP address to change the SSH command, but that feels improper. If I don’t specify the key manually the connection is not established I need to use this to connect: ssh -i ~/.ssh/dropbear I would like to enter this: ssh have a couple of systems on my network and this would help in case I forget which key is on what system. My ssh client is requiring that I identify the key name manually for this Dropbear server.Sudo chown dietpi:dietpi /home/dietpi/.ssh/authorized_keys Sudo chmod 600 /home/dietpi/.ssh/authorized_keys My permissions were applied in the wrong order: like Joulinar pointed out, I needed to apply chmod on the folder, then the file, and then chown.I traced my steps back and found two things that were causing an issue. With all of this said, I know Dropbear has issues with incorrect permissions so I tried addressing it and I understand somewhere is a config file for Dropbear but I don’t know why keys would be blocked/not enabled.Īs Dropbear is default here, I hope you may shed some wisdom so I can learn I appreciate you reading this and hope to find a solution. I’m testing the keys by restarting Dropbear (sudo systemctl restart rvice) or dietpi-services and then running ssh -o PasswordAuthentication=no The process gives the error Permission denied (publickey,password). I’ve set these permissions with chmod 600 700 is giving the same result. -rw- 1 dietpi dietpi 96 Feb 1 18:42 /home/dietpi/.ssh/authorized_keys.lrwxrwxrwx 1 dietpi dietpi 33 Feb 1 18:06 /etc/dropbear/authorized_keys → /home/dietpi/.ssh/authorized_keys.I saw a long-time bug in ssh-copy-id moves keys incorrectly to /etc/dropbear/authorized_keys, I successfully tricked it to put the keys into /home/dietpi/authorized_keys by making /etc/dropbear/authorized_keys a dietpi owned symlink. Using keys, I am getting this error: Permission denied (publickey,password) The Pi4B is working well and connecting with passwords at the moment. rw-r–r- 1 username username 2665 Apr 5 00:15 known_hosts.Hello, I a default install of DietPi v8.13.2 on a Pi 4B, and am trying to setup SSH keys to connect to the Dropbear server (on Dietpi) from an OpenSSH client. rw- 1 username username 4157 Apr 7 01:14 known_hosts rw-r–r- 1 username username 577 Apr 13 06:52 digiocean.pub rw- 1 username username 2610 Apr 13 06:52 digiocean Ssh -i ~/.shh/digiocean Identity file /home/username/.shh/digiocean not accessible: No such file or Permission denied (publickey).ĭrwx- 2 username username 4096 Apr 13 06:57. Ssh -i ~/.ssh/digiocean Permission denied (publickey). Identity added: /home/username/.ssh/digiocean try again, same issue. SHA256:**** I cat the public key and place it on DO’s ssh key section. ![]() Your public key has been saved in digiocean.pub Your identification has been saved in digiocean ![]() ![]() I’ve added the key to the SSH Keys section on DO, and I’ve ran “ssh-add” for the key but no dice so far.Įnter file in which to save the key (/home/username/.ssh/id_rsa): digioceanĮnter passphrase (empty for no passphrase): Hi everyone, currently trying to SSH into a Digital Ocean droplet and I’m getting this error "Permission denied (publickey). ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |