Tablets

Add a secure shell server to your Android tablet

Jack Wallen takes a look at SSH Server, a free secure shell server that doesn't require you to root your Android tablet.

Admins and power users, what better way to flex your Android tablet's muscle than to install a secure shell (SSH) server? You can easily use Secure FTP (SFTP) to copy files to your tablet, but for many SSH servers, you have to root your device. Fortunately, I've found a server that doesn't require root access -- that server is SSH Server, and it's available for free on the Google Play Store.

SSH Server offers the following features:

  • Support for SFTP and SCP
  • Multiple users can be set (each with their own options)
  • Set custom shell start command and arguments
  • Start/Stop server automatically when connected/disconnected from a specified Wi-Fi network or on boot
  • Verbose logging
  • Only allow specified IP addresses (optional)
  • Add Dynamic DNS Updater using the local or public IP of your device
  • Access server from web

Let's walk through the process of installing SSH Server, setting up a connection, and connecting to that server from a desktop machine.

Installation

Installation is simple. Just follow these steps:

  1. Open the Google Play Store
  2. Search for "ssh server"
  3. Tap the entry for SSH Server (by developer Ice Cold Apps)
  4. Tap Install
  5. Tap Accept & download

Once it's installed, you'll find SSH Server located in the app drawer or the home screen (or both locations). Tap the launcher to begin setting up your server.

Setting up a server

First, you must set up a server. During this process, you'll also have to create a user. Without creating a user, you won't be able to log into the server. Let's walk through this process.

  1. To create a new server, tap the Add button from the main window
  2. Tap SSH Server from the drop-down menu
  3. In the Settings tab (Figure A), fill out the necessary information
  4. Scroll to the bottom of this screen and enable the options that are needed (such as Vibrate on new connections, Start directly when app starts clean, etc.)
Figure A

SSH Server on the Verizon-branded Samsung Galaxy Tab.

Once you have these options take care of, but before you back out of this screen, tap on the Users tab. In this section, you must create a new user to go along with the server. Here are the steps:

  1. Tap Add
  2. Fill out the necessary information (Figure B)
  3. Tap the Back button when complete
Figure B

If you don't want to contain the user with the document root, uncheck that option, and they'll be able to navigate the file structure of the device.

It's very important to note that the directory specified for the user must be accessible by said user. The problem with a non-rooted Android device is that it's very difficult to create directories with permissions such that user, group, and others all have write permissions. Because of this, it's safe to use the /mnt/sdcard/Download directory. With this directory, you can use SFTP to copy files to the device.

Tap the back button out of the Settings window. When you're prompted to save your settings, tap Yes, and you'll be taken back to the main window.

Starting the server

You have two options here:

  • Start all servers
  • Start individual servers

NOTE: The free version of this software only allows you to have one server set up. However, you probably won't need more than this.

To start the server you've set up, tap the listing, and then tap Start/Stop. When the server is running, it will be listed as "started." Next, tap the Info button (at the top of the main window), where you'll find the information you need to make your connection (Figure C). Figure C

The Info screen shows you details for making your connection.

Now that you have all the information you need, it's time to connect.

Connecting to SSH Server

You can connect to your new SSH Server with most secure shell clients. If you're connecting via the command line, you'll need to make sure you add the port switch at the end of the command, like so:

ssh -v -l USERNAME ADDRESS -p PORT

Where USERNAME is the actual username set up for the server, ADDRESS is the IP address, and PORT is the port associated with the server.

About

Jack Wallen is an award-winning writer for TechRepublic and Linux.com. He’s an avid promoter of open source and the voice of The Android Expert. For more news about Jack Wallen, visit his website getjackd.net.

0 comments

Editor's Picks