SSH key authentication

From ImageStream Router Documentation

Jump to: navigation, search


Setting up SSH Key Authentication


Setting up your Imagestream router to do SSH key based authentication takes about 10 minutes to setup, and requires some basic familiarity with your SSH terminal software. These instructions cover how to setup SSH Key authentication with both OpenSSH for Unix/Linux and PuTTY for Windows. Instructions for other SSH implementations will vary in creation of the key, but should be similar after that.


You will need to have an ssh client for your operating system. On Windows(TM), PuTTY works well and is free ( ). On Linux, OpenSSH will most likely be installed by default.

Steps for OpenSSH

  1. If you already completed this step, then skip to step 4. Generate the SSH Key by opening a terminal and running ssh-keygen -tdsa.
  2. Save the file to the default location. NOTE: Write this down for later.
  3. Type in the passphrase. NOTE: This can be left blank, but it is considered less secure. Ssh-agent can be used to remember the passphrase, but its setup is outside the scope of this document.
  4. Login to your Imagestream router and select option 3. Advanced, then option 1. Bash shell
  5. Run mkdir /root/.ssh/. Then run chmod 700 /root/.ssh/
  6. On your workstation, run scp <SSH_KEY_LOCATION>.pub root@<IP_OF_ROUTER>:/root/<code>
  7. On the router, run <code>cat /root/ >> /root/.ssh/authorized_keys.
  8. Finally, run rm /root/ Connecting to ssh <IP_OF_ROUTER> should authenticate via the ssh key.

Steps for PuTTY

  1. Download and install putty, pscp, and puttygen NOTE: You can obtain PuTTY from
  2. Open puttygen and click on Generate.
  3. Move the mouse to generate random data
  4. Click on save Private Key and save the file to %USERPROFILE%\putty_key.ppk
  5. Highlight the public key data at the top of the puttygen window, and past it into a text editor. Save that file as %USERPROFILE%\
  6. Run this command at a shell. pscp %USERPROFILE%\ root@<IP_OF_ROUTER>:/root/
  7. Login to your Imagestream router and select option 3. Advanced, then option 1. Bash shell
  8. On the router, run cat /root/ >> /root/.ssh/authorized_keys.
  9. Run mkdir /root/.ssh/. Then run chmod 700 /root/.ssh/
  10. Run putty, load the profile for the router, then go to Connection->SSH->Auth, and in the “Private Key file for Authentication” box, type in %USERPROFILE%\putty_key.ppk, then save the profile.
  11. Finally, run rm /root/ Your router should now authenticate putty via ssh key. Remember to use the profile saved for your router.
Personal tools
Router software releases