All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vivek Goyal <vgoyal@redhat.com>
To: P J P <ppandit@redhat.com>
Cc: virtio-fs@redhat.com
Subject: Re: [Virtio-fs] [RFC] About non-root virtiofsd(1) process
Date: Tue, 16 Feb 2021 09:36:35 -0500	[thread overview]
Message-ID: <20210216143635.GA3196@redhat.com> (raw)
In-Reply-To: <9qo964n3-7p75-7992-7s7p-3srrs4q650n@erqung.pbz>

On Tue, Jan 19, 2021 at 08:04:29PM +0530, P J P wrote:
> +-- On Mon, 18 Jan 2021, Stefan Hajnoczi wrote --+
> | Guest applications may run with different uids/gids. The host has no control 
> | over that.
> | 
> | Imagine booting a guest form a virtio-fs root file system and installing 
> | packages. The guest must be able to control uids/gids for that to work.
> 
> * I see; I'll try to better understand how it's done.
> 
> * With UID namespaces, I thought virtiofsd(1) would be able to operate files 
>   with arbitrary uid/gid, even after dropping its root privileges to acquire 
>   non-root privileges on the host; Because it has 'root' privileges under the 
>   shared directory & UID namespace.
> 
> | > $ ./virtiofsd -runas test -o source=...
> | 
> | Patches for this are welcome.
> 
> * Okay, will try.

Catching up with this thread now.

I had posted minimal patches to allow running virtiofsd unpriviliged.
They did not make further progress though.

https://patchew.org/QEMU/20200730194736.173994-1-vgoyal@redhat.com/

While being able to run virtiofsd in a user namespace is certainly
valuable, I feel being able to run virtiofsd unpriviliged has it
use cases as well. For example, if a user wants to share just its
home directory on host with guest. In that case, we probably don't
require lot of priviliged operations to be performed by virtiofsd.

Vivek


      parent reply	other threads:[~2021-02-16 14:36 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-14  8:41 [Virtio-fs] [RFC] About non-root virtiofsd(1) process P J P
2021-01-14 10:08 ` Dr. David Alan Gilbert
2021-01-14 13:10   ` P J P
2021-01-14 13:34 ` Stefan Hajnoczi
2021-01-15  7:09   ` P J P
2021-01-18 16:55     ` Stefan Hajnoczi
2021-01-19 14:34       ` P J P
2021-01-20  5:49         ` Chirantan Ekbote
2021-01-20 16:21           ` Stefan Hajnoczi
2021-02-16 14:39           ` Vivek Goyal
2021-01-20 16:20         ` Stefan Hajnoczi
2021-02-16 14:36         ` Vivek Goyal [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210216143635.GA3196@redhat.com \
    --to=vgoyal@redhat.com \
    --cc=ppandit@redhat.com \
    --cc=virtio-fs@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.