User: Password:
|
|
Subscribe / Log in / New account

unionfs and software installation

unionfs and software installation

Posted Jan 17, 2008 9:10 UTC (Thu) by skitching (subscriber, #36856)
Parent article: State of the unionfs

Can unionfs be used as a way to install packages on a per-user level?

That is, mount ~/root/bin as a writable layer over /bin, and ~/root/etc over /etc and so
forth, then run tools like dpkg or rpm to install packages on a per-user basis?

That would seem to be a really useful tool..it sucks that unix systems are meant to be
multi-user, yet users still need to ask an administrator to install packages.


(Log in to post comments)

unionfs and software installation

Posted Jan 17, 2008 10:44 UTC (Thu) by jengelh (subscriber, #33263) [Link]

You would still need `chroot ~/root` to get the program binary find its auxiliary files
(remember, paths are often hardcoded).

Yes. and No. and Yes.

Posted Jan 17, 2008 10:48 UTC (Thu) by hummassa (subscriber, #307) [Link]

The problem of "letting a non-admin user installing software" versus "not 
allowing malware to take over the entire system" is still unsolved.

To worsen things, these days the main objectives of malware are "(2) 
recover this user bank passwords, CC numbers, and SS-equiv number" 
and "(1) send the greatest possible amount of spam" because that is what 
the market want from malware. IOW, once the user is fooled to execute 
_any_ malware (even non-rootkitting malware) the damage is done.

Yes. and No. and Yes.

Posted Jan 17, 2008 16:10 UTC (Thu) by nix (subscriber, #2304) [Link]

It occurs to me that this could be used to make fakeroot a lot less ugly internally. It
wouldn't need to mess around transforming paths anymore, just union-mount something writable
over / in a per-process cloned namespace, fake out permissions checks, and Bob's your uncle :)
no harm can be done should the code 'overwrite' /etc/shadow or 'delete' /usr, because trusted
code could inspect the writable union target post-'make install' and transfer only those parts
which look acceptable onto the underlying filesystem(s).

Yes. and No. and Yes.

Posted Jan 18, 2008 8:59 UTC (Fri) by njs (guest, #40338) [Link]

I thought that the point of fakeroot was that it let you do arbitrary (virtual) chown/chmod's
on files you had just created, not that it let you scribble randomly on the existing
filesystem.

I guess you could have, like, a FUSE filesystem that allowed anyone to do arbitrary
chown/chmod, but could only be mounted nodev nosuid.  That might be safe and effective.  Or
something with containers?

unionfs and software installation

Posted Jan 19, 2008 0:59 UTC (Sat) by giraffedata (subscriber, #1954) [Link]

users still need to ask an administrator to install packages.

I wasn't aware that was the case. Isn't that a weakness in the installer or the package being installed? You should be able to install the files in any directory you like and use PATH and other environment variables to make them found (even in preference to another version in a system directory).

The direction the Unix world has been moving in for allowing users to install things is for each user to have his own Unix system with root password; but at least in the old days, installing something privately in a home directory without system privilege was something explicitly allowed for. In fact, you could have multiple levels of administration: E.g. system, department, team, person -- all through the use of PATH etc.

It isn't acceptable for an unprivileged user to override /bin at the filesystem level, because setuid programs rely on certain file names referring to certain files.


Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds