17c478bd9Sstevel@tonic-gate /* $OpenBSD: auth.h,v 1.41 2002/09/26 11:38:43 markus Exp $ */ 27c478bd9Sstevel@tonic-gate 37c478bd9Sstevel@tonic-gate #ifndef _AUTH_H 47c478bd9Sstevel@tonic-gate #define _AUTH_H 57c478bd9Sstevel@tonic-gate 67c478bd9Sstevel@tonic-gate #ifdef __cplusplus 77c478bd9Sstevel@tonic-gate extern "C" { 87c478bd9Sstevel@tonic-gate #endif 97c478bd9Sstevel@tonic-gate 107c478bd9Sstevel@tonic-gate 117c478bd9Sstevel@tonic-gate /* 127c478bd9Sstevel@tonic-gate * Copyright (c) 2000 Markus Friedl. All rights reserved. 137c478bd9Sstevel@tonic-gate * 147c478bd9Sstevel@tonic-gate * Redistribution and use in source and binary forms, with or without 157c478bd9Sstevel@tonic-gate * modification, are permitted provided that the following conditions 167c478bd9Sstevel@tonic-gate * are met: 177c478bd9Sstevel@tonic-gate * 1. Redistributions of source code must retain the above copyright 187c478bd9Sstevel@tonic-gate * notice, this list of conditions and the following disclaimer. 197c478bd9Sstevel@tonic-gate * 2. Redistributions in binary form must reproduce the above copyright 207c478bd9Sstevel@tonic-gate * notice, this list of conditions and the following disclaimer in the 217c478bd9Sstevel@tonic-gate * documentation and/or other materials provided with the distribution. 227c478bd9Sstevel@tonic-gate * 237c478bd9Sstevel@tonic-gate * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 247c478bd9Sstevel@tonic-gate * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 257c478bd9Sstevel@tonic-gate * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 267c478bd9Sstevel@tonic-gate * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 277c478bd9Sstevel@tonic-gate * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 287c478bd9Sstevel@tonic-gate * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 297c478bd9Sstevel@tonic-gate * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 307c478bd9Sstevel@tonic-gate * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 317c478bd9Sstevel@tonic-gate * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 327c478bd9Sstevel@tonic-gate * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 337c478bd9Sstevel@tonic-gate * 347c478bd9Sstevel@tonic-gate */ 357c478bd9Sstevel@tonic-gate /* 36*d8a94255SErik Trauschke * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 377c478bd9Sstevel@tonic-gate * Use is subject to license terms. 387c478bd9Sstevel@tonic-gate */ 397c478bd9Sstevel@tonic-gate 407c478bd9Sstevel@tonic-gate #include "key.h" 417c478bd9Sstevel@tonic-gate #include "hostfile.h" 427c478bd9Sstevel@tonic-gate #include <openssl/rsa.h> 437c478bd9Sstevel@tonic-gate 447c478bd9Sstevel@tonic-gate #ifdef USE_PAM 457c478bd9Sstevel@tonic-gate #include <security/pam_appl.h> 467c478bd9Sstevel@tonic-gate #endif /* USE_PAM */ 477c478bd9Sstevel@tonic-gate 487c478bd9Sstevel@tonic-gate #ifdef HAVE_LOGIN_CAP 497c478bd9Sstevel@tonic-gate #include <login_cap.h> 507c478bd9Sstevel@tonic-gate #endif 517c478bd9Sstevel@tonic-gate #ifdef BSD_AUTH 527c478bd9Sstevel@tonic-gate #include <bsd_auth.h> 537c478bd9Sstevel@tonic-gate #endif 547c478bd9Sstevel@tonic-gate #ifdef KRB5 557c478bd9Sstevel@tonic-gate #include <krb5.h> 567c478bd9Sstevel@tonic-gate #endif 577c478bd9Sstevel@tonic-gate 587c478bd9Sstevel@tonic-gate typedef struct Authctxt Authctxt; 597c478bd9Sstevel@tonic-gate typedef struct Authmethod Authmethod; 607c478bd9Sstevel@tonic-gate typedef struct KbdintDevice KbdintDevice; 617c478bd9Sstevel@tonic-gate 627c478bd9Sstevel@tonic-gate #ifdef USE_PAM 637c478bd9Sstevel@tonic-gate typedef struct pam_stuff pam_stuff; 647c478bd9Sstevel@tonic-gate 657c478bd9Sstevel@tonic-gate struct pam_stuff { 667c478bd9Sstevel@tonic-gate Authctxt *authctxt; 677c478bd9Sstevel@tonic-gate pam_handle_t *h; 687c478bd9Sstevel@tonic-gate int state; 697c478bd9Sstevel@tonic-gate int last_pam_retval; 707c478bd9Sstevel@tonic-gate }; 717c478bd9Sstevel@tonic-gate 727c478bd9Sstevel@tonic-gate /* See auth-pam.h and auth-pam.c */ 737c478bd9Sstevel@tonic-gate 747c478bd9Sstevel@tonic-gate #define PAM_S_DONE_ACCT_MGMT 0x01 /* acct_mgmt done */ 757c478bd9Sstevel@tonic-gate #define PAM_S_DONE_SETCRED 0x02 /* setcred done */ 767c478bd9Sstevel@tonic-gate #define PAM_S_DONE_OPEN_SESSION 0x04 /* open_session done */ 777c478bd9Sstevel@tonic-gate #define PAM_S_DONE 0x07 /* all done */ 787c478bd9Sstevel@tonic-gate #endif /* USE_PAM */ 797c478bd9Sstevel@tonic-gate 807c478bd9Sstevel@tonic-gate struct Authctxt { 817c478bd9Sstevel@tonic-gate int success; 827c478bd9Sstevel@tonic-gate int valid; 837c478bd9Sstevel@tonic-gate int attempt; /* all userauth attempt count */ 847c478bd9Sstevel@tonic-gate int init_attempt; /* passwd/kbd-int attempt count */ 857c478bd9Sstevel@tonic-gate int failures; 867c478bd9Sstevel@tonic-gate int init_failures; 877c478bd9Sstevel@tonic-gate int unwind_dispatch_loop; 887c478bd9Sstevel@tonic-gate int v1_auth_type; 897c478bd9Sstevel@tonic-gate char *v1_auth_name; 907c478bd9Sstevel@tonic-gate Authmethod *method; 917c478bd9Sstevel@tonic-gate char *user; 927c478bd9Sstevel@tonic-gate char *service; 937c478bd9Sstevel@tonic-gate struct passwd *pw; 947c478bd9Sstevel@tonic-gate char *style; 957c478bd9Sstevel@tonic-gate void *kbdintctxt; /* XXX Switch to method_data; 967c478bd9Sstevel@tonic-gate v1 still needs this*/ 977c478bd9Sstevel@tonic-gate #ifdef USE_PAM 987c478bd9Sstevel@tonic-gate pam_stuff *pam; 99f44ef466Sjp161948 char *cuser; /* client side user, needed for setting 100f44ef466Sjp161948 PAM_AUSER for hostbased authentication 101f44ef466Sjp161948 using roles */ 1027c478bd9Sstevel@tonic-gate u_long last_login_time; /* need to get the time of 1037c478bd9Sstevel@tonic-gate last login before calling 1047c478bd9Sstevel@tonic-gate pam_open_session() */ 1057c478bd9Sstevel@tonic-gate char last_login_host[MAXHOSTNAMELEN]; 1067c478bd9Sstevel@tonic-gate int pam_retval; /* pam_stuff is cleaned before 1077c478bd9Sstevel@tonic-gate BSM login failure auditing */ 1087c478bd9Sstevel@tonic-gate #endif /* USE_PAM */ 1097c478bd9Sstevel@tonic-gate 1107c478bd9Sstevel@tonic-gate /* SUNW - What follows remains to reduce diffs with OpenSSH but 1117c478bd9Sstevel@tonic-gate * is not used in Solaris. The Solaris SSH internal 1127c478bd9Sstevel@tonic-gate * architecture requires that this stuff move into the 1137c478bd9Sstevel@tonic-gate * Authmethod method_data. 1147c478bd9Sstevel@tonic-gate */ 1157c478bd9Sstevel@tonic-gate #ifndef SUNW_SSH 1167c478bd9Sstevel@tonic-gate #ifdef BSD_AUTH 1177c478bd9Sstevel@tonic-gate auth_session_t *as; 1187c478bd9Sstevel@tonic-gate #endif 1197c478bd9Sstevel@tonic-gate #ifdef KRB4 1207c478bd9Sstevel@tonic-gate char *krb4_ticket_file; 1217c478bd9Sstevel@tonic-gate #endif 1227c478bd9Sstevel@tonic-gate #ifdef KRB5 1237c478bd9Sstevel@tonic-gate krb5_context krb5_ctx; 1247c478bd9Sstevel@tonic-gate krb5_auth_context krb5_auth_ctx; 1257c478bd9Sstevel@tonic-gate krb5_ccache krb5_fwd_ccache; 1267c478bd9Sstevel@tonic-gate krb5_principal krb5_user; 1277c478bd9Sstevel@tonic-gate char *krb5_ticket_file; 1287c478bd9Sstevel@tonic-gate #endif 1297c478bd9Sstevel@tonic-gate void *methoddata; 1307c478bd9Sstevel@tonic-gate #endif /* SUNW_SSH */ 1317c478bd9Sstevel@tonic-gate }; 1327c478bd9Sstevel@tonic-gate 1337c478bd9Sstevel@tonic-gate struct Authmethod { 1347c478bd9Sstevel@tonic-gate char *name; 1357c478bd9Sstevel@tonic-gate int *enabled; 1367c478bd9Sstevel@tonic-gate /* 1377c478bd9Sstevel@tonic-gate * Userauth method state tracking fields updated in 1387c478bd9Sstevel@tonic-gate * input_userauth_request() and auth-pam.c. 1397c478bd9Sstevel@tonic-gate * 1407c478bd9Sstevel@tonic-gate * The "void (*userauth)(Authctxt *authctxt)" function 1417c478bd9Sstevel@tonic-gate * communicates the userauth result (success, failure, 1427c478bd9Sstevel@tonic-gate * "postponed," abandoned) through the 'authenticated', 1437c478bd9Sstevel@tonic-gate * 'postponed' and 'abandoned' fields. Partial success is 1447c478bd9Sstevel@tonic-gate * indicated by requiring other userauths to be used by setting 1457c478bd9Sstevel@tonic-gate * their 'required' or 'sufficient' fields. 1467c478bd9Sstevel@tonic-gate * 1477c478bd9Sstevel@tonic-gate * Individual methods should only ever set 'not_again' if it 1487c478bd9Sstevel@tonic-gate * makes no sense to complete the same userauth more than once, 1497c478bd9Sstevel@tonic-gate * and they should set any methods' sufficient or required flags 1507c478bd9Sstevel@tonic-gate * in order to force partial authentication and require that 1517c478bd9Sstevel@tonic-gate * more userauths be tried. The (void *) 'method_data' and 1527c478bd9Sstevel@tonic-gate * 'hist_method_data' pointers can be used by methods such as 1537c478bd9Sstevel@tonic-gate * pubkey which may make sense to run more than once during 1547c478bd9Sstevel@tonic-gate * userauth or which may require multiple round tripes (e.g., 1557c478bd9Sstevel@tonic-gate * keyboard-interactive) and which need to keep some state; 1567c478bd9Sstevel@tonic-gate * 'hist_method_data' is there specifically for pubkey userauth 1577c478bd9Sstevel@tonic-gate * where multiple successful attempts should all use different 1587c478bd9Sstevel@tonic-gate * keys. 1597c478bd9Sstevel@tonic-gate * 1607c478bd9Sstevel@tonic-gate * The "attempts," "abandons," "successes" and "failures" fields 1617c478bd9Sstevel@tonic-gate * count the number of times a method has been attempted, 1627c478bd9Sstevel@tonic-gate * abandoned, and has succeeded or failed. Note that pubkey 1637c478bd9Sstevel@tonic-gate * userauth does not double-count sig-less probes that are 1647c478bd9Sstevel@tonic-gate * followed by a pubkey request for the same pubkey anw with a 1657c478bd9Sstevel@tonic-gate * signature. 1667c478bd9Sstevel@tonic-gate */ 1677c478bd9Sstevel@tonic-gate void (*userauth)(Authctxt *authctxt); 1687c478bd9Sstevel@tonic-gate void (*abandon)(Authctxt *, Authmethod *); 1697c478bd9Sstevel@tonic-gate void *method_data; 1707c478bd9Sstevel@tonic-gate void *hist_method_data; 1717c478bd9Sstevel@tonic-gate unsigned int is_initial; 1727c478bd9Sstevel@tonic-gate unsigned int attempts:8; 1737c478bd9Sstevel@tonic-gate unsigned int abandons:8; 1747c478bd9Sstevel@tonic-gate unsigned int successes:8; 1757c478bd9Sstevel@tonic-gate unsigned int failures:8; 1767c478bd9Sstevel@tonic-gate /* 1777c478bd9Sstevel@tonic-gate * Post-attempt state booleans (authenticated, abandoned, etc...) 1787c478bd9Sstevel@tonic-gate */ 1797c478bd9Sstevel@tonic-gate unsigned int authenticated:1; 1807c478bd9Sstevel@tonic-gate unsigned int not_again:1; 1817c478bd9Sstevel@tonic-gate unsigned int sufficient:1; 1827c478bd9Sstevel@tonic-gate unsigned int required:1; 1837c478bd9Sstevel@tonic-gate unsigned int postponed:1; 1847c478bd9Sstevel@tonic-gate unsigned int abandoned:1; 1857c478bd9Sstevel@tonic-gate /* 1867c478bd9Sstevel@tonic-gate * NOTE: multi-round-trip userauth methods can either 1877c478bd9Sstevel@tonic-gate * recursively call dispatch_run and detect abandonment 1887c478bd9Sstevel@tonic-gate * within their message handlers (as PAM kbd-int does) or 1897c478bd9Sstevel@tonic-gate * set the postponed flag and let input_userauth_request() 1907c478bd9Sstevel@tonic-gate * detect abandonment (i.e., initiation of some userauth 1917c478bd9Sstevel@tonic-gate * method before completion of a started, multi-round-trip 1927c478bd9Sstevel@tonic-gate * userauth method). 1937c478bd9Sstevel@tonic-gate * 1947c478bd9Sstevel@tonic-gate */ 1957c478bd9Sstevel@tonic-gate }; 1967c478bd9Sstevel@tonic-gate 1977c478bd9Sstevel@tonic-gate /* 1987c478bd9Sstevel@tonic-gate * Keyboard interactive device: 1997c478bd9Sstevel@tonic-gate * init_ctx returns: non NULL upon success 2007c478bd9Sstevel@tonic-gate * query returns: 0 - success, otherwise failure 2017c478bd9Sstevel@tonic-gate * respond returns: 0 - success, 1 - need further interaction, 2027c478bd9Sstevel@tonic-gate * otherwise - failure 2037c478bd9Sstevel@tonic-gate */ 2047c478bd9Sstevel@tonic-gate struct KbdintDevice 2057c478bd9Sstevel@tonic-gate { 2067c478bd9Sstevel@tonic-gate const char *name; 2077c478bd9Sstevel@tonic-gate void* (*init_ctx)(Authctxt*); 2087c478bd9Sstevel@tonic-gate int (*query)(void *ctx, char **name, char **infotxt, 2097c478bd9Sstevel@tonic-gate u_int *numprompts, char ***prompts, u_int **echo_on); 2107c478bd9Sstevel@tonic-gate int (*respond)(void *ctx, u_int numresp, char **responses); 2117c478bd9Sstevel@tonic-gate void (*free_ctx)(void *ctx); 2127c478bd9Sstevel@tonic-gate }; 2137c478bd9Sstevel@tonic-gate 2147c478bd9Sstevel@tonic-gate int auth_rhosts(struct passwd *, const char *); 2157c478bd9Sstevel@tonic-gate int 2167c478bd9Sstevel@tonic-gate auth_rhosts2(struct passwd *, const char *, const char *, const char *); 2177c478bd9Sstevel@tonic-gate 2187c478bd9Sstevel@tonic-gate int auth_rhosts_rsa(struct passwd *, char *, Key *); 2197c478bd9Sstevel@tonic-gate int auth_password(Authctxt *, const char *); 2207c478bd9Sstevel@tonic-gate int auth_rsa(struct passwd *, BIGNUM *); 2217c478bd9Sstevel@tonic-gate int auth_rsa_challenge_dialog(Key *); 2227c478bd9Sstevel@tonic-gate BIGNUM *auth_rsa_generate_challenge(Key *); 2237c478bd9Sstevel@tonic-gate int auth_rsa_verify_response(Key *, BIGNUM *, u_char[]); 2247c478bd9Sstevel@tonic-gate int auth_rsa_key_allowed(struct passwd *, BIGNUM *, Key **); 2257c478bd9Sstevel@tonic-gate 2267c478bd9Sstevel@tonic-gate int auth_rhosts_rsa_key_allowed(struct passwd *, char *, char *, Key *); 2277c478bd9Sstevel@tonic-gate int hostbased_key_allowed(struct passwd *, const char *, char *, Key *); 2287c478bd9Sstevel@tonic-gate int user_key_allowed(struct passwd *, Key *); 2297c478bd9Sstevel@tonic-gate 2307c478bd9Sstevel@tonic-gate #ifdef KRB4 2317c478bd9Sstevel@tonic-gate #include <krb.h> 2327c478bd9Sstevel@tonic-gate int auth_krb4(Authctxt *, KTEXT, char **, KTEXT); 2337c478bd9Sstevel@tonic-gate int auth_krb4_password(Authctxt *, const char *); 2347c478bd9Sstevel@tonic-gate void krb4_cleanup_proc(void *); 2357c478bd9Sstevel@tonic-gate 2367c478bd9Sstevel@tonic-gate #ifdef AFS 2377c478bd9Sstevel@tonic-gate #include <kafs.h> 2387c478bd9Sstevel@tonic-gate int auth_krb4_tgt(Authctxt *, const char *); 2397c478bd9Sstevel@tonic-gate int auth_afs_token(Authctxt *, const char *); 2407c478bd9Sstevel@tonic-gate #endif /* AFS */ 2417c478bd9Sstevel@tonic-gate 2427c478bd9Sstevel@tonic-gate #endif /* KRB4 */ 2437c478bd9Sstevel@tonic-gate 2447c478bd9Sstevel@tonic-gate #ifdef KRB5 2457c478bd9Sstevel@tonic-gate int auth_krb5(Authctxt *authctxt, krb5_data *auth, char **client, krb5_data *); 2467c478bd9Sstevel@tonic-gate int auth_krb5_tgt(Authctxt *authctxt, krb5_data *tgt); 2477c478bd9Sstevel@tonic-gate int auth_krb5_password(Authctxt *authctxt, const char *password); 2487c478bd9Sstevel@tonic-gate void krb5_cleanup_proc(void *authctxt); 2497c478bd9Sstevel@tonic-gate #endif /* KRB5 */ 2507c478bd9Sstevel@tonic-gate 2517c478bd9Sstevel@tonic-gate #include "auth-pam.h" 2527c478bd9Sstevel@tonic-gate #include "auth2-pam.h" 2537c478bd9Sstevel@tonic-gate 2547c478bd9Sstevel@tonic-gate Authctxt *do_authentication(void); 2557c478bd9Sstevel@tonic-gate Authctxt *do_authentication2(void); 2567c478bd9Sstevel@tonic-gate 2577c478bd9Sstevel@tonic-gate #ifdef HAVE_BSM 2587c478bd9Sstevel@tonic-gate void audit_failed_login_cleanup(void *); 2597c478bd9Sstevel@tonic-gate #endif /* HAVE_BSM */ 2607c478bd9Sstevel@tonic-gate 2617c478bd9Sstevel@tonic-gate int userauth_check_partial_failure(Authctxt *authctxt); 2627c478bd9Sstevel@tonic-gate void userauth_force_kbdint(void); 2637c478bd9Sstevel@tonic-gate 2647c478bd9Sstevel@tonic-gate Authctxt *authctxt_new(void); 2657c478bd9Sstevel@tonic-gate void auth_log(Authctxt *, int, char *, char *); 2667c478bd9Sstevel@tonic-gate void userauth_finish(Authctxt *, char *); 2677c478bd9Sstevel@tonic-gate void userauth_user_svc_change(Authctxt *authctxt, 2687c478bd9Sstevel@tonic-gate char *user, 2697c478bd9Sstevel@tonic-gate char *service); 2707c478bd9Sstevel@tonic-gate int auth_root_allowed(char *); 2717c478bd9Sstevel@tonic-gate 2727c478bd9Sstevel@tonic-gate char *auth2_read_banner(void); 2737c478bd9Sstevel@tonic-gate 2747c478bd9Sstevel@tonic-gate void privsep_challenge_enable(void); 2757c478bd9Sstevel@tonic-gate 2767c478bd9Sstevel@tonic-gate void auth2_challenge(Authctxt *, char *); 2777c478bd9Sstevel@tonic-gate void auth2_challenge_abandon(Authctxt *); 2787c478bd9Sstevel@tonic-gate int bsdauth_query(void *, char **, char **, u_int *, char ***, u_int **); 2797c478bd9Sstevel@tonic-gate int bsdauth_respond(void *, u_int, char **); 2807c478bd9Sstevel@tonic-gate int skey_query(void *, char **, char **, u_int *, char ***, u_int **); 2817c478bd9Sstevel@tonic-gate int skey_respond(void *, u_int, char **); 2827c478bd9Sstevel@tonic-gate 2837c478bd9Sstevel@tonic-gate struct passwd * getpwnamallow(const char *user); 2847c478bd9Sstevel@tonic-gate 285*d8a94255SErik Trauschke int run_auth_hook(const char *, const char *, const char *); 286*d8a94255SErik Trauschke 2877c478bd9Sstevel@tonic-gate char *get_challenge(Authctxt *); 2887c478bd9Sstevel@tonic-gate int verify_response(Authctxt *, const char *); 2897c478bd9Sstevel@tonic-gate 2907c478bd9Sstevel@tonic-gate struct passwd * auth_get_user(void); 2917c478bd9Sstevel@tonic-gate 2927c478bd9Sstevel@tonic-gate char *authorized_keys_file(struct passwd *); 2937c478bd9Sstevel@tonic-gate char *authorized_keys_file2(struct passwd *); 2947c478bd9Sstevel@tonic-gate 2957c478bd9Sstevel@tonic-gate int 2967c478bd9Sstevel@tonic-gate secure_filename(FILE *, const char *, struct passwd *, char *, size_t); 2977c478bd9Sstevel@tonic-gate 2987c478bd9Sstevel@tonic-gate HostStatus 2997c478bd9Sstevel@tonic-gate check_key_in_hostfiles(struct passwd *, Key *, const char *, 3007c478bd9Sstevel@tonic-gate const char *, const char *); 3017c478bd9Sstevel@tonic-gate 3027c478bd9Sstevel@tonic-gate /* hostkey handling */ 3037c478bd9Sstevel@tonic-gate #ifndef lint 3047c478bd9Sstevel@tonic-gate Key *get_hostkey_by_index(int); 3057c478bd9Sstevel@tonic-gate Key *get_hostkey_by_type(int); 3067c478bd9Sstevel@tonic-gate int get_hostkey_index(Key *); 3077c478bd9Sstevel@tonic-gate #endif /* lint */ 3087c478bd9Sstevel@tonic-gate int ssh1_session_key(BIGNUM *); 3097c478bd9Sstevel@tonic-gate 3107c478bd9Sstevel@tonic-gate /* debug messages during authentication */ 3117c478bd9Sstevel@tonic-gate void auth_debug_add(const char *fmt,...) __attribute__((format(printf, 1, 2))); 3127c478bd9Sstevel@tonic-gate void auth_debug_send(void); 3137c478bd9Sstevel@tonic-gate void auth_debug_reset(void); 3147c478bd9Sstevel@tonic-gate 3157c478bd9Sstevel@tonic-gate #define AUTH_FAIL_MAX 6 3167c478bd9Sstevel@tonic-gate #define AUTH_FAIL_LOG (AUTH_FAIL_MAX/2) 3177c478bd9Sstevel@tonic-gate #define AUTH_FAIL_MSG "Too many authentication failures for %.100s" 3187c478bd9Sstevel@tonic-gate 3197c478bd9Sstevel@tonic-gate #define SKEY_PROMPT "\nS/Key Password: " 3207c478bd9Sstevel@tonic-gate 3217c478bd9Sstevel@tonic-gate #ifdef __cplusplus 3227c478bd9Sstevel@tonic-gate } 3237c478bd9Sstevel@tonic-gate #endif 3247c478bd9Sstevel@tonic-gate 3257c478bd9Sstevel@tonic-gate #endif /* _AUTH_H */ 326