OpenGL interface should udev tag all /dev/fb* files
Bug #1675738 reported by
Ara Pulido
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
snapd |
Fix Released
|
High
|
Gary.Wang |
Bug Description
This problem only happens when using this interface and the framebuffer interface in the same snap.
The framebuffer interface udev tags the /dev/fb* devices which causes snap-confine to create a device cgroup and add /dev/fb* to it. The problem comes in because the opengl interface does not currently udev tag any of the devices in /dev, so when the snap is run (or you use 'snap run --shell <snap>) the accessed /dev/* device is not added to the per-snap device cgroup and access is denied.
The OpenGL interface should be made to have all /dev/* files udev tagged just like the framebuffer interface udev tags /dev/fb*.
summary: |
- OpenGL interface should udev tag all /dev/* files + OpenGL interface should udev tag all /dev/fb* files |
Changed in snapd: | |
status: | Triaged → In Progress |
Changed in snapd: | |
assignee: | nobody → Gary.Wang (gary-wzl77) |
To post a comment you must log in.
Here's a list of existing snapd interfaces that all use device nodes but no udev tagging yet:
alsa: /dev/snd/* module- control: /dev/mem 0-9]{,[ 0-9]*}, /dev/tap[ 0-9]{,[ 0-9]*} usb/[0- 9][0-9] [0-9]/[ 0-9][0- 9][0-9]
bluez - /dev/rfkill
bluetooth-control - /dev/vhci
camera - /dev/video[0-9]*
fuse-support - /dev/fuse
kernel-
mir - /dev/input/* and /dev/tty[0-9]* (note, /dev/tty is added unconditionally to the cgroup, so this is for tty#)
modem-manager - /dev/tty[^0-9]* (ie, *not* /dev/tty#, but instead /dev/ttyUSB, etc, etc) and /dev/cdc-*
(modem-manager has udev rules, but not ones that udev tag the devices to the snap)
network-control: /dev/rfkill, /dev/net/tun, /dev/tun[
network-manager: /dev/rfkill
ofono: /dev/tty[^0-9]*, /dev/cdc-*, /dev/modem*, /dev/dsp, /dev/chnlat11, /dev/socket/rild* (if this is a unix socket, may not be needed), /dev/net/tun
opengl - /dev/dri/card*, /dev/nvidia*, /dev/vchiq
optical-drive: /dev/sr[0-9]*, /dev/scd[0-9]*
ppp - /dev/ppp, /dev/tty[^0-9]*
pulseaudio - /dev/snd/pcm*, /dev/snd/control*, /dev/snd/timer
raw-usb: /dev/bus/
tpm - /dev/tpm0
udisks2 - /dev/sd*, /dev/mmcblk*
Here's a list of interfaces that access device nodes that already use udev tagging:
framebuffer, uhid, serial-port, i2c, time-control, physical- memory- observe, physical- memory- control, io-ports-control, iio, hidraw
So any snap that plugs one of the interfaces from the first list *and* one of the interfaces from the second list is currently broken, so all interfaces in the first list need to be updated to use udev tagging