Thanks to everyone who had responded to this, specifically to Edward Grimm.
Below is my question reproduced:
> Can I get the 'chown' to make it work for non-root users on
> SunOS 4.1.4?
I wanted this badly, as frequent requests from users to change owner to some
one else, kept coming to me.
The replies - summarized - were:
1. DONT' DO IT - Because of User Quota getting affected.
2. SETUID chown - As suggested by themselves,very dangerous as anybody can
simply become root. Not a good idea.
3. Unset the _POSIX_CHOWN_RESTRICTED OS option -
- It looked to me initially as the actual solution, but
further analysis proved to me that in SunOS, there is no
way to unset this option at all.(man 2 chown will give the
The chown behaviour is seen only in SunOS and Solaris, and other OS like
Unixware and other SVR4 systems have chown working for non-root users too.
They solve the security problem by UNSETTING all setuid,setgid bits on the
Hence the only solution on SunOS to me, looks like writing my own chown
program and give SETUID perms to that "mychown". This "mychown" will unset
all the setuid,setgid bits on the file being chown'ed. Our site does not
have User quotas implemented and hence this should be fine for me.
Edward Grimm <email@example.com>
Pete A. Zaitcev <firstname.lastname@example.org>
Rodney Marable <email@example.com>
Keith Willenson <firstname.lastname@example.org>
Michael McGeown <email@example.com>
Salvador Ramirez <firstname.lastname@example.org
Gokhan ERDEM <email@example.com>
Sesharao Patchipala <firstname.lastname@example.org>
Tommy Williams <email@example.com>
Daniel E. Singer <firstname.lastname@example.org>
Daniel Beaudry <Daniel.Beaudry@Enter-Net.com>
Richard Pieri <email@example.com>
Kaushik Pushpavanam <firstname.lastname@example.org>
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:11:10 CDT