all,
I havent had to do this for a while ie change group status as a
USER, but now I do ...
/tmp is a mounted partition.
[127] [EMAIL PROTECTED] ~ >ls -la /tmp
total 7760
drwxrwxrwt 19 root root 16384 Jan 15 12:38 .
drwxr-xr-x 27 root root 4096 Oct 22 23:20 ..
[snip]
[128] [EMAIL PROTECTED] ~ >touch aa
[129] [EMAIL PROTECTED] ~ >chgrp apache aa
chgrp: changing group of `aa': Operation not permitted
[130] [EMAIL PROTECTED] ~ >ls -la aa
-rw-r--r-- 1 bundah bundah 0 Jan 15 12:40 aa
My understanding is:
Some files can't be chown()'ed at all: files on read-only filesystem, immutable and
append-only ones.
Otherwise root can change UID and GID as it wishes.
Non-root can't change UID of file.
Non-root can't change GID of file if he isn't the owner.
If non-root owns a file it can change the GID to any of the groups the changing
process belongs to. Any change of GID is subject to quotas.
Both for root and non-root processes:
Change of UID turns suid off.
Change of GID for group-executable turns sgid off.
...
...
How come I cant change that bloody UID?
(I can if I su root).
jobst
--
The email address in this email is used for Mailing Lists Only.
Please reply ONLY to the list email address, do not reply to the
email directly, it gets send to /dev/null.
Why don't sheep shrink when it rains?
__, Jobst Schmalenbach, Technical Director
_ _.--'-n_/ Barrett Consulting Group P/L & The Meditation Room P/L
-(_)------(_)= +61 3 9532 7677, POBox 277, Caulfield South, 3162, Australia
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html