# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2023-2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only

  dbus receive bus=system path=/
       interface=org.freedesktop.DBus.ObjectManager
       member=InterfacesRemoved
       peer=(name="{:*,org.bluez}", label=bluetoothd),

  dbus receive bus=system path=/org/bluez/hci@{int}{,/**}
       interface=org.freedesktop.DBus.Properties
       member=PropertiesChanged
       peer=(name="{:*,org.bluez}", label=bluetoothd),

  dbus send bus=system path=/
       interface=org.freedesktop.DBus.ObjectManager
       member=GetManagedObjects
       peer=(name="{:*,org.bluez}", label=bluetoothd),

  dbus send bus=system path=/org/bluez
       interface=org.bluez.AgentManager@{int}
       member={RegisterAgent,RequestDefaultAgent,UnregisterAgent}
       peer=(name=org.bluez, label=bluetoothd),

  dbus send bus=system path=/org/bluez
       interface=org.bluez.ProfileManager@{int}
       member=RegisterProfile
       peer=(name=org.bluez, label=bluetoothd),

  dbus send bus=system path=/org/bluez/hci@{int}
       interface=org.freedesktop.DBus.Properties
       member=Set
       peer=(name="{:*,org.bluez}", label=bluetoothd),

  dbus send bus=system path=/org/bluez/hci@{int}
       interface=org.bluez.BatteryProviderManager@{int}
       member=RegisterProfile
       peer=(name=org.bluez, label=bluetoothd),

  dbus send bus=system path=/org/bluez/hci@{int}
       interface=org.bluez.Media@{int}
       member=RegisterApplication
       peer=(name=org.bluez, label=bluetoothd),

  include if exists <abstractions/bus/org.bluez.d>

# vim:syntax=apparmor
