Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 10-07-2010, 12:03 AM   #1
enn
Member
enn began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Sep 2010
Device: Kindle 3
SSH keys with dropbear?

Hello,

Is there a trick to getting SSH keys working with dropbear? I've only used them with the OpenSSH sshd before, and I can't seem to get it to work.

On the Kindle, in /tmp/root aka /var/tmp/root (root's home), I have:

Code:
[root@kindle root]# ls -ld .ssh
drwx------    2 root     root           60 Oct  6 22:49 .ssh
[root@kindle root]# ls -ld .ssh/*
-rw-r--r--    1 root     root          391 Oct  6 22:54 .ssh/authorized_keys
The authorized_keys file contains the key from my id_rsa.pub. I see that dropbear only supports SSHv2, but the man page for ssh-keygen on my machine says, "If invoked without any arguments, ssh-keygen will generate an RSA key for use in SSH protocol 2 connections," so I assume that's what I have. Is there some way to check this, though? It's been a while since I generated that key.

I can post the full output of ssh -vvv if needed but there really doesn't seem to be much of use there, the relevant bit is:

Code:
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/eli/.ssh/id_rsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug1: Authentications that can continue: publickey,password
...and then it asks me for the password. Any assistance would be appreciated.
enn is offline   Reply With Quote
Old 10-07-2010, 12:31 AM   #2
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 4,920
Karma: 4492231
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW & PW2
Because root's home is in a tmpfs partition, I patched dropbear to always look for the pubkeys in a single place: usbnet/etc/authorized_keys (and tweaked the permission checks to not die horribly because it's a vfat partition).

It handles files formatted for OpenSSH, so you shouldn't have any trouble with a key generated by openssh's tools (be it a rsa or dsa key) . (It works fine with openssh's ssh-agent too).
NiLuJe is offline   Reply With Quote
Old 10-07-2010, 12:54 AM   #3
enn
Member
enn began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Sep 2010
Device: Kindle 3
Ah, that works perfectly -- thank you.
enn is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
iLiad Access the hardware keys thebohemian iRex Developer's Corner 9 07-05-2009 10:31 PM
what is wrong with these keys KingDani iRex 8 05-06-2009 11:42 PM
iLiad PC and iliad together: ssh? dropbear? daudi iRex Developer's Corner 10 01-13-2008 09:47 AM
iLiad dropbear ssh: how to change root password? daudi iRex Developer's Corner 2 01-10-2008 04:49 PM
Use keys in Mobipocket ddavtian iRex 0 10-14-2007 04:03 PM


All times are GMT -4. The time now is 02:13 AM.


MobileRead.com is a privately owned, operated and funded community.