Quota doesn't reflect all files

fuzzymonkey

Well-Known Member
Jun 11, 2004
61
0
156
I'm having another php problem... At least I'm assuming this has to do with my previous php problem (abridged: php running as nobody makes uploaded files owned by nobody, causing users to have unlimited quota if they upload the files with a php program).

Is there a tool that will chown all the right files in a user's home directory to that user?
 

aby

Well-Known Member
May 31, 2005
638
0
166
India
fuzzymonkey said:
I'm having another php problem... At least I'm assuming this has to do with my previous php problem (abridged: php running as nobody makes uploaded files owned by nobody, causing users to have unlimited quota if they upload the files with a php program).

Is there a tool that will chown all the right files in a user's home directory to that user?
Try this script

/scripts/enablefileprotect

Also you can disable the upload option using php ....
 

fuzzymonkey

Well-Known Member
Jun 11, 2004
61
0
156
Thanks for your reply. I ran the script, but I think it only fixes permissions, not ownership. There are still tons of files owned by "nobody." I guess I'll have to chown them all by hand.
 

fuzzymonkey

Well-Known Member
Jun 11, 2004
61
0
156
For future reference, I cd'ed to /home as root, and ran the following bash command:
Code:
for f in * ; do chown $f:$f /home/$f/public_html/* -R ; done