[PATCHSET RFC v5 8/8] fuse: run fuse servers as a contained service

Darrick J. Wong
2025-09-16T00:20:08Z

Hi all,

This patchset defines the necessary communication protocols and library
code so that users can mount fuse servers that run in unprivileged
systemd service containers. That in turn allows unprivileged untrusted
mounts, because the worst that can happen is that a malicious image
crashes the fuse server and the mount dies, instead of corrupting the
kernel. As part of the delegation, add a new ioctl allowing any process
with an open fusedev fd to ask for permission for anyone with that
fusedev fd to use iomap.

If you're going to start using this code, I strongly recommend pulling
from my git trees, which are linked below.

This has been running on the djcloud for months with no problems. Enjoy!
Comments and questions are, as always, welcome.

--D

kernel git tree:
https://git.kernel.org/cgit/linux/kernel/git/djwong/xfs-linux.git/log/?h=fuse-service-container
---
Commits in this patchset:
* fuse: allow privileged mount helpers to pre-approve iomap usage
* fuse: set iomap backing device block size
---
fs/fuse/fuse_dev_i.h | 32 +++++++++++++++++++--
fs/fuse/fuse_i.h | 12 ++++++++
include/uapi/linux/fuse.h | 8 +++++
fs/fuse/dev.c | 13 +++++----
fs/fuse/file_iomap.c | 67 ++++++++++++++++++++++++++++++++++++++++++++-
fs/fuse/inode.c | 18 ++++++++----
6 files changed, 134 insertions(+), 16 deletions(-)