Problem parsing imported private key

2648 views
Skip to first unread message

Alan

unread,
Apr 10, 2011, 11:09:37 PM4/10/11
to ConnectBot Users
Tried to import private key (from puttygen) but failed.
Any advice?

Shai Ayal

unread,
Apr 10, 2011, 11:49:50 PM4/10/11
to connectb...@googlegroups.com, Alan
You should export this key (from puttygen) as an openssh private key. This is the format connectbot recognizes.

Shai

On Mon, Apr 11, 2011 at 6:09 AM, Alan <gpm...@gmail.com> wrote:
Tried to import private key (from puttygen) but failed.
Any advice?

--
You received this message because you are subscribed to the Google Groups "ConnectBot Users" group.
To post to this group, send email to connectb...@googlegroups.com.
To unsubscribe from this group, send email to connectbot-use...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/connectbot-users?hl=en.


jordy verkest

unread,
Oct 19, 2012, 1:12:01 AM10/19/12
to connectb...@googlegroups.com, Alan
I've exported my private key in puttygen to OpenSSH format.
ConnectBot still says problem parsing imported private key.
?

Shai Ayal

unread,
Oct 19, 2012, 1:15:33 AM10/19/12
to connectb...@googlegroups.com, Alan
On Fri, Oct 19, 2012 at 7:12 AM, jordy verkest <jordy....@gmail.com> wrote:
>
> I've exported my private key in puttygen to OpenSSH format.
> ConnectBot still says problem parsing imported private key.
> ?
>

Can you post a sample? Generate a *new* private key in puttygen,
export it to OpenSSH format, try to import it to connectbt. If it
fails, post it here

Shai

--
SPT - persistent SSH tunnels for android.

me

unread,
Oct 19, 2012, 1:49:43 AM10/19/12
to connectb...@googlegroups.com, Alan
Sample key ;

-----BEGIN RSA PRIVATE KEY-----
Proc-Type: 4,ENCRYPTED
DEK-Info: DES-EDE3-CBC,AF9F12410375BD2E

V7W0u367QMRaTb3Xpi9hRafBOP1UBnJBaxpr4Yv0xiz7K6lYmpTj+vxfcKqzFE3z
zFP1xxkOQo3UKHDQWPeZQHjEpIj5Y5hxj1MfuvXmmQT7erH+EFV+A+vYEIYtmEuq
ttiAeb6MDdyUsdqEha/qPo1rX+x8OVYkEyRxqdZsjEtCDHng9MTYPbc7r0EstD2c
M0fJMzCrsX5NugffQreI8SL85wF9LCp1pw9SO9PqzosKir2K0d69lZEQ1hF548mh
fEq/3KgqbFg5hJD57JBYnY7x+i8fFJCjded3mOf7uGVs1MBnMwU37ZsMB5Mp4+l1
2mXCF2Ni+4hQQ0+lzDTRE+q9scqXEpiLAtZg3XkuFOm+57njV73z8a61b+m95eXo
ngGg47TpdVsjOKqguKIUH4fcGpigPHyGrpoZ03KPxH2yPXb/E5thfNBNoEH0A4Dt
wwLs54Z+p/wH8lbgcTtijLZOQ9vBU52NE4fyEsHIxnh04tyLBQEhpV0NyOg6u+uY
1xtZGfGn4ycIMD/hpSJiOltz5CMP2ALgZGooYKX1a0IRWVD3ReL84GoKiQXQqQtJ
adOeALKd1p56wXcUY837gQoHeywrrMA1+K9pmjTvmcQnHk22fudPnfHhUzXMsAVF
XWPs/HTiJ5LWpClrsTl24p1ApWPIIHN6Nsb1BH1va0hJRhFkMZ3JNr8ULGNuktUg
49a76RGTX79veNdMsZSO8C+RmRpHAJTBiPpmFDie+WZY8zefaMaynhdZqwABiXyR
wRP812w5Dx8/S9t6KzNEItS9PTDD6hfK9fzLPXX4vsE=
-----END RSA PRIVATE KEY-----

me

unread,
Oct 20, 2012, 12:59:38 PM10/20/12
to connectb...@googlegroups.com, Alan
*bump*

Shai Ayal

unread,
Oct 20, 2012, 2:59:31 PM10/20/12
to connectb...@googlegroups.com, Alan
I managed to import this key into connectbot as is. It shows up in the
public keys list, and when I touch it it asks for the password (which
I don;t know). Does connectbot give you an error before the password
or after?

me

unread,
Oct 20, 2012, 3:16:42 PM10/20/12
to connectb...@googlegroups.com, Alan
Before the password. It just says problem parsing imported private key
Just upgraded to ConnectBot-git-master-2012-10-20_04-01-07.apk, the problem persists.
Using Android 2.3.6 on a Samsung GT-B5510.


(the password for the sample key is test)

Shai Ayal

unread,
Oct 20, 2012, 4:10:36 PM10/20/12
to connectb...@googlegroups.com, Alan
On Sat, Oct 20, 2012 at 9:16 PM, me <jordy....@gmail.com> wrote:
> Before the password. It just says problem parsing imported private key
> Just upgraded to ConnectBot-git-master-2012-10-20_04-01-07.apk, the problem
> persists.
> Using Android 2.3.6 on a Samsung GT-B5510.
>
>
> (the password for the sample key is test)
>
I managed to unlock the key with this password in connectbot.

How do you transfer the key to the android device?

me

unread,
Oct 20, 2012, 4:14:37 PM10/20/12
to connectb...@googlegroups.com, Alan
i just copy it over usb to /sdcard

how to get debug information from connectbot ?

Shai Ayal

unread,
Oct 20, 2012, 4:20:09 PM10/20/12
to connectb...@googlegroups.com, Alan
On Sat, Oct 20, 2012 at 10:14 PM, me <jordy....@gmail.com> wrote:
> i just copy it over usb to /sdcard
>
> how to get debug information from connectbot ?

just install aLogCat, you should see some debug info in the logs

me

unread,
Oct 20, 2012, 5:19:57 PM10/20/12
to connectb...@googlegroups.com, Alan
E/ConnectBot.PubkeyListActivity( 2520): Problem parsing imported private key
E/ConnectBot.PubkeyListActivity( 2520): java.lang.NullPointerException
E/ConnectBot.PubkeyListActivity( 2520):     at org.connectbot.bean.PubkeyBean.getValues(PubkeyBean.java:213)
E/ConnectBot.PubkeyListActivity( 2520):     at org.connectbot.util.PubkeyDatabase.savePubkey(PubkeyDatabase.java:311)
E/ConnectBot.PubkeyListActivity( 2520):     at org.connectbot.PubkeyListActivity.readKeyFromFile(PubkeyListActivity.java:562)
E/ConnectBot.PubkeyListActivity( 2520):     at org.connectbot.PubkeyListActivity.access$100(PubkeyListActivity.java:83)
E/ConnectBot.PubkeyListActivity( 2520):     at org.connectbot.PubkeyListActivity$13.onClick(PubkeyListActivity.java:611)
E/ConnectBot.PubkeyListActivity( 2520):     at com.android.internal.app.AlertController$AlertParams$3.onItemClick(AlertController.java:873)
E/ConnectBot.PubkeyListActivity( 2520):     at android.widget.AdapterView.performItemClick(AdapterView.java:284)
E/ConnectBot.PubkeyListActivity( 2520):     at android.widget.ListView.performItemClick(ListView.java:3736)
E/ConnectBot.PubkeyListActivity( 2520):     at android.widget.AbsListView$PerformClick.run(AbsListView.java:1974)
E/ConnectBot.PubkeyListActivity( 2520):     at android.os.Handler.handleCallback(Handler.java:587)
E/ConnectBot.PubkeyListActivity( 2520):     at android.os.Handler.dispatchMessage(Handler.java:92)
E/ConnectBot.PubkeyListActivity( 2520):     at android.os.Looper.loop(Looper.java:130)
E/ConnectBot.PubkeyListActivity( 2520):     at android.app.ActivityThread.main(ActivityThread.java:3687)
E/ConnectBot.PubkeyListActivity( 2520):     at java.lang.reflect.Method.invokeNative(Native Method)
E/ConnectBot.PubkeyListActivity( 2520):     at java.lang.reflect.Method.invoke(Method.java:507)
E/ConnectBot.PubkeyListActivity( 2520):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867)
E/ConnectBot.PubkeyListActivity( 2520):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:625)
E/ConnectBot.PubkeyListActivity( 2520):     at dalvik.system.NativeStart.main(Native Method)

Shai Ayal

unread,
Oct 21, 2012, 1:41:41 AM10/21/12
to connectb...@googlegroups.com, Alan
This looks like something in the java implementation is wrong. Can you
give us some details on your android system?

Shai

me

unread,
Oct 21, 2012, 2:40:12 AM10/21/12
to connectb...@googlegroups.com, Alan
Android 2.3.6
Kernel 2.6.35.7
dpi@DELL137#1
Build GINGERBREAD.CELG1

What more info can I give ?

Shai Ayal

unread,
Oct 21, 2012, 2:41:37 AM10/21/12
to connectb...@googlegroups.com, Alan

Is this a stock rom? What hardware?

בתאריך 21 באוק 2012 08:40, מאת "me" <jordy....@gmail.com>:
--
You received this message because you are subscribed to the Google Groups "ConnectBot Users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/connectbot-users/-/xtEFlKcepZEJ.

me

unread,
Oct 21, 2012, 2:45:06 AM10/21/12
to connectb...@googlegroups.com, Alan
samsung gt-b5510

no, not stock, it has already been updated by Samsung technicians

me

unread,
Oct 21, 2012, 2:48:27 AM10/21/12
to connectb...@googlegroups.com, Alan

Shai Ayal

unread,
Oct 21, 2012, 3:35:18 AM10/21/12
to connectb...@googlegroups.com, Alan
On Sun, Oct 21, 2012 at 8:48 AM, me <jordy....@gmail.com> wrote:



On Sunday, October 21, 2012 8:45:06 AM UTC+2, me wrote:
-- 

It's very strange. Maybe try to install some other android SSH application and see if it can import the key? Also did you try to import the key with another androi app (e.g. some notepad) just to see if the file is accessible?

Shai
 

me

unread,
Oct 21, 2012, 4:39:47 AM10/21/12
to connectb...@googlegroups.com, Alan
I can open the key in ThinkFree Write.
I can import the key in PaderSyncSSH. (trialware)

I really would like to use ConnectBot.

Are you a CB developer ?

Shai Ayal

unread,
Oct 21, 2012, 4:46:38 AM10/21/12
to connectb...@googlegroups.com, Alan
On Sun, Oct 21, 2012 at 10:39 AM, me <jordy....@gmail.com> wrote:
I can open the key in ThinkFree Write.
I can import the key in PaderSyncSSH. (trialware)

I really would like to use ConnectBot.

Are you a CB developer ?

No. I'm not. I am the developer for SPT, and a connectbot user. At this stage I can only raise my hands ...
Sorry

-- 

Tom Atkinson

unread,
Feb 20, 2013, 12:09:37 AM2/20/13
to connectb...@googlegroups.com, Alan
So far from what I've seen - SPT is the best at keeping the tunnels live. ConnectBot makes them nicely but then stops after a bit when they break. SPT keeps trying to remake the connection, usually if i reboot my server it comes back after a bit.

Rubin Abdi

unread,
Mar 30, 2013, 4:09:36 PM3/30/13
to connectb...@googlegroups.com
Revisiting this again as it would be really nice to have an updated
version of ConnectBot that works with my keys.

I went through and generated a new key on my Debian Sid box...

$ ssh-keygen -C "rubin110@flamboyant"

I gave the key a password. Using adb I pushed the private key to
/sdcard/ then brought up a shell and cat the file to make sure it was
actually there.

After that I went through the normal steps in the UI to import a key,
only to see a "Problem parsing imported key" toast popup.

Here's a logcat during that time...

http://paste.debian.net/246011/

Again any help would be extremely appreciated.

--
Rubin
ru...@starset.net

signature.asc

Jay Dominic

unread,
Apr 26, 2013, 3:27:26 AM4/26/13
to connectb...@googlegroups.com, Alan
i you have created your private and public key through PUTTYGEN you usually enter something in the ''key comment'' i.e ssh server's public ip address. Then at the ''key passphrase'' is your own password. The password you keyed in is what connectbot is asking you.

Julian Reuthlinger

unread,
May 10, 2013, 5:55:05 PM5/10/13
to connectb...@googlegroups.com
Hi there! :-)

Do you have an update to this problem? tried the same today and got the same error :-/

Julian Reuthlinger

unread,
May 10, 2013, 6:32:28 PM5/10/13
to connectb...@googlegroups.com
solved! :-)

Just open Puttygen, load the key, klick on "Conversions" and export it to a openSSH-Key. Thats all ;-)
Reply all
Reply to author
Forward
0 new messages