Editing SSH

Warning: You are not logged in. Your IP address will be recorded in this page's edit history.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 3: Line 3:
#Administrating remote computers such as servers by using the device over a secure connection instead of plain-text.
#Administrating remote computers such as servers by using the device over a secure connection instead of plain-text.
#When performing console operations one may stumble upon limits such as text-input, battery life, raw horsepower, or available software.
#When performing console operations one may stumble upon limits such as text-input, battery life, raw horsepower, or available software.
-
#Some applications require a better network connection than device provides. E.g. a colocated 100 Mbit server running 24/7 is usually both faster as well as more reliable than a device on WiFi or 3G.
+
#Some applications require a better network connection than device provides. E.g. a colocated 100 mbit server running 24/7 is usually both faster as well as more reliable than a device on WiFi or 3G.
#Combined with a terminal emulator supporting detaching such as screen or dtach an application remains running after network connection is gone, device is unpowered.
#Combined with a terminal emulator supporting detaching such as screen or dtach an application remains running after network connection is gone, device is unpowered.
#SSH protocol can be used for remote X11, forwarding, tunneling, [[:wikipedia:Virtual private network|VPN]], port knocking alternative. These are intermediate-advanced topics requiring sufficient background knowledge.
#SSH protocol can be used for remote X11, forwarding, tunneling, [[:wikipedia:Virtual private network|VPN]], port knocking alternative. These are intermediate-advanced topics requiring sufficient background knowledge.
== Flavours to install on your device ==
== Flavours to install on your device ==
-
 
=== OpenSSH ===
=== OpenSSH ===
Line 16: Line 15:
=== Dropbear ===
=== Dropbear ===
-
 
[http://maemo.org/packages/view/dropbear/ Dropbear] is an alternative ssh client/server package which uses less disk/memory.
[http://maemo.org/packages/view/dropbear/ Dropbear] is an alternative ssh client/server package which uses less disk/memory.
Line 57: Line 55:
== PuTTY ==
== PuTTY ==
-
PuTTY is a client for the SSH and Telnet protocols. It is a popular client for Microsoft Windows, *Nix Operating Systems with ports even existing for Symbian phones, Windows Mobile and even the internet tablet itself. It can be used to connect to a tablet running OpenSSH to get a remote shell.
+
PuTTY is a client for the SSH & [the abysmally insecure] Telnet protocols. It is a popular client for Microsoft Windows, *Nix Operating Systems with ports even existing for Symbian phones, Windows Mobile and even the internet tablet itself. It can be used to connect to a tablet running OpenSSH to get a remote shell.
=== Usage ===
=== Usage ===
# Load up PuTTY on the machine you want to connect to the tablet from. You should see the window titled "PuTTY Configuration" and the "Session" category selected.
# Load up PuTTY on the machine you want to connect to the tablet from. You should see the window titled "PuTTY Configuration" and the "Session" category selected.
-
# Ensure "SSH" is selected as the "Connection type:" and enter the tablet's IP address in the "Host Name (or IP address)" section.
+
# Ensure "SSH" is selected as the "Connection type:" and enter <code>the tablet's ip</code> in the "Host Name (or IP address)" section.
# ''If'' you need to change any other settings out of necessity or personal preference for example, go and change settings as required.
# ''If'' you need to change any other settings out of necessity or personal preference for example, go and change settings as required.
# If you want to save these settings for future use to connect to the tablet quickly, add a name in "Saved Sessions" and press Save.
# If you want to save these settings for future use to connect to the tablet quickly, add a name in "Saved Sessions" and press Save.
-
# Press Open and enter the name of the user you wish to connect as when prompted. (<code>root</code> is commonly used)
+
# Press Open and enter the name of the user you wish to connect as when prompted. (root is commonly used)
Line 71: Line 69:
=== Extra security AND convenience ===
=== Extra security AND convenience ===
-
 
It is fairly easy to generate a secure key to allow key-based authentication to the device. Provided you keep the key secure this is more secure than using a UNIX password (PAM).
It is fairly easy to generate a secure key to allow key-based authentication to the device. Provided you keep the key secure this is more secure than using a UNIX password (PAM).
Line 77: Line 74:
On the device you need to create a directory in the appropriate users home directory:
On the device you need to create a directory in the appropriate users home directory:
-
cd
+
  cd
-
mkdir .ssh
+
  mkdir .ssh
-
chmod 700 .ssh
+
  chmod 700 .ssh
Back on the remote *NIX computer run the following command:
Back on the remote *NIX computer run the following command:
-
ssh-keygen -t rsa
+
  ssh-keygen -t rsa
-
You'll find a file in your home directory called <code>.ssh/id_rsa.pub</code> and <code>.ssh/id_rsa</code>. The .pub one is allowed out in public - you give it to other machines. The other one must be kept private.
+
You'll find a file in your home directory called .ssh/id_rsa.pub and .ssh/id_rsa
 +
The .pub one is allowed out in public - you give it to other machines. The other one must be kept private.
-
In the case your private key is stolen (ie. device stolen) the perpetrator has access to your machine without requiring a password. It is therefore recommended to use a password when issuing the <code>ssh-keygen</code> command. Note this password should ''not'' be the same as your UNIX password.
+
In the case your private key is stolen (ie. device stolen) the perpetrator has access to your machine without requiring a password. It is therefore recommended to use a password when issuing ssh-keygen command. Note this password must [i]not[/i] be the same as your UNIX password.
Then if you use OpenSSH:
Then if you use OpenSSH:
  su -c "scp .ssh/id_rsa.pub <user>@<hostname_or_ip_address:/home/user/.ssh/authorized_keys2"
  su -c "scp .ssh/id_rsa.pub <user>@<hostname_or_ip_address:/home/user/.ssh/authorized_keys2"
-
alternatively, use <code>ssh-copy-id</code> (it makes sure all permissions are correct on the receiving end):
+
alternatively, use ssh-copy-id (it makes sure all permissions are correct on the receiving end):
  ssh-copy-id -i .ssh/id_rsa.pub <user>@<hostname_or_ip_address>
  ssh-copy-id -i .ssh/id_rsa.pub <user>@<hostname_or_ip_address>
For dropbear:
For dropbear:
Line 102: Line 100:
=== VPN, tunneling ===
=== VPN, tunneling ===
-
 
Please see howto [http://www.undeadly.org/cgi?action=article&sid=20090903183235 Tunneling out of corporate networks (Part 1)]. Alternatively, [[reverse ssh]] may be useful.
Please see howto [http://www.undeadly.org/cgi?action=article&sid=20090903183235 Tunneling out of corporate networks (Part 1)]. Alternatively, [[reverse ssh]] may be useful.

Learn more about Contributing to the wiki.


Please note that all contributions to maemo.org wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see maemo.org wiki:Copyrights for details). Do not submit copyrighted work without permission!


Cancel | Editing help (opens in new window)
Retrieved from "http://wiki.maemo.org/SSH"