Home > Android > SSH Login without password with ConnectBot on Android

SSH Login without password with ConnectBot on Android

 

  Typing password on Android device is troublesome, espcially when the password is long and complex. You may know that ssh-keygen can be used to generate rsa key pair to configure server, for SSH login without password (detailed in http://linuxproblem.org/art_9.html). On Android device you can do the same thing with ConnectBot.

  Open ConnectBot, Menu => “Manage Pubkeys” => Menu => “Generate”, then generate one. The password on this step is NOT the acctual server password, but the passwd for this key pair(so if you can ensure the safty of your device you dont have to fill it). After touching the screen for a while the key pair is generated, and you can manage to copy your public key to PC(e.g. via a text file in sdcard). Then append public key to ~/.ssh/authorized_keys remote sever. In fact the process of copying public key can be done on the phone, but I suppose this way is the most efficient.

  It is strongly adviced that you also backup your private key to sdcard or PC. Once you clear data storage for ConnectBot (e.g. uninstall ConnectBot or installed a now ROM), the private key is lost and you have to this once again. With the private key backuped on your sdcard, you can easily import it afterward (in the similiar way to create it).

 

Advertisements
Categories: Android
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: