don't consider a partial success as a failure

This commit is contained in:
Petr Lautrbach 2014-09-04 16:33:25 +02:00
parent 163064841f
commit ce2d80b4e7
2 changed files with 20 additions and 0 deletions

View File

@ -0,0 +1,16 @@
diff --git a/auth2.c b/auth2.c
index d9b440a..ec0bf12 100644
--- a/auth2.c
+++ b/auth2.c
@@ -355,8 +355,9 @@ userauth_finish(Authctxt *authctxt, int authenticated, const char *method,
authctxt->success = 1;
} else {
- /* Allow initial try of "none" auth without failure penalty */
- if (!authctxt->server_caused_failure &&
+ /* Allow initial try of "none" auth without failure penalty
+ * Partial succes is not failure */
+ if (!authctxt->server_caused_failure && !partial &&
(authctxt->attempt > 1 || strcmp(method, "none") != 0))
authctxt->failures++;
if (authctxt->failures >= options.max_authtries) {

View File

@ -198,6 +198,9 @@ Patch911: openssh-6.6p1-set_remote_ipaddr.patch
# https://bugzilla.mindrot.org/show_bug.cgi?id=2058 # https://bugzilla.mindrot.org/show_bug.cgi?id=2058
# slightly changed patch from comment 10 # slightly changed patch from comment 10
Patch912: openssh-6.6.1p1-utf8-banner.patch Patch912: openssh-6.6.1p1-utf8-banner.patch
# don't consider a partial success as a failure
# https://bugzilla.mindrot.org/show_bug.cgi?id=2270
Patch913: openssh-6.6.1p1-partial-success.patch
License: BSD License: BSD
@ -405,6 +408,7 @@ popd
%patch910 -p1 -b .NI_MAXHOST %patch910 -p1 -b .NI_MAXHOST
%patch911 -p1 -b .set_remote_ipaddr %patch911 -p1 -b .set_remote_ipaddr
%patch912 -p1 -b .utf8-banner %patch912 -p1 -b .utf8-banner
%patch913 -p1 -b .partial-success
%patch200 -p1 -b .audit %patch200 -p1 -b .audit
%patch700 -p1 -b .fips %patch700 -p1 -b .fips