Lines Matching refs:authctxt
190 auth2_challenge(Authctxt *authctxt, char *devs) in auth2_challenge() argument
193 authctxt->user ? authctxt->user : "<nouser>", in auth2_challenge()
196 if (authctxt->user == NULL || !devs) in auth2_challenge()
198 if (authctxt->kbdintctxt == NULL) in auth2_challenge()
199 authctxt->kbdintctxt = kbdint_alloc(devs); in auth2_challenge()
200 return auth2_challenge_start(authctxt); in auth2_challenge()
205 auth2_challenge_stop(Authctxt *authctxt) in auth2_challenge_stop() argument
209 if (authctxt->kbdintctxt != NULL) { in auth2_challenge_stop()
210 kbdint_free(authctxt->kbdintctxt); in auth2_challenge_stop()
211 authctxt->kbdintctxt = NULL; in auth2_challenge_stop()
217 auth2_challenge_start(Authctxt *authctxt) in auth2_challenge_start() argument
219 KbdintAuthctxt *kbdintctxt = authctxt->kbdintctxt; in auth2_challenge_start()
225 auth2_challenge_stop(authctxt); in auth2_challenge_start()
231 if ((kbdintctxt->ctxt = kbdintctxt->device->init_ctx(authctxt)) == NULL) { in auth2_challenge_start()
232 auth2_challenge_stop(authctxt); in auth2_challenge_start()
235 if (send_userauth_info_request(authctxt) == 0) { in auth2_challenge_start()
236 auth2_challenge_stop(authctxt); in auth2_challenge_start()
242 authctxt->postponed = 1; in auth2_challenge_start()
247 send_userauth_info_request(Authctxt *authctxt) in send_userauth_info_request() argument
253 kbdintctxt = authctxt->kbdintctxt; in send_userauth_info_request()
282 Authctxt *authctxt = ctxt; in input_userauth_info_response() local
288 if (authctxt == NULL) in input_userauth_info_response()
290 kbdintctxt = authctxt->kbdintctxt; in input_userauth_info_response()
296 authctxt->postponed = 0; /* reset */ in input_userauth_info_response()
321 authenticated = authctxt->valid ? 1 : 0; in input_userauth_info_response()
325 if (send_userauth_info_request(authctxt) == 1) in input_userauth_info_response()
326 authctxt->postponed = 1; in input_userauth_info_response()
335 if (!authctxt->postponed) { in input_userauth_info_response()
337 auth2_challenge_stop(authctxt); in input_userauth_info_response()
341 auth2_challenge_start(authctxt); in input_userauth_info_response()
344 userauth_finish(authctxt, authenticated, method); in input_userauth_info_response()