[SOLVED] ConnectBot with PuTTYgen Keys - SSH App for Android

Post new topic   Reply to topic    DD-WRT Forum Index -> General Questions
Goto page 1, 2  Next
Author Message
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 15:26    Post subject: [SOLVED] ConnectBot with PuTTYgen Keys - SSH App for Android Reply with quote
I've been updating my Router's old SSH RSA 2048 Keys to the Ed25519 with PuTTYgen Release 0.76. My old Android SSH App don't support Ed25519 Keys. I just want to know which Android SSH App are people on the forum are using that are up to date secure and support Port Forwarding and Ed25519 Keys in PuTTY.

TIA!

Edited Title...

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2


Last edited by mac913 on Tue Nov 22, 2022 21:09; edited 1 time in total
Sponsor
dale_gribble39
DD-WRT Guru


Joined: 11 Jun 2022
Posts: 1931

PostPosted: Tue Nov 22, 2022 15:46    Post subject: Reply with quote
https://proprivacy.com/guides/ssh-android-setup-guide
_________________
"The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep." - Robert Frost

"I am one of the noticeable ones - notice me" - Dale Frances McKenzie Bozzio

<fact>code knows no gender</fact>

This is me, knowing I've ruffled your feathers, and not giving a ****
Some people are still hard-headed.

--------------------------------------
Mac Pro (Mid 2012) - Two 2.4GHz 6-Core Intel Xeon E5645 processors 64GB 1333MHz DDR3 ECC SDRAM OpenSUSE Leap 15.5
egc
DD-WRT Guru


Joined: 18 Mar 2014
Posts: 12881
Location: Netherlands

PostPosted: Tue Nov 22, 2022 15:53    Post subject: Reply with quote
You can still use your old RSA keys if you want.
_________________
Routers:Netgear R7000, R6400v1, R6400v2, EA6900 (XvortexCFE), E2000, E1200v1, WRT54GS v1.
Install guide R6400v2, R6700v3,XR300:https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=316399
Install guide R7800/XR500: https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=320614
Forum Guide Lines (important read):https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=324087
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 16:08    Post subject: Reply with quote
egc wrote:
You can still use your old RSA keys if you want.


For Security and Speed isn't it best to move to the Ed25519 Keys instead of the long RSA Keys?

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2
ho1Aetoo
DD-WRT Guru


Joined: 19 Feb 2019
Posts: 2971
Location: Germany

PostPosted: Tue Nov 22, 2022 16:08    Post subject: Reply with quote
I use juiceSSH


2022-11-22 17.06.23.png
 Description:
 Filesize:  136.34 KB
 Viewed:  1168 Time(s)

2022-11-22 17.06.23.png


mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 16:16    Post subject: Reply with quote
dale_gribble39 wrote:
https://proprivacy.com/guides/ssh-android-setup-guide


I have ConnectBot but doesn't work with Keys generated with PuTTygen 0.76 using Ed25519 and passphrase. The last update was Oct 2021.

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2
ho1Aetoo
DD-WRT Guru


Joined: 19 Feb 2019
Posts: 2971
Location: Germany

PostPosted: Tue Nov 22, 2022 16:19    Post subject: Reply with quote
Putty uses its own format.
But you can convert the keys to the OpenSSH format

you can also generate the keys in the WebIF of the router and download them in OpenSSH format and then convert them in Putty
dale_gribble39
DD-WRT Guru


Joined: 11 Jun 2022
Posts: 1931

PostPosted: Tue Nov 22, 2022 16:50    Post subject: Reply with quote
mac913 wrote:
dale_gribble39 wrote:
https://proprivacy.com/guides/ssh-android-setup-guide


I have ConnectBot but doesn't work with Keys generated with PuTTygen 0.76 using Ed25519 and passphrase. The last update was Oct 2021.

Does anything in the article say that ConnectBot is compatible with ECDSA/ed25519? Unless specifically stated in the article, it doesn't support them...

_________________
"The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep." - Robert Frost

"I am one of the noticeable ones - notice me" - Dale Frances McKenzie Bozzio

<fact>code knows no gender</fact>

This is me, knowing I've ruffled your feathers, and not giving a ****
Some people are still hard-headed.

--------------------------------------
Mac Pro (Mid 2012) - Two 2.4GHz 6-Core Intel Xeon E5645 processors 64GB 1333MHz DDR3 ECC SDRAM OpenSUSE Leap 15.5
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 17:05    Post subject: Reply with quote
dale_gribble39 wrote:
mac913 wrote:
dale_gribble39 wrote:
https://proprivacy.com/guides/ssh-android-setup-guide


I have ConnectBot but doesn't work with Keys generated with PuTTygen 0.76 using Ed25519 and passphrase. The last update was Oct 2021.

Does anything in the article say that ConnectBot is compatible with ECDSA/ed25519? Unless specifically stated in the article, it doesn't support them...


I'm going to test ConnectBot's Key Generator since it has type Ed25519 with Password. I will test if PuTTY 0.76 will work with this Key too.

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2
ho1Aetoo
DD-WRT Guru


Joined: 19 Feb 2019
Posts: 2971
Location: Germany

PostPosted: Tue Nov 22, 2022 17:21    Post subject: Reply with quote
Well, you can also use multiple keys.
In the router you only have to store several public keys.

On the end devices you can then use individual private keys.
E.g., created with dropbear / openssh / putty / whatever ...

Smile

By the way, it is safest if you don't store your private keys on any smartphone Mr. Green
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 17:38    Post subject: Reply with quote
mac913 wrote:
dale_gribble39 wrote:
mac913 wrote:
dale_gribble39 wrote:
https://proprivacy.com/guides/ssh-android-setup-guide


I have ConnectBot but doesn't work with Keys generated with PuTTygen 0.76 using Ed25519 and passphrase. The last update was Oct 2021.

Does anything in the article say that ConnectBot is compatible with ECDSA/ed25519? Unless specifically stated in the article, it doesn't support them...


I'm going to test ConnectBot's Key Generator since it has type Ed25519 with Password. I will test if PuTTY 0.76 will work with this Key too.


Tested ConnectBot's Ed25519 Key Generator and the host (DDWRT Router) does NOT like the Password and will not connect. PuTTYgen Ed25519 Key works fine with DDWRT Router. When I use the PuTTYgen Key with ConnectBot, states Bad Password. ConnectBot r1.9.8 has issues with Ed25519 and Password. In the past ConnectBot with RSA with Password from PuTTYgen worked fine.

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2


Last edited by mac913 on Tue Nov 22, 2022 17:46; edited 1 time in total
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 17:43    Post subject: Reply with quote
ho1Aetoo wrote:
Well, you can also use multiple keys.
In the router you only have to store several public keys.

On the end devices you can then use individual private keys.
E.g., created with dropbear / openssh / putty / whatever ...

:)

By the way, it is safest if you don't store your private keys on any smartphone :mrgreen:


I always use Passswords/Passphares with my Keys, so the key is useless without knowing the Password or Passphrase. I don't use 1234 as a password either. :)

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2
ho1Aetoo
DD-WRT Guru


Joined: 19 Feb 2019
Posts: 2971
Location: Germany

PostPosted: Tue Nov 22, 2022 18:35    Post subject: Reply with quote
So I just created an Ed25519 key with password protection using OpenSSH.
The public key is stored on the router.

It works fine on my Linux PC.
Then I imported the private key into JuiceSSH.

There it also works fine Smile



2022-11-22 19.34.18.png
 Description:
 Filesize:  104.61 KB
 Viewed:  1086 Time(s)

2022-11-22 19.34.18.png


mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 19:06    Post subject: Reply with quote
ho1Aetoo wrote:
So I just created an Ed25519 key with password protection using OpenSSH.
The public key is stored on the router.

It works fine on my Linux PC.
Then I imported the private key into JuiceSSH.

There it also works fine :-)


Thanks for testing. I'll check it out later.

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Tue Nov 22, 2022 21:06    Post subject: Reply with quote
I have ConnectBot working with PuTTYgen Ed25519 Keys

You need to use 3 different formats for your newly created Ed25519 from PuTTYgen 0.76...

When you start PuTTYgen select EdDSA with Curve Ed25519 then Press Generate and move your mouse around to create the Key. Now enter your Key passphrase. Now we can create 2 different files and import the new key to your DD-WRT Router with at least Build 50906.

a) Your PuTTY software will need the file created from "Save private key" which is a ppk file.
Debian CLI Command (-C is optional): puttygen -t ed25519 -C "personal_comment" -o file_name.ppk

b) Now for your DD-WRT Router SSH Key, copy the key inside the box "Public key for pasting into OpenSSH..." You may want to back it up in a file. (I use wrt extension)
Debian CLI Command: puttygen file_name.ppk -O public-openssh -o file_name.wrt

c) Your ConnectBot App will need the file created from the top tab "Conversions" and "Export OpenSSH Key" there are 2 types they both work, pick either one. (I use ssh extension)
Debian CLI Command: puttygen file_name.ppk -O private-openssh -o file_name.ssh

If your Host ConnectBot doesn't connect, delete the Host and re-create it. This will reset the SshHostKey in the app.


UPDATE Testeing the Windows Putty 0.78 "ppk" keys in Putty 0.74 under Debian Bullseye "stable" states the key format is too new and doesn't work. I created new ed25519 keys with Debian Puttygen 0.74 using the commands in Bold and works with Putty 0.78 too.

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2


Last edited by mac913 on Sun Dec 11, 2022 22:14; edited 1 time in total
Goto page 1, 2  Next Display posts from previous:    Page 1 of 2
Post new topic   Reply to topic    DD-WRT Forum Index -> General Questions All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum