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

Re: fakeroot inquiry

Roland McGrath <roland@frob.com> writes:

> For building packages, you could just use a tmpfs with uid-mapping.
> i.e.
> 	$ settrans -ca my-pkg /hurd/tmpfs --map-uid=`whoami`:root
> 	$ make install prefix=my-pkg
> 	$ tar cf my-pkg.tar my-pkg
> 	$ settrans -g my-pkg
> 	$ rm -f my-pkg

Is uid remapping really what is wanted here? If I want to install some
files in the tree as owned by, say, "tty", how does any mapping
between my uid and root help?

Or are you saying that the mapping is not only a translation applied
when reading and writing the owner attributes in the filesystem, but
also for other access control? So that when I try to chown a file to
"tty", the filesystem should first put the caller's uid through the
mapping, so that I translate to root, and then think "this guy is
root, just do anything he asks for". That would work.

> 	$ settrans -ca my-pkg /hurd/tmpfs --map-uid=`whoami`:root

The whoami invocation seems a little ugly. There should probably be
some other way to refer to the uid that owns the underlying node, or
something like that.

> Note also, this all is only the filesystem part of what fakeroot does.
> fakeroot also fakes out getuid and so forth so that e.g. `whoami' says
> `root'.

I wonder how much it is that depends on that.


To UNSUBSCRIBE, email to debian-hurd-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Reply to: