bubblewrap icon indicating copy to clipboard operation
bubblewrap copied to clipboard

PR_SET_DUMPABLE

Open maklor78 opened this issue 5 years ago • 2 comments

In some sandboxed applications like the example code in libseccomp the PR_SET_DUMPABLE is set to 0 to prevent escape via ptrace

However here https://github.com/containers/bubblewrap/blob/1f7e2ad948c051054b683461885a0215f1806240/bubblewrap.c#L852 bubblewrap is set as traceable instead.

Why is this? If I am not mistaken, this recent issue https://github.com/containers/bubblewrap/security/advisories/GHSA-j2qp-rvxj-43vj would have been prevented if this value was set to 0 instead.

maklor78 avatar Apr 19 '20 23:04 maklor78

Its done once we no longer need any privileges, because doing so opens up to access to various files in /proc to access by your uid which some things (like. e..g flatpak) relies on.

alexlarsson avatar Apr 20 '20 06:04 alexlarsson

I guess if we wanted to we could make this optional as its not always needed.

alexlarsson avatar Apr 20 '20 06:04 alexlarsson