Blame SOURCES/0192-libwbclient-Change-return-code-for-wbcAuthenticateUs.patch

5ad689
From b9a2edea74ea04a09301f91fffb6835df72d8760 Mon Sep 17 00:00:00 2001
5ad689
From: Lukas Slebodnik <lslebodn@redhat.com>
5ad689
Date: Tue, 22 Aug 2017 13:09:18 +0200
5ad689
Subject: [PATCH 192/192] libwbclient: Change return code for
5ad689
 wbcAuthenticateUserEx
5ad689
5ad689
Samba-4.6 change behaviour of few functions
5ad689
New version of code make sure session info for user is stored in cache.
5ad689
It is a performance optimisation to prevent contacting KDC for each
5ad689
session. More details in samba bug
5ad689
https://bugzilla.samba.org/show_bug.cgi?id=11259
5ad689
5ad689
Old return code WBC_SSSD_NOT_IMPLEMENTED was translated
5ad689
to NT_STATUS_LOGON_FAILURE which caused many failures.
5ad689
5ad689
    [2017/08/21 11:34:15.044321,  5, pid=27742, effective(0, 0), real(0, 0)]
5ad689
    ../libcli/security/security_token.c:53(security_token_debug)
5ad689
      Security token: (NULL)
5ad689
    [2017/08/21 11:34:15.044330,  5, pid=27742, effective(0, 0), real(0, 0)]
5ad689
    ../source3/auth/token_util.c:640(debug_unix_user_token)
5ad689
      UNIX token of user 0
5ad689
      Primary group is 0 and contains 0 supplementary groups
5ad689
    [2017/08/21 11:34:15.044349,  4, pid=27742, effective(0, 0), real(0, 0)]
5ad689
    ../source3/smbd/sec_ctx.c:439(pop_sec_ctx)
5ad689
      pop_sec_ctx (0, 0) - sec_ctx_stack_ndx = 0
5ad689
    [2017/08/21 11:34:15.044360,  1, pid=27742, effective(0, 0), real(0, 0)]
5ad689
    ../source3/smbd/sesssetup.c:290(reply_sesssetup_and_X_spnego)
5ad689
      Failed to generate session_info (user and group token) for session
5ad689
    setup: NT_STATUS_LOGON_FAILURE
5ad689
5ad689
Resolves:
5ad689
https://pagure.io/SSSD/sssd/issue/3461
5ad689
5ad689
Reviewed-by: Sumit Bose <sbose@redhat.com>
5ad689
(cherry picked from commit 725d04cd21016dc6092a9f03cd363bb83d7c054c)
5ad689
(cherry picked from commit aede6a1f4412f133e4b3fd76944f764d76fc4868)
5ad689
(cherry picked from commit 260062d946e7cc265e2671f88b1662276431c0bb)
5ad689
---
5ad689
 src/sss_client/libwbclient/wbc_pam_sssd.c | 2 +-
5ad689
 1 file changed, 1 insertion(+), 1 deletion(-)
5ad689
5ad689
diff --git a/src/sss_client/libwbclient/wbc_pam_sssd.c b/src/sss_client/libwbclient/wbc_pam_sssd.c
5ad689
index 174cf1310fad0243036fe591978cc89700903896..77698f523e6e7aeb37d4db50b469d1604d7ee595 100644
5ad689
--- a/src/sss_client/libwbclient/wbc_pam_sssd.c
5ad689
+++ b/src/sss_client/libwbclient/wbc_pam_sssd.c
5ad689
@@ -49,7 +49,7 @@ wbcErr wbcAuthenticateUserEx(const struct wbcAuthUserParams *params,
5ad689
         *error = NULL;
5ad689
     }
5ad689
 
5ad689
-    WBC_SSSD_NOT_IMPLEMENTED;
5ad689
+    return WBC_ERR_WINBIND_NOT_AVAILABLE;
5ad689
 }
5ad689
 
5ad689
 /* Trigger a verification of the trust credentials of a specific domain */
5ad689
-- 
5ad689
2.9.4
5ad689