From: Sergey Kitov Date: Tue, 15 Aug 2017 08:09:07 +0000 (+0300) Subject: auth: auth_request_log_unknown_user() to call common auth_request_log_login_failure() X-Git-Tag: 2.3.0.rc1~1164 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bd18d17a3da7c96a027d784183e9a98b1b666bad;p=thirdparty%2Fdovecot%2Fcore.git auth: auth_request_log_unknown_user() to call common auth_request_log_login_failure() Separate implementation of auth_request_log_unknown_user() is replaced with call to auth_request_log_login_failure() NOTE: behavior of the auth_request_log_unknown_user() is changed and is in line with auth_request_log_password_mismatch() --- diff --git a/src/auth/auth-request.c b/src/auth/auth-request.c index 12cfc6be40..cd014f6a7c 100644 --- a/src/auth/auth-request.c +++ b/src/auth/auth-request.c @@ -2449,27 +2449,7 @@ void auth_request_log_password_mismatch(struct auth_request *request, void auth_request_log_unknown_user(struct auth_request *request, const char *subsystem) { - string_t *str; - - if (strcmp(request->set->verbose_passwords, "no") == 0 || - !request->set->verbose) { - auth_request_log_info(request, subsystem, "unknown user"); - return; - } - str = t_str_new(128); - get_log_prefix(str, request, subsystem); - str_append(str, "unknown user "); - - auth_request_append_password(request, str); - - if (request->userdb_lookup) { - if (request->userdb->next != NULL) - str_append(str, " - trying the next userdb"); - } else { - if (request->passdb->next != NULL) - str_append(str, " - trying the next passdb"); - } - i_info("%s", str_c(str)); + auth_request_log_login_failure(request, subsystem, "unknown user"); } void auth_request_log_login_failure(struct auth_request *request,