Mercurial > dropbear
comparison cli-auth.c @ 360:09cb54106e89 insecure-nocrypto
explicit merge of '0501e6f661b5415eb76f3b312d183c3adfbfb712'
and '2b954d406290e6a2be8eb4a262d3675ac95ac544'
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Mon, 02 Oct 2006 06:39:32 +0000 |
parents | 64abb124763d |
children | 582cb38e4eb5 |
comparison
equal
deleted
inserted
replaced
295:03f65e461915 | 360:09cb54106e89 |
---|---|
249 cli_ses.lastauthtype = AUTH_TYPE_PUBKEY; | 249 cli_ses.lastauthtype = AUTH_TYPE_PUBKEY; |
250 } | 250 } |
251 #endif | 251 #endif |
252 | 252 |
253 #ifdef ENABLE_CLI_INTERACT_AUTH | 253 #ifdef ENABLE_CLI_INTERACT_AUTH |
254 if (!finished && ses.authstate.authtypes & AUTH_TYPE_INTERACT) { | 254 if (ses.keys->trans_algo_crypt->cipherdesc == NULL) { |
255 fprintf(stderr, "Sorry, I won't let you use interactive auth unencrypted.\n"); | |
256 } | |
257 else if (!finished && ses.authstate.authtypes & AUTH_TYPE_INTERACT) { | |
255 if (cli_ses.auth_interact_failed) { | 258 if (cli_ses.auth_interact_failed) { |
256 finished = 0; | 259 finished = 0; |
257 } else { | 260 } else { |
258 cli_auth_interactive(); | 261 cli_auth_interactive(); |
259 cli_ses.lastauthtype = AUTH_TYPE_INTERACT; | 262 cli_ses.lastauthtype = AUTH_TYPE_INTERACT; |
261 } | 264 } |
262 } | 265 } |
263 #endif | 266 #endif |
264 | 267 |
265 #ifdef ENABLE_CLI_PASSWORD_AUTH | 268 #ifdef ENABLE_CLI_PASSWORD_AUTH |
266 if (!finished && ses.authstate.authtypes & AUTH_TYPE_PASSWORD) { | 269 if (ses.keys->trans_algo_crypt->cipherdesc == NULL) { |
270 fprintf(stderr, "Sorry, I won't let you use password auth unencrypted.\n"); | |
271 } | |
272 else if (!finished && ses.authstate.authtypes & AUTH_TYPE_PASSWORD) { | |
267 cli_auth_password(); | 273 cli_auth_password(); |
268 finished = 1; | 274 finished = 1; |
269 cli_ses.lastauthtype = AUTH_TYPE_PASSWORD; | 275 cli_ses.lastauthtype = AUTH_TYPE_PASSWORD; |
270 } | 276 } |
271 #endif | 277 #endif |