Remote Access Cheat Sheet
In the bad old days, people could work on computers far away by using protocol/client systems called telnet and ftp. These were (and are) desperately insecure, inasmuch as all traffic associated with them passes unencrypted over the Internet, where it could be intercepted, stolen, or altered at will by crackers between the source and destination. In modern times, data are encrypted to avoid this problem. The standard suite of protocols for this is called SSH (Secure SHell).
Secure Shell is used to run a command line on a remote machine. The "ssh client" runs on your local machine, while the remote machine must run an "ssh daemon" - a server. The server listens for connections, and when one is requested, sends a key code to the client to identify itself. If the credentials supplied by the server match those the client has stored, then the session is started and the user identifies herself using a login name and password (or in one of several other ways).
There are two ssh protocols: ssh1, which uses 56-bit encryption (this means that the public keys can be expressed in 56 binary digits) and is susceptible to some attacks, and ssh2, which uses 128-bit encryption and is much safer.
Unix and OS X
Typically the command looks like
ssh -2 firstname.lastname@example.org
The latter command forces the client to try the ssh2 protocol first.
One must run an ssh client from the "Start" menu. At WSU we use an excellent free client called "Putty". See the page http://www.math.wsu.edu/helpdesk/on_line_help/ssh.html for details and references. The official download site for this is at chiark.greenend. Go figure.
Secure FTP (sftp) performs file transfers through an encrypted tunnel. While "encrypted tunnel" would make a terrific name for a metal band, in this case it means that all file transfers are encoded, so that the information in them cannot be understood by anyone intercepting it. To use it, you again need client software on your local machine, and an ssh server that supports sftp on the remote machine. While there are many client packages (for example, Linux people can use gFTP - use the SSH2 protocol in the upper right of the screen), in the simplest setting the interface is a command line. A free client for this is available at the page given in the link above. A typical session follows (with comments on the tasks performed in green).
|open the ftp session||>open ftphost.com|
|list the contents of the remote directory||>ls|
|change the remote directory||>cd newdirectory|
|change the local directory||>lcd mydirectory|
|put a file on the remote machine||>put myfile remotefile|
|get a file from the remote machine||>get remotefile|
|close the session||>exit|
Note that after you transfer a file, in order to make it public (so people can see it on the web) you may need to use ssh to go to the remote machine and change the access using a command such as
chmod go+rx remotefile
This command allows others to read or execute your file.
There are graphical interfaces for this. One of the best is the free client Filezilla. This product is not related to mozilla, the web browser, but it works well.
There is a second way to transfer files using SSH, called SCP (Secure CoPy). There is really little difference in the background details between this and sftp, but the appearance to the user is significantly different. In particular, the scp command works very like the cp (copy) command of Unix. For example, to copy a file called myfile.txt that resides on a computer named mycomputer.math.wsu.edu to the current directory, one could type a command of the form
scp email@example.com:myfile.txt .
A solution for the final is available.