Re: Hard link to root-owned file now fails (since Fedora 19)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jul 16, 2013 at 11:50:10AM -0400, Colin Walters wrote:
> On Tue, 2013-07-16 at 15:59 +0100, Richard W.M. Jones wrote:
> >  I'm not even sure
> > how to do that because we want the atomic behaviour of hard links, and
> > we want to have qemu running as a different user (for security, oh the
> > irony), so there's no other obvious way to code it.
> 
> Can you link to or describe the relevant algorithm/code?  The file
> https://github.com/openstack/nova/blob/master/nova/virt/disk/vfs/guestfs.py#L94
> doesn't contain an obvious call to link().

Thanks for any input.  It's this code below.  The big comment at the
top explains roughly what's going on, but misses out a crucial detail:
If you are using libvirt in a certain way, then libvirtd [which runs
as root] will chown the 'kernel' and 'initrd' files to root.root.  If
that chown didn't happen, then none of this would be a problem.

https://github.com/libguestfs/libguestfs/blob/master/src/appliance.c#L68

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Fedora Windows cross-compiler. Compile Windows programs, test, and
build Windows installers. Over 100 libraries supported.
http://fedoraproject.org/wiki/MinGW
-- 
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/devel





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux