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

Re: chmod help



Hi!

E.L. Meijer Eric" (tgakem@sg10.chem.tue.nl):
> > *-debianuser@jkeating.static.execpc.com (Default Debian Reader)
> > |
> > | How can i change the perms on a directory so that a file that is copied into that directory is automatically owned by another user and group?

> Don't know if anyone mentioned it already, but you can actually do this
> for the group ownership.  If you do a `chmod g+s <dir>', new files
> created in this directory will get the same group.

Hmm, do you have an idea how to deal with an anonFTP like incoming
directory, too? This dir is direct accessible and (the big problem) the guy
to sort all this stuff will (hopefully) never get root.

I made a "diaradm" group and added this guy to it. Then made the dir sgid
diradm. "guy" has to cp things to its new location to change owner.

drawbacks
 - luser xyz does "chgrp xyz subdir" and "guy" is locked out :-(
 - cp may have some problems when space becomes limited and its SLOW
   compared to a mv (on the same partition)

Do I need to write somethind suid root which guy can run (like "chown -R guy
dir" )?


Rainer

-- 
KeyID=58341901 fingerprint=A5 57 04 B3 69 88 A1 FB  78 1D B5 64 E0 BF 72 EB


Reply to: