Acked-by: M. Mohan Kumar
On Monday, January 16, 2012 11:41:40 PM Daniel P. Berrange wrote:
> From: "Daniel P. Berrange"
>
> When 2c74c2cb4bedddbfa67628fbd5f9273b4e0e9903 added support for
> the 'readonly' flag against 9p filesystems, it also made QEMU
> add
Hi,
I will give a fix to disable virtfs by providing a configure option
--disable-virtfs.
But if you want use virtfs with your current setup, we can give the
option to
disable handle and proxy FS driver. Still you can use local FS driver.
Meador Inge wrote:
Did these [1] builds errors ever
Stefan Weil writes:
We need to change fsuid and fsgid in 9p server side when 9p client wants
to create a file with given uid and gid.
In my case setfsuid and setfsgid never return -1 even if a normal user tries to
change fsuid.
I am running F17 and glibc is 2.15-56.fc17
IMHO setfsuid/setfsgid
No, commit daf0b9aca9f67323266af1a92e8ea06f9d7bf408 added create
support proxy FS driver model. Local FS had support for creating files
much before.
Georg, is qemu running with root user privileges?
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subsc
Georg,
pass-through security model needs root privilege, if you want to run
qemu as non-root user either you have to use mapped security model or
proxy fs driver. But libvirt does not have support for proxy FS driver.
I posted a patch few months ago to libvirt for enabling the same. I will
do the
IDE,
> };
>
> -setfsgid(gid);
> -setfsuid(uid);
> +if (setresuid(-1, uid, suid) == -1) {
> +retval = -errno;
> +goto err_out;
> +}
> +if (setresgid(-1, gid, sgid) == -1) {
> +retval = -errno;
> +goto err_suid;
> +}
>
After changing the order of setresuid and setresgid this patch works as
expected. Please move setresgid before setresuid.
Tested-by: M. Mohan Kumar
From: "M. Mohan Kumar"
In current implementation of setfsuid/setfsgid there is no way to know
if it failed by checking the return value. This patch assumes
setfsuid/setfsgid returns -1 in case of error. Eventually kernel code
needs to be fixed.
Signed-off-by: M. Mohan Kumar
---
fs
Michael Tokarev writes:
> 28.02.2013 13:12, Aneesh Kumar K.V wrote:
>> Michael Tokarev writes:
>>
>>> When guest tries to chmod a block or char device file over 9pfs,
>>> the qemu process segfaults.
>>>
>>> On host:
>>> qemu-system-x86_64 -virtfs
>>> local,path=/dev,security_model=mapped-file
Michael Tokarev writes:
Hi,
Please try mounting with -oversion=9p2000.L
With qemu-1.4.0 and 9p2000.L, I could not recreate this issue. ie not
getting Unknown error during directory listing.
I am using Guest kernel 3.8.0-rc5+.
> When I mount a 9pfs filesystem in guest with no write permission
Michael Tokarev writes:
> 28.02.2013 17:55, M. Mohan Kumar wrote:
>> Michael Tokarev writes:
>>
>> Hi,
>>
>> Please try mounting with -oversion=9p2000.L
>>
>> With qemu-1.4.0 and 9p2000.L, I could not recreate this issue. ie not
>> gett
-fsdev can take local, handle and proxy. Could you please use try with
one of them?
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1130769
Title:
VirtFS (virtio-9p-pci) error: Parameter 'driver' exp
From: "M. Mohan Kumar"
bdrv_flags is set by bdrv_parse_discard_flags(), but later it is reset
to zero.
Signed-off-by: M. Mohan Kumar
---
blockdev.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/blockdev.c b/blockdev.c
index e174b7d..bc7016a 100644
--- a/blockdev.c
+++ b/
From: "M. Mohan Kumar"
In passthrough security model in local fs driver, after a file creation
chown and chmod are done to set the file credentials and mode as requested
by 9p client. But if there was a request to create a file with S_ISGID
bit, doing chown on that file resets the S
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
fsdev/virtfs-proxy-helper.c | 10 --
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/fsdev/virtfs-proxy-helper.c b/fsdev/virtfs-proxy-helper.c
index baafee2..5aafc38 100644
--- a/fsdev/virtfs-proxy-help
A new fsdev parameter "access" is introduced to control accessing 9p export.
access=ro|rw can be used to specify the access type. By default rw access
is given to 9p export.
Signed-off-by: M. Mohan Kumar
---
fsdev/file-op-9p.h |1 +
fsdev/qemu-fsdev.c
On Mon, May 23, 2011 at 11:08:34AM +0100, Stefan Hajnoczi wrote:
> On Mon, May 23, 2011 at 8:58 AM, M. Mohan Kumar wrote:
> > A new fsdev parameter "access" is introduced to control accessing 9p export.
> > access=ro|rw can be used to specify the access type. By default
A new fsdev parameter "readonly" is introduced to control accessing 9p export.
readonly=on|off can be used to specify the access type. By default rw access
is given to 9p export.
Signed-off-by: M. Mohan Kumar
---
Changes from previous version:
* Use "readonly" option instead
A new fsdev parameter "readonly" is introduced to control accessing 9p export.
readonly=on|off can be used to specify the access type. By default rw access
is given to 9p export.
Signed-off-by: M. Mohan Kumar
---
Change from previous version V2:
* QEMU_OPT_BOOL is used for readdonly
operations are done from this
thread to avoid TOCTTOU vulnerability.
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: M. Mohan Kumar
---
fsdev/file-op-9p.h |1 +
hw/9pfs/virtio-9p-coth.c | 105 +--
hw/9pfs/virtio-9p-coth.h | 13 +-
hw
On Wed, Jun 15, 2011 at 10:10:00PM +0200, Andreas Färber wrote:
> Am 14.06.2011 um 10:12 schrieb M. Mohan Kumar:
>
>> [RFC PATCH] virtio-9p: Use clone approach to fix TOCTOU vulnerability
>
> Subject doesn't need to be duplicated.
Ok
>
>> In passthrough security
On Wed, Jun 15, 2011 at 04:24:12PM +0100, Stefan Hajnoczi wrote:
> On Tue, Jun 14, 2011 at 9:12 AM, M. Mohan Kumar wrote:
> > [RFC PATCH] virtio-9p: Use clone approach to fix TOCTOU vulnerability
> >
> > In passthrough security model, following a symbolic link in the server
Hi Max,
Could you try passing msize=262144 for 9p mount point and post the
results?
Host:
[root@llm116 media]# ls -lhas file
1.1G -rw-r--r-- 1 root root 1.0G Apr 26 11:05 file
[root@llm116 media]# dd if=/dev/zero of=file bs=1M count=1024
1024+0 records in
1024+0 records out
1073741824 bytes (1.1
Hi Anthony,
When I tried with ldconfig version 2.14.90, ldconfig successfully completed
QEMU version: 1.0.50
Kernel version: 3.3.0-rc6+
Could you please try with recent ldconfig?
On 02/22/2012 09:28 AM, C Anthony Risinger wrote:
On Sat, Feb 18, 2012 at 11:38 AM, Aneesh Kumar K.V
wrote:
On
From: "M. Mohan Kumar"
Add both chroot worker & qemu side interfaces to create regular files in
chroot environment
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 36
hw/9pfs/virtio-9p-chroot.h|1 +
hw/
From: "M. Mohan Kumar"
Support for removing file or directory in chroot environment. Add
interfaces to remove file/directory in chroot worker and qemu side.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 18 ++
hw/9pfs/virtio-9p-chroot.h
From: "M. Mohan Kumar"
Add support to do chown in chroot process
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 18 ++
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c |9 +
3 files changed, 24 insert
From: "M. Mohan Kumar"
Add both chroot worker and qemu side interfaces to create special files
(directory, device nodes, links and symbolic links)
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 52 +
hw/9pfs/virtio-9
From: "M. Mohan Kumar"
Add support to do chmod operation in chroot process.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 18 ++
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c |5 +++--
3 files changed, 22
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 52 -
hw/9pfs/virtio-9p-chroot.c| 59 -
hw/9pfs/virtio-9p-chroot.h|3 ++
hw/9pfs/virtio-
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
osdep.c | 32
qemu-common.h |2 ++
2 files changed, 34 insertions(+), 0 deletions(-)
diff --git a/osdep.c b/osdep.c
index 56e6963..5a4d670 100644
--- a/osdep.c
+++ b/osdep.c
@@ -126
* Split patchset based on chroot side (server) and qemu side(client)
functionalities
M. Mohan Kumar (15):
Implement qemu_read_full
virtio-9p: Enable CONFIG_THREAD if CONFIG_VIRTFS is enabled
virtio-9p: Provide chroot worker side interfaces
virtio-9p: Add qemu side interfaces for chroot
From: "M. Mohan Kumar"
Implement chroot worker side interfaces like sending the file
descriptor to qemu process, reading the object request from socket etc.
Also add chroot main function and other helper routines.
Signed-off-by: M. Mohan Kumar
[mala...@us.ibm.com: Do not send fd
From: "M. Mohan Kumar"
Add chroot functionality for system calls that can operate on a file using
relative directory file descriptor.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-local.c | 41 +++--
1 files changed, 39 insertions(+), 2
From: "M. Mohan Kumar"
9p Chroot environment needs APIs defined in qemu-thread.c, so enable
CONFIG_THREAD if virtfs is enabled
Signed-off-by: M. Mohan Kumar
---
configure |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/configure b/configure
index df6340
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 17 ++---
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c | 14 --
3 files changed, 27 insertions(+), 5 deletions(-)
diff --git
From: "M. Mohan Kumar"
After creating a file object, its permission and ownership details are updated
as per 9p client's request for both passthrough and none security model.
But with chrooted environment its not required for passthrough security model.
Move all post file crea
From: "M. Mohan Kumar"
This patch adds both chroot worker and qemu side support to open a file/
directory in the chroot environment
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot.c | 29
hw/9pfs/virtio-9p-chroot.h |2 +-
hw/9pfs/virtio-9p-local
From: "M. Mohan Kumar"
Support renaming a file or directory in chroot envirnoment. Add
interfaces for renaming in chroot worker and qemu side.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 17 +
hw/9pfs/virtio-9p-chroot.h|1
From: "M. Mohan Kumar"
QEMU side interfaces to communicate with chroot worker process.
Signed-off-by: M. Mohan Kumar
[mala...@us.ibm.com: Handle when qemu process can not receive fd because
it already reached max fds]
---
Makefile.objs |2 +-
hw/9pfs/virtio-9p-chroo
On Sun, Jun 26, 2011 at 09:22:27PM +0300, Blue Swirl wrote:
> On Fri, Jun 24, 2011 at 11:22 AM, M. Mohan Kumar wrote:
> > In passthrough security model, following symbolic links in the server
> > side could result in TOCTTOU vulnerabilities.
> > (http://en.wikipedia.org/wiki/
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
Changes from previous version:
* Changed qemu_opt_{get|set}_bool to use 'bool' data type
qemu-option.c | 43 +++
qemu-option.h |3 ++-
2 files changed, 41 insertions(+),
From: "M. Mohan Kumar"
A new fsdev parameter "readonly" is introduced to control accessing 9p export.
readonly=on|off can be used to specify the access type. By default rw access
is given to 9p export.
Signed-off-by: M. Mohan Kumar
---
Changes from previous version V4:
A new fsdev parameter "readonly" is introduced to control accessing 9p export.
"readonly" can be used to specify the access type. By default "rw" access
is given to 9p export.
Signed-off-by: M. Mohan Kumar
---
fsdev/file-op-9p.h |4 +++-
fsdev/qemu-fsdev.c
Signed-off-by: M. Mohan Kumar
---
Changes from previous version V2:
* qemu_opt_set_bool does not need to call qemu_opt_parse, because it
supports only setting boolean types
Changes from previous version:
* Changed qemu_opt_{get|set}_bool to use 'bool' data type
qemu-optio
From: "Aneesh Kumar K.V"
This remove all conditional code from common code path and
make opt validation a FSDriver callback.
Signed-off-by: Aneesh Kumar K.V
Signed-off-by: M. Mohan Kumar
---
fsdev/file-op-9p.h | 15 +--
fsdev/qemu-fsdev.c
From: "M. Mohan Kumar"
Provide root privilege access to QEMU 9p proxy filesystem using socket
communication.
Proxy helper is started by root user as:
~ # virtfs-proxy-helper
{{-s|--socket -u|--uid -g|--gid}|{-f|--fd }}
-p[-r -t ]
Where uid:gid gives socket access to uid
From: "M. Mohan Kumar"
Add option to use named socket for communicating between proxy helper
and qemu proxy FS. Access to socket can be given by using command line
options -u and -g.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtfs-proxy-helpe
From: "M. Mohan Kumar"
Add interfaces to create filesystem objects like directory,
device nodes, symbolic links, links for proxy filesytem driver
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/proxy.h |4 ++
hw/9pfs/virtfs-proxy-helper.c | 63 +
From: "M. Mohan Kumar"
Add file ownership interfaces like chmod/chown, utime update, rename,
remove and truncating files for proxy FS
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/proxy.h |6 ++
hw/9pfs/virtfs-proxy-helper.c | 61 ++-
hw/9pfs/virtio-
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
Makefile | 12 ++-
hw/9pfs/virtfs-proxy-helper.texi | 63 ++
2 files changed, 74 insertions(+), 1 deletions(-)
create mode 100644 hw/9pfs/virtfs-proxy-h
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
qemu-options.hx | 30 ++
1 files changed, 22 insertions(+), 8 deletions(-)
diff --git a/qemu-options.hx b/qemu-options.hx
index 8df6165..eef98c5 100644
--- a/qemu-options.hx
+++ b/qemu-
From: "M. Mohan Kumar"
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/proxy.h |3 ++
hw/9pfs/virtfs-proxy-helper.c | 81 -
hw/9pfs/virtio-9p-proxy.c | 67 +++---
3 files changed, 144 insert
From: "M. Mohan Kumar"
Add new proxy filesystem driver to add root privilege to qemu process.
It needs a helper process to be started by root user.
Following command line can be used to utilize proxy filesystem driver
-virtfs proxy,id=,mount_tag=,sock_fd=
Signed-off-by: M. M
From: "M. Mohan Kumar"
Move p9 marshaling/unmarshaling code to a separate file so that
proxy filesytem driver can use these calls. Also made marshaling
code generic to accept "struct iovec" instead of V9fsPDU.
Signed-off-by: M. Mohan Kumar
Signed-off-by: Aneesh Kumar K.V
From: "M. Mohan Kumar"
Pass-through security model in QEMU 9p server needs root privilege to do
few file operations (like chown, chmod to any mode/uid:gid). There are two
issues in pass-through security model
1) TOCTTOU vulnerability: Following symbolic links in the server could
prov
From: "M. Mohan Kumar"
Add xattr support for proxy FS
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/proxy.h |4 ++
hw/9pfs/virtfs-proxy-helper.c | 60
hw/9pfs/virtio-9p-proxy.c | 121 ++---
3 files ch
From: "M. Mohan Kumar"
Add interfaces to open and create files for proxy file system driver.
Signed-off-by: M. Mohan Kumar
---
Makefile |2 +
configure |1 +
hw/9pfs/proxy.h |6 ++
hw/9pfs/virtfs-proxy-helpe
filesystem operations
(like CAP_DAC_OVERRIDE, CAP_FOWNER etc)
M. Mohan Kumar (12):
hw/9pfs: Move pdu_marshal/unmarshal code to a seperate file
hw/9pfs: Add new proxy filesystem driver
hw/9pfs: File system helper process for qemu 9p proxy FS
hw/9pfs: Open and create files
hw/9pfs: Create other
Add file ownership interfaces like chmod/chown, utime update, rename,
remove and truncating files for proxy FS
Signed-off-by: M. Mohan Kumar
---
Makefile|2 +-
fsdev/virtfs-proxy-helper.c | 66 +
hw/9pfs/virtio-9p-proxy.c | 134
Add interfaces to create filesystem objects like directory,
device nodes, symbolic links, links for proxy filesytem driver
Signed-off-by: M. Mohan Kumar
---
fsdev/virtfs-proxy-helper.c | 105 --
hw/9pfs/virtio-9p-proxy.c | 173
Signed-off-by: M. Mohan Kumar
---
fsdev/virtfs-proxy-helper.c | 165
hw/9pfs/virtio-9p-proxy.c | 174 +--
hw/9pfs/virtio-9p-proxy.h | 34 +
3 files changed, 367 insertions(+), 6 deletions(-)
diff
Add new proxy filesystem driver to add root privilege to qemu process.
It needs a helper process to be started by root user.
Following command line can be used to utilize proxy filesystem driver
-virtfs proxy,id=,mount_tag=,socket_fd=
Signed-off-by: M. Mohan Kumar
---
Makefile.objs
ent to qemu and virtfs-proxy-helper. Also having
a server like virtfs-proxy-helper listening on a pathname without any
authentication is little bit scary. So we have to decide whether this
patch is really needed.
Signed-off-by: M. Mohan Kumar
Signed-off-by: Aneesh Kumar K.V
---
fsdev/file-o
Signed-off-by: M. Mohan Kumar
---
qemu-options.hx | 25 -
1 files changed, 16 insertions(+), 9 deletions(-)
diff --git a/qemu-options.hx b/qemu-options.hx
index 681eaf1..cde17ed 100644
--- a/qemu-options.hx
+++ b/qemu-options.hx
@@ -530,19 +530,19 @@ DEFHEADING
Move p9 marshaling/unmarshaling code to a separate file so that
proxy filesytem driver can use these calls. Also made marshaling
code generic to accept "struct iovec" instead of V9fsPDU.
Signed-off-by: M. Mohan Kumar
---
Makefile.objs |2 +-
fsdev/virtio-9p-marsha
Changes from previous version:
1) Communication between qemu and helper process is similar to 9p way of
packing
elements (pdu marshaling).
M. Mohan Kumar wrote:
Pass-through security model in QEMU 9p server needs root privilege to do
few file operations (like chown, chmod to any mode/uid:gid
Signed-off-by: M. Mohan Kumar
---
Makefile | 12 +++-
fsdev/virtfs-proxy-helper.texi | 59
2 files changed, 70 insertions(+), 1 deletions(-)
create mode 100644 fsdev/virtfs-proxy-helper.texi
diff --git a/Makefile b/Makefile
filesystem operations
(like CAP_DAC_OVERRIDE, CAP_FOWNER etc)
M. Mohan Kumar (12):
hw/9pfs: Move pdu_marshal/unmarshal code to a seperate file
hw/9pfs: Add new proxy filesystem driver
hw/9pfs: File system helper process for qemu 9p proxy FS
hw/9pfs: Open and create files
hw/9pfs: Create other
Add xattr support for proxy FS
Signed-off-by: M. Mohan Kumar
---
fsdev/virtfs-proxy-helper.c | 78 -
hw/9pfs/virtio-9p-proxy.c | 119 +++
hw/9pfs/virtio-9p-proxy.h |4 ++
3 files changed, 190 insertions(+), 11
Add proxy getversion to get generation number
Signed-off-by: M. Mohan Kumar
---
fsdev/virtfs-proxy-helper.c | 74 +++
hw/9pfs/virtio-9p-proxy.c | 31 ++
hw/9pfs/virtio-9p-proxy.h |1 +
3 files changed, 106 insertions(+), 0
Add interfaces to open and create files for proxy file system driver.
Signed-off-by: M. Mohan Kumar
---
fsdev/virtfs-proxy-helper.c | 136 +++-
hw/9pfs/virtio-9p-proxy.c | 180 +--
hw/9pfs/virtio-9p-proxy.h |9 ++
3
Provide root privilege access to QEMU 9p proxy filesystem using socket
communication.
Proxy helper is started by root user as:
~ # virtfs-proxy-helper -f|--fd -p|--path
Signed-off-by: M. Mohan Kumar
---
Makefile|3 +
configure | 19 +++
fsdev
Stefan Hajnoczi wrote:
On Tue, Nov 15, 2011 at 11:57 AM, M. Mohan Kumar wrote:
diff --git a/fsdev/virtfs-proxy-helper.c b/fsdev/virtfs-proxy-helper.c
new file mode 100644
index 000..69daf7c
--- /dev/null
+++ b/fsdev/virtfs-proxy-helper.c
@@ -0,0 +1,271 @@
+/*
+ * Helper for QEMU Proxy
Add support to do chown in chroot process
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 18 ++
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c |9 +
3 files changed, 24 insertions(+), 4 deletions(-)
diff --git
igned-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-local.c | 25 +
1 files changed, 9 insertions(+), 16 deletions(-)
diff --git a/hw/9pfs/virtio-9p-local.c b/hw/9pfs/virtio-9p-local.c
index 3b97f51..68551e2 100644
--- a/hw/9pfs/virtio-9p-local.c
+++ b/hw/9pfs/virt
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 52 -
hw/9pfs/virtio-9p-chroot.c| 59 -
hw/9pfs/virtio-9p-chroot.h|3 ++
hw/9pfs/virtio-9p-local.c | 30
Add support to do chmod operation in chroot process.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 18 ++
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c |5 +++--
3 files changed, 22 insertions(+), 2 deletions(-)
diff
This patch adds both chroot worker and qemu side support to open a file/
directory in the chroot environment
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot.c | 29
hw/9pfs/virtio-9p-chroot.h |2 +-
hw/9pfs/virtio-9p-local.c | 79
QEMU side interfaces to communicate with chroot worker process.
Signed-off-by: M. Mohan Kumar
[mala...@us.ibm.com: Handle when qemu process can not receive fd because
it already reached max fds]
---
Makefile.objs |2 +-
hw/9pfs/virtio-9p-chroot.c | 103
9p Chroot environment needs APIs defined in qemu-thread.c, so enable
CONFIG_THREAD if virtfs is enabled
Signed-off-by: M. Mohan Kumar
---
configure |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/configure b/configure
index 1340c33..ad59fcc 100755
--- a/configure
+++ b
Implement chroot worker side interfaces like sending the file
descriptor to qemu process, reading the object request from socket etc.
Also add chroot main function and other helper routines.
Signed-off-by: M. Mohan Kumar
[mala...@us.ibm.com: Do not send fd as part of data, instead a special
Add both chroot worker & qemu side interfaces to create regular files in
chroot environment
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 36
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c |
fatal, ie qemu will exit
* Split patchset based on chroot side (server) and qemu side(client)
functionalities
M. Mohan Kumar (15):
Implement qemu_read_full
virtio-9p: Enable CONFIG_THREAD if CONFIG_VIRTFS is enabled
virtio-9p: Provide chroot worker side interfaces
virtio-9p: qemu
Add both chroot worker and qemu side interfaces to create special files
(directory, device nodes, links and symbolic links)
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 52 +
hw/9pfs/virtio-9p-chroot.h|5 +++
hw/9pfs
Support for removing file or directory in chroot environment. Add
interfaces to remove file/directory in chroot worker and qemu side.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 18 ++
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p
Signed-off-by: M. Mohan Kumar
---
osdep.c | 32
qemu-common.h |2 ++
2 files changed, 34 insertions(+), 0 deletions(-)
diff --git a/osdep.c b/osdep.c
index 56e6963..5a4d670 100644
--- a/osdep.c
+++ b/osdep.c
@@ -126,6 +126,38 @@ ssize_t
Support renaming a file or directory in chroot envirnoment. Add
interfaces for renaming in chroot worker and qemu side.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 17 +
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c
Add chroot functionality for system calls that can operate on a file using
relative directory file descriptor.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-local.c | 41 +++--
1 files changed, 39 insertions(+), 2 deletions(-)
diff --git a/hw/9pfs
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-chroot-worker.c | 17 ++---
hw/9pfs/virtio-9p-chroot.h|1 +
hw/9pfs/virtio-9p-local.c | 14 --
3 files changed, 27 insertions(+), 5 deletions(-)
diff --git a/hw/9pfs/virtio-9p-chroot-worker.c
b
On Tuesday, September 06, 2011 08:18:22 PM Stefan Hajnoczi wrote:
> A virtfs feature that needs root therefore needs to be in a separate
> process. Either QEMU needs to fork or virtfs could use a separate
> daemon binary.
>
> You have already implemented the fork approach in the chroot
> I agree, regardless of libvirt's needs, p9fs needs to be secure for any
> non-root user using QEMU. As non-root I should be able todo
>
> $ qemu -virtfs $HOME/shared
>
> and have strong confidence that symlink attacks can't be used by the
> guest to access other locations nuder $HOME.
>
> >
Guest and the host may not be running same architecture.
Hence fcntl flag mapping is needed.
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Aneesh Kumar K.V
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p.c | 50 +-
hw/9pfs/virtio
Use 9P specific lock constants instead of arch specific lock constants.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p.c |2 +-
hw/9pfs/virtio-9p.h |6 ++
2 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/hw/9pfs/virtio-9p.c b/hw/9pfs/virtio-9p.c
index 668ea24
per.pod,
> which can't be created because fsdev/ does not exist.
>
Hi,
I tried ./configure --disable-system --enable-virtfs and make. But didnt
face any build failure. Could you please share your build failure
information? virtfs-proxy-helper.1 is created inside the fsdev folder.
Peter Maydell writes:
How about this approach?
[PATCH] configure: Disable virtfs if softmmu not enabled
Signed-off-by: M. Mohan Kumar
---
configure | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/configure b/configure
index 1654413..88c2b0f 100755
--- a
Michael Tokarev writes:
> 11.06.2013 21:23, M. Mohan Kumar wrote:
>> Peter Maydell writes:
>>
>> How about this approach?
>
> Well, this is definitely wrong :)
>
>> -if test "$softmmu" = yes ; then
>> - if test "$virtfs" != n
Stefan Weil writes:
> This leak was reported by cppcheck.
>
> Signed-off-by: Stefan Weil
Reviewed-by: M. Mohan Kumar
> ---
> fsdev/qemu-fsdev.c |2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/fsdev/qemu-fsdev.c b/fsdev/qemu-fsdev.c
> index 6eaf36d..c
Stefan Weil writes:
> The leak was reported by cppcheck.
>
> Function proxy_init also calls g_free for ctx->fs_root.
> Avoid reuse of this memory by setting ctx->fs_root to NULL.
>
> Signed-off-by: Stefan Weil
Reviewed-by: M. Mohan Kumar
> ---
>
> Hi,
>
From: "M. Mohan Kumar"
Fix few more memory leaks in virtio-9p-device.c detected using valgrind.
Signed-off-by: M. Mohan Kumar
---
hw/9pfs/virtio-9p-device.c | 26 +-
1 file changed, 17 insertions(+), 9 deletions(-)
diff --git a/hw/9pfs/virtio-9p-device.c
ath=/tmp/,security_model=prox,mount_tag=v_pass
People who want to use proxy_helper without libvirt can use following
interface:
$ proxy_helper -s -p <9p-path-to-export>
With following qemu fsdev parameter:
-virtfs proxy,id=,socket=,path=/tmp/,
security_model=prox,mount_tag=v_pass
--
Regards,
M. Mohan Kumar
1 - 100 of 282 matches
Mail list logo