||Setting up WinSCP | Using WinSCP ||
WinSCP is a windows client for the SCP (secure copy) protocol, a way to transfer files across the network using the ssh (secure shell) encrypted protocol. Unlike other windows SCP clients, this one has a graphical user interface which looks like either Windows Explorer, or the Norton Commander interface. It replaces ws_ftp and similar FTP programs on windows clients in cases where SSH is needed to connect to the server.
This document is written for the WinSCP v2 beta product which was released in October 2001.
Download the WinSCP application from the website. This application downloads as an executable that you can run right away, without having to run a setup program. At that point, just doubleclick on the icon WinSCP2.exe and the program launches:
Enter in the hostname of the machine to which you'll be connecting,
your username, the Port number (almost certainly port 22), and
if you have an RSA key, the path to it.
Do not type in your password at this stage. If you do, the program will remember it. While this seems convenient, it leaves your password in a location on your computer where others can potentially read it, and also allows anyone who gets physical access to your machine straight access into the server. Saving passwords in any application is a bad idea, unless you know for sure they're encrypted (say, in a keyring).
Click on the Advanced tab:
Here you can set your preferred protocol, the encryption algorithm, and other settings. If your server supports it, use SSH 2, which is much more secure, and is not vulnerable to some exploits which have plagued SSH1. See your System Administrator for which protocol to use. The Encryption algorithm will depend upon the server as well. These settings can be experimented with. If it works, use it. The Logging option can help you troubleshoot which options to use.
If you do choose SSH 1, do not click on the Allow agent forwarding, as I believe this allows others to use WinSCP to forward their sessions with this program. (Does anyone know this for sure? I'd like to confirm it.)
Click on the Interface Tab. This controls how you would like the program to look:
I recommend using the Norton Commander, but this is a personal preference.
Click on the Preferences button.
If you have "Copy files using double-click" enabled, I highly recommend turning on Confirm copy on double-click operation, otherwise it's extremely easy to accidently double click on a file and overwrite your newer file.
Enable Logging on the Logging tab if you're having problems connecting, or if you're terribly curious about such things. For normal usage, it probablyi isn't necessary.
On the Directories tab, you can set default starting locations for the session, both on your client machine, Local Directory (Left Panel) and for the Server Remote Directory (Right Panel). For instance, you might want to set the Local directory to C:\My Documents and leave the Remote blank, as it will default to your home directory on the server.
But if you only use WinSCP to put up webpages, you might put
htdocs/ in for the Remote directory.
Once you have all of these things set, click on the Stored Sessions tab.
Click on Save and all of these settings will be saved. (Remember not to have your password saved.
Once all of your settings are set (and you should only have to do all of that once for each session), click on the Login button.
The first time you log into a server, you'll get a dialog which tells you that the server's host key isn't cached in the registry:
How sever a problem this is depends on your network setup. Generally, the first time you connect to a host, this will happen. This isn't true if you, or your administrator, has pre-loaded the keys somehow.
Usually, if this is the first time you've connected to a host, this is okay. So click on "Yes". However, if you've connected to this host before, and you get this error, contact your administrator, because there is a chance the machine has been compromised. (There is also a good chance the machine was just re-installed, or SSH was updated, but check anyway.)
Then, you'll get a dialog asking for your password:
Enter your password, and that should connect you: