|
cvsdist |
ffdec5 |
Skip the initial empty-password check if permit_empty_passwd is disabled. This
|
|
cvsdist |
ffdec5 |
doesn't change the timing profiles of the host because the additional condition
|
|
cvsdist |
ffdec5 |
check which can short-circuit the call to pam_authenticate() has no dependency
|
|
cvsdist |
ffdec5 |
on the identity of the user who is being authenticated.
|
|
Tomáš Mráz |
09510a |
diff -up openssh-5.1p1/auth1.c.skip-initial openssh-5.1p1/auth1.c
|
|
Tomáš Mráz |
09510a |
--- openssh-5.1p1/auth1.c.skip-initial 2008-07-09 12:54:05.000000000 +0200
|
|
Tomáš Mráz |
09510a |
+++ openssh-5.1p1/auth1.c 2008-07-23 18:26:01.000000000 +0200
|
|
Tomáš Mráz |
09510a |
@@ -244,7 +244,7 @@ do_authloop(Authctxt *authctxt)
|
|
Tomáš Mráz |
09510a |
authctxt->valid ? "" : "invalid user ", authctxt->user);
|
|
cvsdist |
ffdec5 |
|
|
cvsdist |
ffdec5 |
/* If the user has no password, accept authentication immediately. */
|
|
cvsdist |
ffdec5 |
- if (options.password_authentication &&
|
|
cvsdist |
ffdec5 |
+ if (options.permit_empty_passwd && options.password_authentication &&
|
|
cvsdist |
ffdec5 |
#ifdef KRB5
|
|
cvsdist |
ffdec5 |
(!options.kerberos_authentication || options.kerberos_or_local_passwd) &&
|
|
cvsdist |
ffdec5 |
#endif
|
|
Tomáš Mráz |
09510a |
diff -up openssh-5.1p1/auth2-none.c.skip-initial openssh-5.1p1/auth2-none.c
|
|
Tomáš Mráz |
09510a |
--- openssh-5.1p1/auth2-none.c.skip-initial 2008-07-02 14:56:09.000000000 +0200
|
|
Tomáš Mráz |
09510a |
+++ openssh-5.1p1/auth2-none.c 2008-07-23 18:26:01.000000000 +0200
|
|
Tomáš Mráz |
09510a |
@@ -65,7 +65,7 @@ userauth_none(Authctxt *authctxt)
|
|
cvsdist |
ffdec5 |
if (check_nt_auth(1, authctxt->pw) == 0)
|
|
Tomáš Mráz |
09510a |
return (0);
|
|
cvsdist |
ffdec5 |
#endif
|
|
cvsdist |
ffdec5 |
- if (options.password_authentication)
|
|
cvsdist |
ffdec5 |
+ if (options.permit_empty_passwd && options.password_authentication)
|
|
cvsdist |
ffdec5 |
return (PRIVSEP(auth_password(authctxt, "")));
|
|
cvsdist |
ffdec5 |
return (0);
|
|
cvsdist |
ffdec5 |
}
|