Mercurial > dropbear
comparison cli-runopts.c @ 325:0e4f225b7e07
Add -N "no remote command" dbclient option.
Document -N in dbclient.1 and -P in dropbear.8
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Wed, 07 Jun 2006 15:01:20 +0000 |
parents | 306499676384 |
children | d965110e3f5c |
comparison
equal
deleted
inserted
replaced
324:bc7c134982df | 325:0e4f225b7e07 |
---|---|
48 "Options are:\n" | 48 "Options are:\n" |
49 "-p <remoteport>\n" | 49 "-p <remoteport>\n" |
50 "-l <username>\n" | 50 "-l <username>\n" |
51 "-t Allocate a pty\n" | 51 "-t Allocate a pty\n" |
52 "-T Don't allocate a pty\n" | 52 "-T Don't allocate a pty\n" |
53 "-N Don't run a remote command\n" | |
53 #ifdef ENABLE_CLI_PUBKEY_AUTH | 54 #ifdef ENABLE_CLI_PUBKEY_AUTH |
54 "-i <identityfile> (multiple allowed)\n" | 55 "-i <identityfile> (multiple allowed)\n" |
55 #endif | 56 #endif |
56 #ifdef ENABLE_CLI_LOCALTCPFWD | 57 #ifdef ENABLE_CLI_LOCALTCPFWD |
57 "-L <listenport:remotehost:remoteport> Local port forwarding\n" | 58 "-L <listenport:remotehost:remoteport> Local port forwarding\n" |
86 cli_opts.progname = argv[0]; | 87 cli_opts.progname = argv[0]; |
87 cli_opts.remotehost = NULL; | 88 cli_opts.remotehost = NULL; |
88 cli_opts.remoteport = NULL; | 89 cli_opts.remoteport = NULL; |
89 cli_opts.username = NULL; | 90 cli_opts.username = NULL; |
90 cli_opts.cmd = NULL; | 91 cli_opts.cmd = NULL; |
92 cli_opts.no_cmd = 0; | |
91 cli_opts.wantpty = 9; /* 9 means "it hasn't been touched", gets set later */ | 93 cli_opts.wantpty = 9; /* 9 means "it hasn't been touched", gets set later */ |
92 #ifdef ENABLE_CLI_PUBKEY_AUTH | 94 #ifdef ENABLE_CLI_PUBKEY_AUTH |
93 cli_opts.privkeys = NULL; | 95 cli_opts.privkeys = NULL; |
94 #endif | 96 #endif |
95 #ifdef ENABLE_CLI_LOCALTCPFWD | 97 #ifdef ENABLE_CLI_LOCALTCPFWD |
160 case 't': /* we want a pty */ | 162 case 't': /* we want a pty */ |
161 cli_opts.wantpty = 1; | 163 cli_opts.wantpty = 1; |
162 break; | 164 break; |
163 case 'T': /* don't want a pty */ | 165 case 'T': /* don't want a pty */ |
164 cli_opts.wantpty = 0; | 166 cli_opts.wantpty = 0; |
167 break; | |
168 case 'N': | |
169 cli_opts.no_cmd = 1; | |
165 break; | 170 break; |
166 #ifdef ENABLE_CLI_LOCALTCPFWD | 171 #ifdef ENABLE_CLI_LOCALTCPFWD |
167 case 'L': | 172 case 'L': |
168 nextislocal = 1; | 173 nextislocal = 1; |
169 break; | 174 break; |