PANotConnected: Connection to PulseAudio daemon not established
Tanu Kaskinen
tanuk at iki.fi
Thu Feb 23 05:03:00 PST 2012
On Thu, 2012-02-23 at 11:21 +0100, Fabrice DELENTE wrote:
> Hello.
>
> I'm trying to build and use blueman from scratch.
>
> When trying to connect to a bluetooth headset, I get errors taht seem
> to be due to D-Bus permission trouble, since these errors don't show
> up when I am connected as root:
>
> _________
> set_nap (/usr/lib/python2.7/site-packages/blueman/plugins/applet/Networking.py:80)
> set nap False
> ERROR:dbus.proxies:Introspect error on org.bluez:/: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 2 matched rules; type="method_call", sender=":1.81" (uid=1000 pid=29710 comm="/usr/bin/python) interface="org.freedesktop.DBus.Introspectable" member="Introspect" error name="(unset)" requested_reply=0 destination="org.bluez" (uid=0 pid=1920 comm="/usr/sbin/bluetoothd))
> _________
> Run (/usr/lib/python2.7/site-packages/blueman/main/PluginManager.py:216)
> Function on_manager_state_changed on Networking Failed
> Traceback (most recent call last):
> File "/usr/lib/python2.7/site-packages/blueman/main/PluginManager.py", line 220, in Run
> ret = getattr(inst, function)(*args, **kwargs)
> File "/usr/lib/python2.7/site-packages/blueman/plugins/applet/Networking.py", line 45, in on_manager_state_changed
> self.update_status()
> File "/usr/lib/python2.7/site-packages/blueman/plugins/applet/Networking.py", line 69, in update_status
> self.set_nap(self.Config.props.nap_enable or False)
> File "/usr/lib/python2.7/site-packages/blueman/plugins/applet/Networking.py", line 83, in set_nap
> adapters = self.Applet.Manager.ListAdapters()
> File "/usr/lib/python2.7/site-packages/blueman/bluez/utils.py", line 28, in warp
> raise errors.parse_dbus_error(exception)
> DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 2 matched rules; type="method_call", sender=":1.81" (uid=1000 pid=29710 comm="/usr/bin/python) interface="org.bluez.Manager" member="ListAdapters" error name="(unset)" requested_reply=0 destination="org.bluez" (uid=0 pid=1920 comm="/usr/sbin/bluetoothd))
> _________
> update_menuitems (/usr/lib/python2.7/site-packages/blueman/plugins/applet/DiscvManager.py:132)
> warning: Adapter is None
> _________
> Run (/usr/lib/python2.7/site-packages/blueman/main/PluginManager.py:216)
> Function on_manager_state_changed on AuthAgent Failed
> Traceback (most recent call last):
> File "/usr/lib/python2.7/site-packages/blueman/main/PluginManager.py", line 220, in Run
> ret = getattr(inst, function)(*args, **kwargs)
> File "/usr/lib/python2.7/site-packages/blueman/plugins/applet/AuthAgent.py", line 49, in on_manager_state_changed
> adapters = self.Applet.Manager.ListAdapters()
> File "/usr/lib/python2.7/site-packages/blueman/bluez/utils.py", line 28, in warp
> raise errors.parse_dbus_error(exception)
> DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 2 matched rules; type="method_call", sender=":1.81" (uid=1000 pid=29710 comm="/usr/bin/python) interface="org.bluez.Manager" member="ListAdapters" error name="(unset)" requested_reply=0 destination="org.bluez" (uid=0 pid=1920 comm="/usr/sbin/bluetoothd))
> _________
> Run (/usr/lib/python2.7/site-packages/blueman/main/PluginManager.py:216)
> Function on_manager_state_changed on RecentConns Failed
> Traceback (most recent call last):
> File "/usr/lib/python2.7/site-packages/blueman/main/PluginManager.py", line 220, in Run
> ret = getattr(inst, function)(*args, **kwargs)
> File "/usr/lib/python2.7/site-packages/blueman/plugins/applet/RecentConns.py", line 195, in on_manager_state_changed
> adapters = self.Applet.Manager.ListAdapters()
> File "/usr/lib/python2.7/site-packages/blueman/bluez/utils.py", line 28, in warp
> raise errors.parse_dbus_error(exception)
> DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 2 matched rules; type="method_call", sender=":1.81" (uid=1000 pid=29710 comm="/usr/bin/python) interface="org.bluez.Manager" member="ListAdapters" error name="(unset)" requested_reply=0 destination="org.bluez" (uid=0 pid=1920 comm="/usr/sbin/bluetoothd))
> Traceback (most recent call last):
> File "/usr/lib/python2.7/site-packages/blueman/plugins/applet/ShowConnected.py", line 66, in enumerate_connections
> adapters = self.Applet.Manager.ListAdapters()
> File "/usr/lib/python2.7/site-packages/blueman/bluez/utils.py", line 28, in warp
> raise errors.parse_dbus_error(exception)
> dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 2 matched rules; type="method_call", sender=":1.81" (uid=1000 pid=29710 comm="/usr/bin/python) interface="org.bluez.Manager" member="ListAdapters" error name="(unset)" requested_reply=0 destination="org.bluez" (uid=0 pid=1920 comm="/usr/sbin/bluetoothd))
> _________
>
How is the mail subject related to these errors? I don't see anything
Pulseaudio related here.
> How can I set permissions in D-Bus? Thanks!
Services that use the system bus (bluetoothd is one of them) install
configuration files under /etc/dbus-1/system.d/ that describe who are
allowed to communicate with the service. Bluetoothd seems to have its
configuration in /etc/dbus-1/system.d/bluetooth.conf. These policies are
enforced by the D-Bus daemon. The service is free to implement further
restrictions itself. Those restrictions are configured in a
service-specific way. I don't know bluetoothd well, so I don't know if
it implements any access control beyond
the /etc/dbus-1/system.d/bluetooth.conf file.
--
Tanu
More information about the dbus
mailing list