| 1112 |
pvar->auth_state.TIS_prompt); |
pvar->auth_state.TIS_prompt); |
| 1113 |
destroy_malloced_string(&pvar->auth_state.TIS_prompt); |
destroy_malloced_string(&pvar->auth_state.TIS_prompt); |
| 1114 |
} |
} |
| 1115 |
|
|
| 1116 |
|
if (pvar->auth_state.echo) { |
| 1117 |
|
SendMessage(GetDlgItem(dlg, IDC_SSHPASSWORD), EM_SETPASSWORDCHAR, 0, 0); |
| 1118 |
|
} |
| 1119 |
} |
} |
| 1120 |
|
|
| 1121 |
static BOOL end_TIS_dlg(PTInstVar pvar, HWND dlg) |
static BOOL end_TIS_dlg(PTInstVar pvar, HWND dlg) |
| 1447 |
pvar->auth_state.user = NULL; |
pvar->auth_state.user = NULL; |
| 1448 |
pvar->auth_state.flags = 0; |
pvar->auth_state.flags = 0; |
| 1449 |
pvar->auth_state.TIS_prompt = NULL; |
pvar->auth_state.TIS_prompt = NULL; |
| 1450 |
|
pvar->auth_state.echo = 0; |
| 1451 |
pvar->auth_state.supported_types = 0; |
pvar->auth_state.supported_types = 0; |
| 1452 |
pvar->auth_state.cur_cred.method = SSH_AUTH_NONE; |
pvar->auth_state.cur_cred.method = SSH_AUTH_NONE; |
| 1453 |
pvar->auth_state.cur_cred.password = NULL; |
pvar->auth_state.cur_cred.password = NULL; |
| 1462 |
destroy_malloced_string(&pvar->auth_state.TIS_prompt); |
destroy_malloced_string(&pvar->auth_state.TIS_prompt); |
| 1463 |
} |
} |
| 1464 |
|
|
| 1465 |
void AUTH_set_TIS_mode(PTInstVar pvar, char *prompt, int len) |
void AUTH_set_TIS_mode(PTInstVar pvar, char *prompt, int len, int echo) |
| 1466 |
{ |
{ |
| 1467 |
if (pvar->auth_state.cur_cred.method == SSH_AUTH_TIS) { |
if (pvar->auth_state.cur_cred.method == SSH_AUTH_TIS) { |
| 1468 |
pvar->auth_state.mode = TIS_AUTH_MODE; |
pvar->auth_state.mode = TIS_AUTH_MODE; |
| 1471 |
pvar->auth_state.TIS_prompt = malloc(len + 1); |
pvar->auth_state.TIS_prompt = malloc(len + 1); |
| 1472 |
memcpy(pvar->auth_state.TIS_prompt, prompt, len); |
memcpy(pvar->auth_state.TIS_prompt, prompt, len); |
| 1473 |
pvar->auth_state.TIS_prompt[len] = 0; |
pvar->auth_state.TIS_prompt[len] = 0; |
| 1474 |
|
pvar->auth_state.echo = echo; |
| 1475 |
} else { |
} else { |
| 1476 |
AUTH_set_generic_mode(pvar); |
AUTH_set_generic_mode(pvar); |
| 1477 |
} |
} |