Lines Matching refs:authctxt
158 kbdint_next_device(Authctxt *authctxt, KbdintAuthctxt *kbdintctxt) in kbdint_next_device() argument
174 !auth2_method_allowed(authctxt, in kbdint_next_device()
198 auth2_challenge(Authctxt *authctxt, char *devs) in auth2_challenge() argument
201 authctxt->user ? authctxt->user : "<nouser>", in auth2_challenge()
204 if (authctxt->user == NULL || !devs) in auth2_challenge()
206 if (authctxt->kbdintctxt == NULL) in auth2_challenge()
207 authctxt->kbdintctxt = kbdint_alloc(devs); in auth2_challenge()
208 return auth2_challenge_start(authctxt); in auth2_challenge()
213 auth2_challenge_stop(Authctxt *authctxt) in auth2_challenge_stop() argument
217 if (authctxt->kbdintctxt != NULL) { in auth2_challenge_stop()
218 kbdint_free(authctxt->kbdintctxt); in auth2_challenge_stop()
219 authctxt->kbdintctxt = NULL; in auth2_challenge_stop()
225 auth2_challenge_start(Authctxt *authctxt) in auth2_challenge_start() argument
227 KbdintAuthctxt *kbdintctxt = authctxt->kbdintctxt; in auth2_challenge_start()
232 if (kbdint_next_device(authctxt, kbdintctxt) == 0) { in auth2_challenge_start()
233 auth2_challenge_stop(authctxt); in auth2_challenge_start()
239 if ((kbdintctxt->ctxt = kbdintctxt->device->init_ctx(authctxt)) == NULL) { in auth2_challenge_start()
240 auth2_challenge_stop(authctxt); in auth2_challenge_start()
243 if (send_userauth_info_request(authctxt) == 0) { in auth2_challenge_start()
244 auth2_challenge_stop(authctxt); in auth2_challenge_start()
250 authctxt->postponed = 1; in auth2_challenge_start()
255 send_userauth_info_request(Authctxt *authctxt) in send_userauth_info_request() argument
261 kbdintctxt = authctxt->kbdintctxt; in send_userauth_info_request()
290 Authctxt *authctxt = ctxt; in input_userauth_info_response() local
297 if (authctxt == NULL) in input_userauth_info_response()
299 kbdintctxt = authctxt->kbdintctxt; in input_userauth_info_response()
305 authctxt->postponed = 0; /* reset */ in input_userauth_info_response()
329 authenticated = authctxt->valid ? 1 : 0; in input_userauth_info_response()
333 if (send_userauth_info_request(authctxt) == 1) in input_userauth_info_response()
334 authctxt->postponed = 1; in input_userauth_info_response()
341 if (!authctxt->postponed) { in input_userauth_info_response()
343 auth2_challenge_stop(authctxt); in input_userauth_info_response()
347 auth2_challenge_start(authctxt); in input_userauth_info_response()
350 userauth_finish(authctxt, authenticated, "keyboard-interactive", in input_userauth_info_response()