uploads directory independent minded

Having trouble installing serendipity?
Post Reply
Bruce
Regular
Posts: 18
Joined: Sun Mar 14, 2004 5:28 am
Location: Ontario/ Canada
Contact:

uploads directory independent minded

Post by Bruce »

After installing (a great smooth install) everything is great! I like the program. I tried the upload picture, and found they didnt show, checking directory permissions I found uploads is set at 770.

I cannot open the directory nor change the permissions. I have never had that happen before. Can't see anything to change in htaccess either???
I have ftp access only to webserver. I imagine the no show on photos is due to the uploads directory being inaccessible?
I didn't do it
Bruce
Regular
Posts: 18
Joined: Sun Mar 14, 2004 5:28 am
Location: Ontario/ Canada
Contact:

duh?

Post by Bruce »

I made a new upload directory called photos, chmod 777 and entered it in configuration and it works now. Maybe this post should be deleted?
I didn't do it
RazorSA
Posts: 1
Joined: Thu Mar 25, 2004 8:50 am

Worked for me ...

Post by RazorSA »

Very strange in deed...

Up until today, nothing I did could make this work !!!
I tried everything.

Then today... I just did this "chmod -R 0777 uploads" again, and it worked 100% ...


hmmm ... Maybe my server ...
MsMittens
Regular
Posts: 12
Joined: Thu Mar 04, 2004 6:05 pm

Post by MsMittens »

Permissions work like this: rwxrwxrwx. The first three rwx (read/write/execute) apply to the user that owns the directory. The second three rwx apply to the primary group that the user is a member of (it's commonly "users" but could be something else). The last rwx applies to the "rest of the world". Now, a couple of things come to mind:

- uploading to FTP is commonly set to 222. The write option available for all users (owner, group, everyone) ensures that people can upload but cannot browse the directory. This avoids people seeing and accessing files that don't belong to them necessary. This is particularly helpful if users are uploading anonymously and you want some type of simple protection from "nosy-ness".

- uploading via Web. It was mentioned that the directory was 770. Since the web user is commonly Apache, any uploads through it will be sent as if it was Apache rather than the owner of the directory. Do not confuse your login into the Serendipity Admin section as being the user of the directory. It's not the same. The Serendipity user is stored in the SQL database whereas your account on the apache server is stored in two files: /etc/passwd and /etc/shadow.

What I would humbly suggest is some thought towards security. If you are going to allow uploads limit what browsing users can do (users need execute to get into a directory and read to see in the directory). So it might be better to use 703 to limit what they see.

Just an idear. :)
Post Reply