From e2a197cf4658f554fc653403bfe8aa340ae8c2fa Mon Sep 17 00:00:00 2001 From: jacob Date: Wed, 11 Sep 2002 17:30:36 +0000 Subject: [PATCH] Updated usage messages for command-line utilities to reflect new options. Updated manual to reflect reality (e.g. usage messages, '-p port' not actually implemented, sprinkle references to '-i keyfile'). (I've put "Release 0.53" in the messages; let's hope this doesn't cause a flood of "where is 0.53?" email.) I don't guarantee that the result is entirely sane and sensible in all respects, but it is at least consistent. git-svn-id: svn://svn.tartarus.org/sgt/putty@1951 cda61777-01e9-0310-a592-d414129be87e --- doc/pageant.but | 6 ++++-- doc/plink.but | 21 ++++++++++++++++++--- doc/pscp.but | 23 +++++++++++++++++------ doc/pubkey.but | 9 ++++++--- doc/using.but | 22 +++++++++++----------- plink.c | 15 +++++++++++++-- psftp.c | 6 ++++++ scp.c | 6 ++++++ 8 files changed, 81 insertions(+), 27 deletions(-) diff --git a/doc/pageant.but b/doc/pageant.but index c54c0175..c1f2a825 100644 --- a/doc/pageant.but +++ b/doc/pageant.but @@ -1,4 +1,4 @@ -\versionid $Id: pageant.but,v 1.7 2001/12/20 15:27:40 simon Exp $ +\versionid $Id: pageant.but,v 1.8 2002/09/11 17:30:36 jacob Exp $ \C{pageant} Using Pageant for authentication @@ -162,7 +162,9 @@ secret. To enable agent forwarding, first start Pageant. Then set up a PuTTY SSH session in which \q{Allow agent forwarding} is enabled (see -\k{config-ssh-agentfwd}). Open the session as normal. +\k{config-ssh-agentfwd}). Open the session as normal. (Alternatively, +you can use the \c{-A} command line option; see +\k{using-cmdline-agent} for details.) If this has worked, your applications on the server should now have access to a Unix domain socket which the SSH server will forward diff --git a/doc/plink.but b/doc/plink.but index 44cf8d7d..6cc461e6 100644 --- a/doc/plink.but +++ b/doc/plink.but @@ -1,4 +1,4 @@ -\versionid $Id: plink.but,v 1.16 2002/08/07 19:20:06 simon Exp $ +\versionid $Id: plink.but,v 1.17 2002/09/11 17:30:36 jacob Exp $ \C{plink} Using the command-line connection tool Plink @@ -43,13 +43,28 @@ use Plink: \c Z:\sysosd>plink \c PuTTY Link: command-line connection utility -\c Release 0.50 +\c Release 0.53 \c Usage: plink [options] [user@]host [command] +\c ("host" can also be a PuTTY saved session name) \c Options: \c -v show verbose messages -\c -ssh force use of ssh protocol +\c -load sessname Load settings from saved session +\c -ssh -telnet -rlogin -raw +\c force use of a particular protocol (default SSH) \c -P port connect to specified port +\c -l user connect with specified username +\c -m file read remote command(s) from file +\c -batch disable all interactive prompts +\c The following options only apply to SSH connections: \c -pw passw login with specified password +\c -L listen-port:host:port Forward local port to remote address +\c -R listen-port:host:port Forward remote port to local address +\c -X -x enable / disable X11 forwarding +\c -A -a enable / disable agent forwarding +\c -t -T enable / disable pty allocation +\c -1 -2 force use of particular protocol version +\c -C enable compression +\c -i key private key file for authentication Once this works, you are ready to use Plink. diff --git a/doc/pscp.but b/doc/pscp.but index ad0144c7..1a322f6b 100644 --- a/doc/pscp.but +++ b/doc/pscp.but @@ -1,4 +1,4 @@ -\versionid $Id: pscp.but,v 1.21 2002/08/07 19:20:06 simon Exp $ +\versionid $Id: pscp.but,v 1.22 2002/09/11 17:30:36 jacob Exp $ \#FIXME: Need examples @@ -41,17 +41,24 @@ use PSCP: \c Z:\owendadmin>pscp \c PuTTY Secure Copy client -\c Release 0.50 +\c Release 0.53 \c Usage: pscp [options] [user@]host:source target -\c pscp [options] source [source...] [user@]host:target -\c pscp [options] -ls user@host:filespec +\c pscp [options] source [source...] [user@]host:target +\c pscp [options] -ls user@host:filespec \c Options: \c -p preserve file attributes \c -q quiet, don't show statistics \c -r copy directories recursively \c -v show verbose messages +\c -load sessname Load settings from saved session \c -P port connect to specified port +\c -l user connect with specified username \c -pw passw login with specified password +\c -1 -2 force use of particular SSH protocol version +\c -C enable compression +\c -i key private key file for authentication +\c -batch disable all interactive prompts +\c -unsafe allow server-side wildcards (DANGEROUS) (PSCP's interface is much like the Unix \c{scp} command, if you're familiar with that.) @@ -226,7 +233,7 @@ using code such as this: \S{pscp-pubkey} Using public key authentication with PSCP Like PuTTY, PSCP can authenticate using a public key instead of a -password. There are two ways you can do this. +password. There are three ways you can do this. Firstly, PSCP can use PuTTY saved sessions in place of hostnames (see \k{pscp-usage-basics-host}). So you would do this: @@ -240,7 +247,11 @@ username to log in as (see \k{config-username}). hostname: type \c{pscp sessionname:file localfile}, where \c{sessionname} is replaced by the name of your saved session. -Secondly, PSCP will attempt to authenticate using Pageant if Pageant +Secondly, you can supply the name of a private key file on the command +line, with the \c{-i} option. See \k{using-cmdline-identity} for more +information. + +Thirdly, PSCP will attempt to authenticate using Pageant if Pageant is running (see \k{pageant}). So you would do this: \b Ensure Pageant is running, and has your private key stored in it. diff --git a/doc/pubkey.but b/doc/pubkey.but index e6523201..87eb2fef 100644 --- a/doc/pubkey.but +++ b/doc/pubkey.but @@ -1,4 +1,4 @@ -\versionid $Id: pubkey.but,v 1.17 2002/05/18 09:20:41 simon Exp $ +\versionid $Id: pubkey.but,v 1.18 2002/09/11 17:30:36 jacob Exp $ \C{pubkey} Using public keys for SSH authentication @@ -413,11 +413,14 @@ such as Your server should now be configured to accept authentication using your private key. Now you need to configure PuTTY to \e{attempt} -authentication using your private key. You can do this in either of -two ways: +authentication using your private key. You can do this in any of +three ways: \b Select the private key in PuTTY's configuration. See \k{config-ssh-privkey} for details. +\b Specify the key file on the command line with the \c{-i} option. +See \k{using-cmdline-identity} for details. + \b Load the private key into Pageant (see \k{pageant}). In this case PuTTY will automatically try to use it for authentication if it can. diff --git a/doc/using.but b/doc/using.but index ae093b2d..ad5bab08 100644 --- a/doc/using.but +++ b/doc/using.but @@ -1,4 +1,4 @@ -\versionid $Id: using.but,v 1.7 2002/08/07 19:20:06 simon Exp $ +\versionid $Id: using.but,v 1.8 2002/09/11 17:30:36 jacob Exp $ \C{using} Using PuTTY @@ -350,12 +350,12 @@ straight into a session. To start a connection to a server called \c{host}: -\c putty.exe [-ssh | -telnet | -rlogin | -raw] [user@]host[:port] +\c putty.exe [-ssh | -telnet | -rlogin | -raw] [user@]host If this syntax is used, settings are taken from the Default Settings -(see \k{config-saving}); \c{user} and \c{port} override these -settings if supplied. Also, you can specify a protocol, which will -override the default protocol (see \k{using-cmdline-protocol}). +(see \k{config-saving}); \c{user} overrides these settings if +supplied. Also, you can specify a protocol, which will override the +default protocol (see \k{using-cmdline-protocol}). For telnet sessions, the following alternative syntax is supported (this makes PuTTY suitable for use as a URL handler for telnet URLs in @@ -481,14 +481,14 @@ more than one command in sequence, or a whole shell script. This option is not available in the file transfer tools PSCP and PSFTP. -\S2{using-cmdline-p} \c{-p} or \c{-P}: specify a port number +\S2{using-cmdline-p} \c{-P}: specify a port number -The \c{-p} option (you can also write it as \c{-P}) is used to -specify the port number to connect to. If you have a Telnet server -running on port 9696 of a machine instead of port 23, for example: +The \c{-P} option is used to specify the port number to connect to. If +you have a Telnet server running on port 9696 of a machine instead of +port 23, for example: -\c putty -telnet -p 9696 host.name -\c plink -telnet -p 9696 host.name +\c putty -telnet -P 9696 host.name +\c plink -telnet -P 9696 host.name (Note that this option is more useful in Plink than in PuTTY, because in PuTTY you can write \c{putty -telnet host.name 9696} in diff --git a/plink.c b/plink.c index 91484c66..9229fa8e 100644 --- a/plink.c +++ b/plink.c @@ -185,14 +185,25 @@ static void usage(void) printf(" (\"host\" can also be a PuTTY saved session name)\n"); printf("Options:\n"); printf(" -v show verbose messages\n"); - printf(" -ssh force use of ssh protocol\n"); + printf(" -load sessname Load settings from saved session\n"); + printf(" -ssh -telnet -rlogin -raw\n"); + printf(" force use of a particular protocol (default SSH)\n"); printf(" -P port connect to specified port\n"); - printf(" -pw passw login with specified password\n"); + printf(" -l user connect with specified username\n"); printf(" -m file read remote command(s) from file\n"); + printf(" -batch disable all interactive prompts\n"); + printf("The following options only apply to SSH connections:\n"); + printf(" -pw passw login with specified password\n"); printf(" -L listen-port:host:port Forward local port to " "remote address\n"); printf(" -R listen-port:host:port Forward remote port to" " local address\n"); + printf(" -X -x enable / disable X11 forwarding\n"); + printf(" -A -a enable / disable agent forwarding\n"); + printf(" -t -T enable / disable pty allocation\n"); + printf(" -1 -2 force use of particular protocol version\n"); + printf(" -C enable compression\n"); + printf(" -i key private key file for authentication\n"); exit(1); } diff --git a/psftp.c b/psftp.c index d498b07d..2bf0ded5 100644 --- a/psftp.c +++ b/psftp.c @@ -1650,8 +1650,14 @@ static void usage(void) printf(" -bc output batchfile commands\n"); printf(" -be don't stop batchfile processing if errors\n"); printf(" -v show verbose messages\n"); + printf(" -load sessname Load settings from saved session\n"); + printf(" -l user connect with specified username\n"); printf(" -P port connect to specified port\n"); printf(" -pw passw login with specified password\n"); + printf(" -1 -2 force use of particular SSH protocol version\n"); + printf(" -C enable compression\n"); + printf(" -i key private key file for authentication\n"); + printf(" -batch disable all interactive prompts\n"); cleanup_exit(1); } diff --git a/scp.c b/scp.c index 13b8080f..cc67a625 100644 --- a/scp.c +++ b/scp.c @@ -2088,8 +2088,14 @@ static void usage(void) printf(" -q quiet, don't show statistics\n"); printf(" -r copy directories recursively\n"); printf(" -v show verbose messages\n"); + printf(" -load sessname Load settings from saved session\n"); printf(" -P port connect to specified port\n"); + printf(" -l user connect with specified username\n"); printf(" -pw passw login with specified password\n"); + printf(" -1 -2 force use of particular SSH protocol version\n"); + printf(" -C enable compression\n"); + printf(" -i key private key file for authentication\n"); + printf(" -batch disable all interactive prompts\n"); printf(" -unsafe allow server-side wildcards (DANGEROUS)\n"); #if 0 /* -- 2.11.0