Mercurial > dropbear
comparison svr-runopts.c @ 435:337c45621e81
merge of 'a9b0496634cdd25647b65e585cc3240f3fa699ee'
and 'c22be8b8f570b48e9662dac32c7b3e7148a42206'
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Thu, 22 Feb 2007 14:53:49 +0000 |
parents | 0aaaf68e97dc 3bfbe95f9a14 |
children | d82a2a44c684 |
comparison
equal
deleted
inserted
replaced
434:0aaaf68e97dc | 435:337c45621e81 |
---|---|
73 #endif | 73 #endif |
74 "-p [address:]port\n" | 74 "-p [address:]port\n" |
75 " Listen on specified tcp port (and optionally address),\n" | 75 " Listen on specified tcp port (and optionally address),\n" |
76 " up to %d can be specified\n" | 76 " up to %d can be specified\n" |
77 " (default port is %s if none specified)\n" | 77 " (default port is %s if none specified)\n" |
78 "-P PidFile Create pid file PidFile\n" | |
79 " (default %s)\n" | |
78 #ifdef INETD_MODE | 80 #ifdef INETD_MODE |
79 "-i Start for inetd\n" | 81 "-i Start for inetd\n" |
80 #endif | 82 #endif |
81 #ifdef DEBUG_TRACE | 83 #ifdef DEBUG_TRACE |
82 "-v verbose\n" | 84 "-v verbose\n" |
86 DSS_PRIV_FILENAME, | 88 DSS_PRIV_FILENAME, |
87 #endif | 89 #endif |
88 #ifdef DROPBEAR_RSA | 90 #ifdef DROPBEAR_RSA |
89 RSA_PRIV_FILENAME, | 91 RSA_PRIV_FILENAME, |
90 #endif | 92 #endif |
91 DROPBEAR_MAX_PORTS, DROPBEAR_DEFPORT); | 93 DROPBEAR_MAX_PORTS, DROPBEAR_DEFPORT, DROPBEAR_PIDFILE); |
92 } | 94 } |
93 | 95 |
94 void svr_getopts(int argc, char ** argv) { | 96 void svr_getopts(int argc, char ** argv) { |
95 | 97 |
96 unsigned int i; | 98 unsigned int i; |
107 svr_opts.noauthpass = 0; | 109 svr_opts.noauthpass = 0; |
108 svr_opts.norootpass = 0; | 110 svr_opts.norootpass = 0; |
109 svr_opts.inetdmode = 0; | 111 svr_opts.inetdmode = 0; |
110 svr_opts.portcount = 0; | 112 svr_opts.portcount = 0; |
111 svr_opts.hostkey = NULL; | 113 svr_opts.hostkey = NULL; |
114 svr_opts.pidfile = DROPBEAR_PIDFILE; | |
112 #ifdef ENABLE_SVR_LOCALTCPFWD | 115 #ifdef ENABLE_SVR_LOCALTCPFWD |
113 svr_opts.nolocaltcp = 0; | 116 svr_opts.nolocaltcp = 0; |
114 #endif | 117 #endif |
115 #ifdef ENABLE_SVR_REMOTETCPFWD | 118 #ifdef ENABLE_SVR_REMOTETCPFWD |
116 svr_opts.noremotetcp = 0; | 119 svr_opts.noremotetcp = 0; |
187 break; | 190 break; |
188 #endif | 191 #endif |
189 case 'p': | 192 case 'p': |
190 nextisport = 1; | 193 nextisport = 1; |
191 break; | 194 break; |
195 case 'P': | |
196 next = &svr_opts.pidfile; | |
197 break; | |
192 #ifdef DO_MOTD | 198 #ifdef DO_MOTD |
193 /* motd is displayed by default, -m turns it off */ | 199 /* motd is displayed by default, -m turns it off */ |
194 case 'm': | 200 case 'm': |
195 svr_opts.domotd = 0; | 201 svr_opts.domotd = 0; |
196 break; | 202 break; |