diff options
author | Damien Miller <djm@mindrot.org> | 2000-09-16 16:25:12 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2000-09-16 16:25:12 +1100 |
commit | b70b61f5fecf37d95e031414849745030fa8a420 (patch) | |
tree | 33a92aca5fde66bde1c3bb3cdabfc5a4c27e24ab /auth2.c | |
parent | 52cbcbf0bb5ee685f77449f68c59926320bfe85f (diff) |
- (djm) Update CygWin support from Corinna Vinschen <vinschen@cygnus.com>
Diffstat (limited to 'auth2.c')
-rw-r--r-- | auth2.c | 13 |
1 files changed, 11 insertions, 2 deletions
@@ -182,6 +182,15 @@ input_userauth_request(int type, int plen) authenticated = ssh2_auth_pubkey(pw, service); } } + +#ifdef HAVE_CYGWIN + if (authenticated && !check_nt_auth(strcmp(method, "password") == 0, pw->pw_uid)) { + packet_disconnect("Authentication rejected for uid %d.", + (int) pw->pw_uid); + authenticated = 0; + } +#endif + if (authenticated && pw && pw->pw_uid == 0 && !options.permit_root_login) { authenticated = 0; log("ROOT LOGIN REFUSED FROM %.200s", @@ -189,8 +198,8 @@ input_userauth_request(int type, int plen) } #ifdef USE_PAM - if (authenticated && !do_pam_account(pw->pw_name, NULL)) - authenticated = 0; + if (authenticated && !do_pam_account(pw->pw_name, NULL)) + authenticated = 0; #endif /* USE_PAM */ /* Raise logging level */ |