summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2014-05-09 20:03:02 +0200
committerJakub Hrozek <jhrozek@redhat.com>2014-05-13 21:46:46 +0200
commit0161a3c5637a0c0092bf54c436bb3d6508d7df26 (patch)
tree5d057559f2b8345608a422e1f544c446ba420b52 /Makefile.am
parentb81ad4a7c59cade13d52216f805d904392627136 (diff)
downloadsssd-0161a3c5637a0c0092bf54c436bb3d6508d7df26.tar.gz
sssd-0161a3c5637a0c0092bf54c436bb3d6508d7df26.tar.xz
sssd-0161a3c5637a0c0092bf54c436bb3d6508d7df26.zip
SBUS: Add an async request to retrieve the caller ID
Adds an async request sbus_get_sender_id_{send,recv} that allows retrieval of UID based on "sender" as returned by dbus_message_get_sender(). The UID is an int64_t to be able to use "-1" to as a fallback value for uknown or error cases. The unit test is added as a standalone one, not part of the sbus_tests because the request, and by extension the unit test relies on being connected to the system bus, which is very unlikely to work in a build system. Reviewed-by: Pavel Březina <pbrezina@redhat.com> Reviewed-by: Stef Walter <stefw@redhat.com>
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am22
1 files changed, 22 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am
index 4f9c11f47..d3a6b5c2f 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -175,6 +175,7 @@ if HAVE_CMOCKA
ad_common_tests \
dp_opt_tests \
responder-get-domains-tests \
+ sbus-internal-tests \
test_search_bases
endif
@@ -1465,6 +1466,27 @@ responder_get_domains_tests_LDADD = \
$(SSSD_INTERNAL_LTLIBS) \
libsss_test_common.la
+sbus_internal_tests_SOURCES = \
+ src/tests/cmocka/sbus_internal_tests.c \
+ src/sbus/sssd_dbus_request.c
+sbus_internal_tests_CFLAGS = \
+ $(AM_CFLAGS)
+sbus_internal_tests_LDFLAGS = \
+ -Wl,-wrap,dbus_bus_get \
+ -Wl,-wrap,dbus_pending_call_steal_reply \
+ -Wl,-wrap,dbus_pending_call_unref \
+ -Wl,-wrap,dbus_message_unref \
+ -Wl,-wrap,dbus_connection_unref \
+ -Wl,-wrap,dbus_connection_set_exit_on_disconnect \
+ -Wl,-wrap,hash_lookup
+sbus_internal_tests_LDADD = \
+ $(CMOCKA_LIBS) \
+ $(SSSD_LIBS) \
+ libsss_util.la \
+ libsss_crypt.la \
+ libsss_debug.la \
+ libsss_test_common.la
+
test_find_uid_SOURCES = \
src/tests/cmocka/test_find_uid.c \
src/util/find_uid.c \