summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
authorSumit Bose <sbose@redhat.com>2017-09-18 15:00:53 +0200
committerLukas Slebodnik <lslebodn@redhat.com>2017-09-22 14:46:21 +0200
commit1f331476e7d33bb03cc35a2a9064ee1cc5bed6cf (patch)
tree600d292073011087eca87397f421f2f2ce7ea9e6 /Makefile.am
parent11a030ac6e064c50759b5397e1f4d0289f87f64a (diff)
downloadsssd-1f331476e7d33bb03cc35a2a9064ee1cc5bed6cf.tar.gz
sssd-1f331476e7d33bb03cc35a2a9064ee1cc5bed6cf.tar.xz
sssd-1f331476e7d33bb03cc35a2a9064ee1cc5bed6cf.zip
sssd_client: add mutex protected call to the PAC responder
SSSD's plugin for MIT Kerberos to send the PAC to the PAC responder currently uses sss_pac_make_request() which does not protect the communication with the PAC responder with a mutex as e.g. the NSS and PAM clients. If an application using threads loads this plugin via libkrb5 in different threads and is heavily processing Kerberos tickets with PACs chances are that two threads try to communicate with SSSD at once. In this case one of the threads will miss a reply and will wait for it until the default client timeout of 300s is passed. This patch adds a call which uses a mutex to protect the communication which will avoid the 300s delay mentioned above. Resolves: https://pagure.io/SSSD/sssd/issue/3518 Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> Reviewed-by: Fabiano Fidêncio <fidencio@redhat.com>
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am16
1 files changed, 16 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am
index f1f467100..c0586d7ec 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -3523,6 +3523,9 @@ endif
if BUILD_WITH_LIBCURL
noinst_PROGRAMS += tcurl-test-tool
endif
+if BUILD_PAC_RESPONDER
+ noinst_PROGRAMS += sssd_pac_test_client
+endif
if BUILD_AUTOFS
autofs_test_client_SOURCES = \
@@ -4257,6 +4260,19 @@ sssd_pac_plugin_la_LDFLAGS = \
-avoid-version \
-module
+sssd_pac_test_client_SOURCES = \
+ src/sss_client/sss_pac_responder_client.c \
+ src/sss_client/common.c \
+ src/util/strtonum.c \
+ $(NULL)
+sssd_pac_test_client_CFLAGS = \
+ $(AM_CFLAGS) \
+ $(NULL)
+sssd_pac_test_client_LDADD = \
+ $(CLIENT_LIBS) \
+ -lpthread \
+ $(NULL)
+
# python[23] bindings
pysss_la_SOURCES = \
$(SSSD_TOOLS_OBJ) \