gong-gy / connectbot

Automatically exported from code.google.com/p/connectbot
Apache License 2.0
0 stars 0 forks source link

Trouble using a pre-generated key. #288

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Generate a key with say PuTTY Keygen.
2. Copy the key via USB to the root of the SD card.
3. Attempt to import the key using connectbot's importer.

What is the expected output? What do you see instead?
I expect connectbot to import the key. Instead I get "Problem parsing
imported key." If I knew a bit more I would find log files to better
troubleshoot the issue. Unfortunately this is all I have to go off of.

Also I know that the file copied correctly, because I copied the key from
my device to my work computer, and my work computer can use the key to
connect to my server.

What version of the product are you using (you can see this by using Menu
-> About in the Host List)?
Connectbot version 229.
Motorola Droid firmware version 2.0.1 
kernel version 2.6.29-omap1-g0dd7e0b android-build@apa26 #511
Build number ESD56

Original issue reported on code.google.com by michael....@gmail.com on 16 Mar 2010 at 8:26

GoogleCodeExporter commented 8 years ago
Note that you can get logcat info via the Log Collector app, and send it via 
email,
etc. Very handy.

Are you sure you're importing the private part of the key pair, not the public 
part?

Original comment by cdmac...@gmail.com on 17 Mar 2010 at 3:41

GoogleCodeExporter commented 8 years ago
Thanks for the tip on the logs. I'll look in to that. Don't have a whole lot of 
time
to play with it atm.

But what I can tell you is that I used the same file that PuTTY used to log in. 
It's
labeled privatekey.ppk. I don't think the other file that PuTTY Keygen creates 
has an
extension.

Original comment by michael....@gmail.com on 17 Mar 2010 at 4:02

GoogleCodeExporter commented 8 years ago
I can reproduce this issue. I have attached my log. I hope this helps!

Original comment by brian.j....@gmail.com on 27 Mar 2010 at 5:05

Attachments:

GoogleCodeExporter commented 8 years ago
I have the same issue, please follow up!

Original comment by google@odrioo.com on 29 Mar 2010 at 9:22

GoogleCodeExporter commented 8 years ago
As a follow-up: this is while using a DSA key.

Original comment by brian.j....@gmail.com on 3 Apr 2010 at 3:12

GoogleCodeExporter commented 8 years ago
Reading of existing, secret key (hogehoge.ppk)
Conversion tab
It exports to the form openssh
save
copy SD export file
import connectbot

I'm sorry ..good English it... 

Original comment by kuroudo....@gmail.com on 26 Apr 2010 at 1:46

GoogleCodeExporter commented 8 years ago
Worked perfectly. Thanks for the tip kuroudo.

Original comment by SeidrHrafn on 27 Apr 2010 at 3:45

GoogleCodeExporter commented 8 years ago
Importing of DSA keys remains broken for those of us who do not use PuTTY.

Original comment by brian.j....@gmail.com on 27 Apr 2010 at 3:49

GoogleCodeExporter commented 8 years ago
I have the same issue. DSA private key, generated via Putty, get parsing errors 
on private key import.

Original comment by justin.l...@gmail.com on 22 Jul 2010 at 3:47

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Found the answer on another page but dont have the link handy. The private key 
file has to be in the openSSH format. PuttyGen has a "conversions" menu that 
you can use to convert your putty generated private key to a standard openSSH 
key. That should do the trick. 

Original comment by justin.l...@gmail.com on 22 Jul 2010 at 4:26

GoogleCodeExporter commented 8 years ago
I believe there's a separate issue with openssh-generated keys. They don't fail 
to parse, but in my experience they simply don't unlock.

see: Issue #239

Original comment by cdmac...@gmail.com on 22 Jul 2010 at 3:49

GoogleCodeExporter commented 8 years ago
My DSA key didn't work but I had no problems connecting with an Open SSH key 
and unlocking it.  The app works really GREAT!!  Might need to use it tonight 
while out and abount with no access no wifi.

Original comment by micha...@gmail.com on 24 Jul 2010 at 12:05

GoogleCodeExporter commented 8 years ago
ConnectBot doesn't work with PuTTY format keys. It must be in OpenSSH format. 
Like the previous commenter said: use PuTTYGen to convert it.

Original comment by kenny@the-b.org on 23 Aug 2010 at 4:39

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I’ve generated my keys with ssh-keygen from openssh package, they are AES-128 
encrypted and have corrent (id_rsa and id_rsa.pub) names. Why Connectbot cannot 
parse them while importing?
Android 2.3.6

Original comment by hautsuha...@gmail.com on 23 Feb 2012 at 3:26

GoogleCodeExporter commented 8 years ago
Answer by justin.l worked perfectly. Also, be sure your key file is in the root 
of your phone.

"Found the answer on another page but dont have the link handy. The private key 
file has to be in the openSSH format. PuttyGen has a "conversions" menu that 
you can use to convert your putty generated private key to a standard openSSH 
key. That should do the trick."

Original comment by diedrich...@gmail.com on 28 Jul 2012 at 6:37

GoogleCodeExporter commented 8 years ago
thanks to justin for the conversion tip.  i was suspect of the .ppk file 
compatibility with android/linux, but thought it may have been a separate 
configuration error ... saved me some time!

Original comment by lance.j....@gmail.com on 27 Sep 2013 at 11:18