qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v4 0/3] 9pfs security fixes
@ 2016-08-30 17:10 Greg Kurz
  2016-08-30 17:11 ` [Qemu-devel] [PATCH v4 1/3] 9pfs: forbid illegal path names Greg Kurz
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: Greg Kurz @ 2016-08-30 17:10 UTC (permalink / raw)
  To: qemu-devel
  Cc: Peter Maydell, Felix Wilhelm, Michael S. Tsirkin, Greg Kurz,
	P J P, Aneesh Kumar K.V, Eric Blake

As reported by Felix Wilhelm, at various places in 9pfs, full paths are
created by concatenating a guest originated string to the export path. A
malicious guest could forge a relative path and access files outside the
export path.

A tentative fix was sent recently by Prasad J Pandit, but it was only
focused on the local backend and did not get a positive review. This series
tries to address the issue more globally, based on the official 9P spec.

I wasn't running the TUXERA test suite correctly and overlooked a failure
with symbolic links (thanks Aneesh for your assistance). This v4 is basically
the same as v3 with a change in patch 1/3.

---

Greg Kurz (3):
      9pfs: forbid illegal path names
      9pfs: forbid . and .. in file names
      9pfs: handle walk of ".." in the root directory


 hw/9pfs/9p.c |  147 ++++++++++++++++++++++++++++++++++++++++++++++++++++++----
 hw/9pfs/9p.h |    1 
 2 files changed, 139 insertions(+), 9 deletions(-)

--
Greg

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2016-09-15 22:23 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-30 17:10 [Qemu-devel] [PATCH v4 0/3] 9pfs security fixes Greg Kurz
2016-08-30 17:11 ` [Qemu-devel] [PATCH v4 1/3] 9pfs: forbid illegal path names Greg Kurz
2016-08-30 18:03   ` Eric Blake
2016-08-30 19:27     ` Greg Kurz
2016-08-31  2:42     ` Aneesh Kumar K.V
2016-08-30 17:13 ` [Qemu-devel] [PATCH v4 2/3] 9pfs: forbid . and .. in file names Greg Kurz
2016-08-30 18:06   ` Eric Blake
2016-08-30 19:03     ` Greg Kurz
2016-08-30 18:19 ` [Qemu-devel] [PATCH v4 0/3] 9pfs security fixes Michael S. Tsirkin
2016-08-30 18:29 ` Peter Maydell
2016-08-30 19:39   ` Peter Maydell
2016-08-31  9:33     ` Greg Kurz
2016-08-30 18:40 ` [Qemu-devel] [PATCH v4 3/3] 9pfs: handle walk of ".." in the root directory Greg Kurz
2016-09-15 22:22   ` Paolo Bonzini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).