Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-09-30 Thread Stefano Stabellini
On Wed, 30 Sep 2015, Ian Campbell wrote: > On Tue, 2015-09-29 at 18:07 +0100, Ian Jackson wrote: > > Stefano Stabellini writes ("Re: [PATCH v7] run QEMU as non-root"): > > > On Fri, 7 Aug 2015, Wei Liu wrote: > > > > Please use for / while to loop. > > > > > > The goto retry loop is a very common p

Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-09-30 Thread Ian Campbell
On Tue, 2015-09-29 at 18:07 +0100, Ian Jackson wrote: > Stefano Stabellini writes ("Re: [PATCH v7] run QEMU as non-root"): > > On Fri, 7 Aug 2015, Wei Liu wrote: > > > Please use for / while to loop. > > > > The goto retry loop is a very common patter for error handling, but I > > can turn it into

Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-09-29 Thread Ian Jackson
Stefano Stabellini writes ("Re: [PATCH v7] run QEMU as non-root"): > On Fri, 7 Aug 2015, Wei Liu wrote: > > Please use for / while to loop. > > The goto retry loop is a very common patter for error handling, but I > can turn it into a loop if you are keen on it. I'm afraid I agree with Wei here.

Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-09-29 Thread Stefano Stabellini
On Fri, 7 Aug 2015, Wei Liu wrote: > On Thu, Jul 23, 2015 at 06:08:02PM +0100, Stefano Stabellini wrote: > [...] > > +For security reasons, libxl tries to pass a non-root username to QEMU as > > +argument. During initialization QEMU calls setuid and setgid with the > > +user ID and the group ID of

Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-08-07 Thread Wei Liu
On Mon, Jul 27, 2015 at 03:19:56PM +0200, Fabio Fantoni wrote: > Il 23/07/2015 19:08, Stefano Stabellini ha scritto: > >Try to use "xen-qemudepriv-domid$domid" first, then > >"xen-qemudepriv-shared" and root if everything else fails. > > > >The uids need to be manually created by the user or, more

Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-08-07 Thread Wei Liu
On Thu, Jul 23, 2015 at 06:08:02PM +0100, Stefano Stabellini wrote: [...] > +For security reasons, libxl tries to pass a non-root username to QEMU as > +argument. During initialization QEMU calls setuid and setgid with the > +user ID and the group ID of the user passed as argument. > +Libxl looks f

Re: [Xen-devel] [PATCH v7] run QEMU as non-root

2015-07-27 Thread Fabio Fantoni
Il 23/07/2015 19:08, Stefano Stabellini ha scritto: Try to use "xen-qemudepriv-domid$domid" first, then "xen-qemudepriv-shared" and root if everything else fails. The uids need to be manually created by the user or, more likely, by the xen package maintainer. Expose a device_model_user setting

[Xen-devel] [PATCH v7] run QEMU as non-root

2015-07-23 Thread Stefano Stabellini
Try to use "xen-qemudepriv-domid$domid" first, then "xen-qemudepriv-shared" and root if everything else fails. The uids need to be manually created by the user or, more likely, by the xen package maintainer. Expose a device_model_user setting in libxl_domain_build_info, so that opinionated caller