3

I'm trying to use sgit to connect to a remote repository. It has a screen to "Manage Private Keys," but it doesn't seem to include a key generator. Instead, it lets you browse the file system, so presumably it's letting you pick a key generated by an external tool. I used JuiceSSH to generate a key pair, but can't find where it drops the key pair files.

So, how can I get sgit working? Should I be using a different tool to generate key pairs for sgit? Or is there a way to do it in sgit and I'm just missing it?

Don Branson
  • 136
  • 1
  • 5

2 Answers2

7

To export keys from JuiceSSH (either private or public):

  1. Load up JuiceSSH and go to Connections
  2. Swipe right to the identities list
  3. Long press the identity you want to export the key for
  4. Select either "Export public key" or "Export private key"

This will bring up a "Share" dialog that will let you save the key to clipboard/gmail/dropbox etc.

Thanks

Paul (JuiceSSH developer)

JuiceSSH
  • 71
  • 2
0

When exporting the private key from JuiceSSH, you must share it to an application that you can write in like messenger or a note pad and it will input the key in text form.

Copy the entire text from "-----BEGIN RSA..." to "END RSA KEY-----". Save this as a file called "id_rsa" and use it as the private key for your client application(I used AndFTP). My notepad application saved the file as "id_rsa.txt" so I created a copy and removed the extension with this command:

cp id_rsa.txt id_rsa

Don't forget to add the public key to the server's authorized_keys file. This can be done by exporting the public key and copying it like before. I used the echo command to add the copied key the the authorized_keys file.

echo "ssh-rsa ... JuiceSSH" >> .ssh/authorized_keys

Paste the exported text in quotes so it looks similar to the above("JuiceSSH" is the name given to the key by the generator) and execute the command in the server's home directory(/home/user/) where the .ssh folder is located.