Rootless podman run --privileged
fails if there is an inaccessible /dev
subdirectory
#3919
Labels
kind/bug
Categorizes issue or PR as related to a bug.
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
/kind bug
Description
Current implementation of privileged containers uses
libcontainer
'sHostDevices()
function to obtain the list of host devices. This function returns any error arising when accessing the subdirectories in/dev
. This means, that having some inaccessible (by current user) subdirectory in/dev
makes rootlesspodman run --privileged
crash, e.g.:Dir permissions are:
Steps to reproduce the issue:
/dev
which is not accessible to ordinary users:sudo mkdir -m 0700 /dev/kaboom
podman run --privileged alpine
Describe the results you received:
podman
crashes with thepermission denied
error.Describe the results you expected:
Inaccessible directory is ignored.
The text was updated successfully, but these errors were encountered: