All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: mszeredi@redhat.com, slp@redhat.com, qemu-devel@nongnu.org,
	"Dr. David Alan Gilbert" <dgilbert@redhat.com>,
	virtio-fs@redhat.com, Alex Xu <alex@alxu.ca>,
	P J P <ppandit@redhat.com>, Laszlo Ersek <lersek@redhat.com>,
	vgoyal@redhat.com
Subject: Re: [PATCH v2] virtiofsd: prevent opening of special files (CVE-2020-35517)
Date: Tue, 26 Jan 2021 10:36:19 +0000	[thread overview]
Message-ID: <20210126103619.GD3640294@redhat.com> (raw)
In-Reply-To: <20210126103502.260758-1-stefanha@redhat.com>

On Tue, Jan 26, 2021 at 10:35:02AM +0000, Stefan Hajnoczi wrote:
> A well-behaved FUSE client does not attempt to open special files with
> FUSE_OPEN because they are handled on the client side (e.g. device nodes
> are handled by client-side device drivers).
> 
> The check to prevent virtiofsd from opening special files is missing in
> a few cases, most notably FUSE_OPEN. A malicious client can cause
> virtiofsd to open a device node, potentially allowing the guest to
> escape. This can be exploited by a modified guest device driver. It is
> not exploitable from guest userspace since the guest kernel will handle
> special files inside the guest instead of sending FUSE requests.
> 
> This patch adds the missing checks to virtiofsd. This is a short-term
> solution because it does not prevent a compromised virtiofsd process
> from opening device nodes on the host.
> 
> Reported-by: Alex Xu <alex@alxu.ca>
> Fixes: CVE-2020-35517
> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Reviewed-by: Vivek Goyal <vgoyal@redhat.com>
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|



WARNING: multiple messages have this Message-ID (diff)
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: qemu-devel@nongnu.org, virtio-fs@redhat.com,
	Alex Xu <alex@alxu.ca>, P J P <ppandit@redhat.com>,
	Laszlo Ersek <lersek@redhat.com>,
	vgoyal@redhat.com
Subject: Re: [Virtio-fs] [PATCH v2] virtiofsd: prevent opening of special files (CVE-2020-35517)
Date: Tue, 26 Jan 2021 10:36:19 +0000	[thread overview]
Message-ID: <20210126103619.GD3640294@redhat.com> (raw)
In-Reply-To: <20210126103502.260758-1-stefanha@redhat.com>

On Tue, Jan 26, 2021 at 10:35:02AM +0000, Stefan Hajnoczi wrote:
> A well-behaved FUSE client does not attempt to open special files with
> FUSE_OPEN because they are handled on the client side (e.g. device nodes
> are handled by client-side device drivers).
> 
> The check to prevent virtiofsd from opening special files is missing in
> a few cases, most notably FUSE_OPEN. A malicious client can cause
> virtiofsd to open a device node, potentially allowing the guest to
> escape. This can be exploited by a modified guest device driver. It is
> not exploitable from guest userspace since the guest kernel will handle
> special files inside the guest instead of sending FUSE requests.
> 
> This patch adds the missing checks to virtiofsd. This is a short-term
> solution because it does not prevent a compromised virtiofsd process
> from opening device nodes on the host.
> 
> Reported-by: Alex Xu <alex@alxu.ca>
> Fixes: CVE-2020-35517
> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Reviewed-by: Vivek Goyal <vgoyal@redhat.com>
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|


  reply	other threads:[~2021-01-26 10:37 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-26 10:35 [PATCH v2] virtiofsd: prevent opening of special files (CVE-2020-35517) Stefan Hajnoczi
2021-01-26 10:35 ` [Virtio-fs] " Stefan Hajnoczi
2021-01-26 10:36 ` Daniel P. Berrangé [this message]
2021-01-26 10:36   ` Daniel P. Berrangé
2021-01-26 10:47 ` Liam Merwick
2021-01-26 17:16 ` Greg Kurz
2021-01-27  9:25   ` Miklos Szeredi
2021-01-27  9:25     ` Miklos Szeredi
2021-01-27 10:20     ` Greg Kurz
2021-01-27 10:20       ` Greg Kurz
2021-01-27 10:34       ` Miklos Szeredi
2021-01-27 10:34         ` Miklos Szeredi
2021-01-27 13:49         ` Greg Kurz
2021-01-27 13:49           ` Greg Kurz
2021-01-27 14:09           ` Miklos Szeredi
2021-01-27 14:09             ` Miklos Szeredi
2021-01-27 15:09             ` Greg Kurz
2021-01-27 15:09               ` Greg Kurz
2021-01-27 15:22               ` Miklos Szeredi
2021-01-27 15:22                 ` Miklos Szeredi
2021-01-27 15:35                 ` Greg Kurz
2021-01-27 15:35                   ` Greg Kurz
2021-01-27 15:47                   ` Miklos Szeredi
2021-01-27 15:47                     ` Miklos Szeredi
2021-01-27 15:52                     ` Miklos Szeredi
2021-01-27 15:52                       ` Miklos Szeredi
2021-01-28 12:14                       ` Greg Kurz
2021-01-28 12:14                         ` Greg Kurz
2021-01-28 14:00                         ` Miklos Szeredi
2021-01-28 14:00                           ` Miklos Szeredi
2021-01-28 14:26                           ` Greg Kurz
2021-01-28 14:26                             ` Greg Kurz
2021-01-27 10:18   ` Stefan Hajnoczi

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=20210126103619.GD3640294@redhat.com \
    --to=berrange@redhat.com \
    --cc=alex@alxu.ca \
    --cc=dgilbert@redhat.com \
    --cc=lersek@redhat.com \
    --cc=mszeredi@redhat.com \
    --cc=ppandit@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=slp@redhat.com \
    --cc=stefanha@redhat.com \
    --cc=vgoyal@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.