Access denied to /etc/pulse/client.conf.d/


#1

G’day,

I started having trouble with my package “hatari-emulator”. It used to work fine but recently audio output doesn’t work any more. It appears that access to /etc/pulse/client.conf.d/ is denied by the snap confinement:

$ sudo snappy-debug.security scanlog hatari-emulator
INFO: following '/var/log/syslog'. If have dropped messages, use:
INFO: $ sudo journalctl --output=short --follow --all | sudo snappy-debug.security scanlog
kernel.printk_ratelimit = 0
= AppArmor =
Time: Dec 15 12:10:02
Log: apparmor="DENIED" operation="open" profile="snap.hatari-emulator.hatari" name="/etc/pulse/client.conf.d/" pid=6436 comm="hatari" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
File: /etc/pulse/client.conf.d/ (read)
Suggestion:
* adjust program to read necessary files from $SNAP, $SNAP_DATA, $SNAP_COMMON, $SNAP_USER_DATA or $SNAP_USER_COMMON

NB: I do have the “pulseaudio” interface connected.

Any ideas?

Regards,
Jacob


#2

The pulseaudio interface has /etc/pulse/* r, but this doesn’t allow access to /etc/pulse/client.conf.d/.

What is the output of snap version? If you adjust /var/lib/snapd/apparmor/profiles/snap.hatari-emulator.hatari to change this line:

  /etc/pulse/* r,

to:

  /etc/pulse/** r,

Then run: sudo apparmor_parser -r /var/lib/snapd/apparmor/profiles/snap.hatari-emulator.hatari, does you application work again?


#3

Thanks @jdstrand, when I retried today the app’s audio started working again. I’m not aware of making any changes to anything and so I really don’t know what exactly was going on :-/


#4

Interesting. I will still fix the denial in the next batch of policy updates. Please report back if/when you figure it out.