From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=32950 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OOH6K-0002RS-De for qemu-devel@nongnu.org; Mon, 14 Jun 2010 17:21:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OOH6J-0003ys-2f for qemu-devel@nongnu.org; Mon, 14 Jun 2010 17:21:48 -0400 Received: from e38.co.us.ibm.com ([32.97.110.159]:38944) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OOH6I-0003yM-Tz for qemu-devel@nongnu.org; Mon, 14 Jun 2010 17:21:47 -0400 Received: from d03relay01.boulder.ibm.com (d03relay01.boulder.ibm.com [9.17.195.226]) by e38.co.us.ibm.com (8.14.4/8.13.1) with ESMTP id o5ELF4KP006439 for ; Mon, 14 Jun 2010 15:15:04 -0600 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay01.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id o5ELLZeW037164 for ; Mon, 14 Jun 2010 15:21:41 -0600 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id o5ELLY88028732 for ; Mon, 14 Jun 2010 15:21:34 -0600 Message-ID: <4C169D5F.4010609@linux.vnet.ibm.com> Date: Mon, 14 Jun 2010 14:21:35 -0700 From: "Venkateswararao Jujjuri (JV)" MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH-V7 09/10] virtio-9p: Implement Security model for mknod References: <1276547689-3408-1-git-send-email-jvrao@linux.vnet.ibm.com> <1276547689-3408-10-git-send-email-jvrao@linux.vnet.ibm.com> <4C169973.60004@linux.vnet.ibm.com> In-Reply-To: <4C169973.60004@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: qemu-devel@nongnu.org Anthony Liguori wrote: > On 06/14/2010 03:34 PM, Venkateswararao Jujjuri (JV) wrote: >> Mapped mode stores extended attributes in the user space of the extended >> attributes. Given that the user space extended attributes are available >> to regular files only, special files are created as regular files on the >> fileserver and appropriate mode bits are added to the extended >> attributes. >> This method presents all special files and symlinks as regular files >> on the >> fileserver while they are represented as special files on the guest >> mount. >> >> On Host/Fileserver: >> -rw-------. 1 virfsuid virtfsgid 0 2010-05-11 09:36 afifo >> -rw-------. 1 virfsuid virtfsgid 0 2010-05-11 09:32 blkdev >> -rw-------. 1 virfsuid virtfsgid 0 2010-05-11 09:33 chardev >> >> On Guest/Client: >> prw-r--r-- 1 guestuser guestuser 0 2010-05-11 12:36 afifo >> brw-r--r-- 1 guestuser guestuser 0, 0 2010-05-11 12:32 blkdev >> crw-r--r-- 1 guestuser guestuser 4, 5 2010-05-11 12:33 chardev >> >> In the passthrough securit model, specifal files are directly created >> on the fileserver. But the user credential >> >> Signed-off-by: Venkateswararao Jujjuri >> --- >> hw/file-op-9p.h | 2 +- >> hw/virtio-9p-local.c | 34 ++++++++++++++++++++++++++++++++-- >> hw/virtio-9p.c | 14 ++++++++++---- >> 3 files changed, 43 insertions(+), 7 deletions(-) >> >> >> static int local_mksock(FsContext *ctx2, const char *path) >> diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c >> index 1a25e96..d276db3 100644 >> --- a/hw/virtio-9p.c >> +++ b/hw/virtio-9p.c >> @@ -160,9 +160,15 @@ static int v9fs_do_chmod(V9fsState *s, V9fsString >> *path, mode_t mode) >> return s->ops->chmod(&s->ctx, path->data,&cred); >> } >> >> -static int v9fs_do_mknod(V9fsState *s, V9fsString *path, mode_t mode, >> dev_t dev) >> +static int v9fs_do_mknod(V9fsState *s, V9fsCreateState *vs, mode_t mode, >> + dev_t dev) >> { >> > > You've added this function *before* you actually declare V9fsCreateState > which is happening way down before v9fs_post_create(). > > Did you actually build these patches before sending them to the list? Yes I did. This patch series is built on the following two patches. Please apply these two patches before taking this patch series. [PATCH-V2] [virtio-9p] Flush the debug message out to the log file. (http://lists.gnu.org/archive/html/qemu-devel/2010-06/msg00255.html) [PATCH] virtio-9p: Rearrange fileop structures (http://lists.gnu.org/archive/html/qemu-devel/2010-06/msg00143.html) Sorry for the confusion. - JV > > Regards, > > Anthony Liguori >