summaryrefslogtreecommitdiff
path: root/bus/services.c
diff options
context:
space:
mode:
Diffstat (limited to 'bus/services.c')
-rw-r--r--bus/services.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/bus/services.c b/bus/services.c
index 584485b1..8e625867 100644
--- a/bus/services.c
+++ b/bus/services.c
@@ -36,6 +36,7 @@
#include "policy.h"
#include "bus.h"
#include "selinux.h"
+#include "apparmor.h"
struct BusService
{
@@ -458,6 +459,12 @@ bus_registry_acquire_service (BusRegistry *registry,
_dbus_string_get_const_data (service_name));
goto out;
}
+
+ if (!bus_apparmor_allows_acquire_service (connection,
+ (registry->context ?
+ bus_context_get_type (registry->context) : NULL),
+ _dbus_string_get_const_data (service_name), error))
+ goto out;
if (!bus_client_policy_check_can_own (policy, service_name))
{