comparison svr-runopts.c @ 692:c58a15983808

Allow configuring "allow blank password option" at runtime Changes this from a compile-time switch to a command-line option. Signed-off-by: Paul Eggleton <[email protected]>
author Paul Eggleton <paul.eggleton@linux.intel.com>
date Tue, 12 Feb 2013 15:52:57 +0000
parents 675bbd630f5d
children 002cf09827c0
comparison
equal deleted inserted replaced
691:e698d1a9f428 692:c58a15983808
61 #endif 61 #endif
62 "-w Disallow root logins\n" 62 "-w Disallow root logins\n"
63 #if defined(ENABLE_SVR_PASSWORD_AUTH) || defined(ENABLE_SVR_PAM_AUTH) 63 #if defined(ENABLE_SVR_PASSWORD_AUTH) || defined(ENABLE_SVR_PAM_AUTH)
64 "-s Disable password logins\n" 64 "-s Disable password logins\n"
65 "-g Disable password logins for root\n" 65 "-g Disable password logins for root\n"
66 "-B Allow blank password logins\n"
66 #endif 67 #endif
67 #ifdef ENABLE_SVR_LOCALTCPFWD 68 #ifdef ENABLE_SVR_LOCALTCPFWD
68 "-j Disable local port forwarding\n" 69 "-j Disable local port forwarding\n"
69 #endif 70 #endif
70 #ifdef ENABLE_SVR_REMOTETCPFWD 71 #ifdef ENABLE_SVR_REMOTETCPFWD
113 svr_opts.banner = NULL; 114 svr_opts.banner = NULL;
114 svr_opts.forkbg = 1; 115 svr_opts.forkbg = 1;
115 svr_opts.norootlogin = 0; 116 svr_opts.norootlogin = 0;
116 svr_opts.noauthpass = 0; 117 svr_opts.noauthpass = 0;
117 svr_opts.norootpass = 0; 118 svr_opts.norootpass = 0;
119 svr_opts.allowblankpass = 0;
118 svr_opts.inetdmode = 0; 120 svr_opts.inetdmode = 0;
119 svr_opts.portcount = 0; 121 svr_opts.portcount = 0;
120 svr_opts.hostkey = NULL; 122 svr_opts.hostkey = NULL;
121 svr_opts.pidfile = DROPBEAR_PIDFILE; 123 svr_opts.pidfile = DROPBEAR_PIDFILE;
122 #ifdef ENABLE_SVR_LOCALTCPFWD 124 #ifdef ENABLE_SVR_LOCALTCPFWD
232 svr_opts.noauthpass = 1; 234 svr_opts.noauthpass = 1;
233 break; 235 break;
234 case 'g': 236 case 'g':
235 svr_opts.norootpass = 1; 237 svr_opts.norootpass = 1;
236 break; 238 break;
239 case 'B':
240 svr_opts.allowblankpass = 1;
241 break;
237 #endif 242 #endif
238 case 'h': 243 case 'h':
239 printhelp(argv[0]); 244 printhelp(argv[0]);
240 exit(EXIT_FAILURE); 245 exit(EXIT_FAILURE);
241 break; 246 break;