Current time: 12-24-2024, 03:59 AM Hello There, Guest! (LoginRegister)


Post Reply 
PHP uploads are not readable
Author Message
Eminos Offline
Junior Member
*

Posts: 159
Joined: Jan 2007
Reputation: 0
Post: #1
PHP uploads are not readable
Hi there,

I would really need this one to be fixed, maybe some pro could take a look at it ? Customers are complaining Sad

http://www.isp-control.net/ispcp/ticket/764

Thanks in advance.

/E
11-03-2007 10:48 PM
Find all posts by this user Quote this message in a reply
rbtux Offline
Moderator
*****
Moderators

Posts: 1,847
Joined: Feb 2007
Reputation: 33
Post: #2
RE: PHP uploads are not readable
can you try to set the upload_tmp_dir to:

upload_tmp_dir = "N;0644;/path/to/tmp"

this works with the session save path. maybe it also works with upload tmp dir...
11-03-2007 11:25 PM
Visit this user's website Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #3
RE: PHP uploads are not readable
Hi Eminos

Maybe you should look for a solution.
I just did some tests:
with mod_php the mode of an uploaded file is 0600
with fastcgi the same - but the user/owner is another one.

I didn't see any way to change the default mode to something else.
Maybe it's rather a good idea to check the applications which do not check/correct the permissions of uploaded files...

/J
11-03-2007 11:57 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Eminos Offline
Junior Member
*

Posts: 159
Joined: Jan 2007
Reputation: 0
Post: #4
RE: PHP uploads are not readable
joximu Wrote:with mod_php the mode of an uploaded file is 0600
with fastcgi the same - but the user/owner is another one.

Yes, but isn't that wrong? It should be 644 right ?
Coz this used to work with older versions of ISPCP.

/E
(This post was last modified: 11-04-2007 12:08 AM by Eminos.)
11-03-2007 11:59 PM
Find all posts by this user Quote this message in a reply
Eminos Offline
Junior Member
*

Posts: 159
Joined: Jan 2007
Reputation: 0
Post: #5
RE: PHP uploads are not readable
rbtux Wrote:can you try to set the upload_tmp_dir to:

upload_tmp_dir = "N;0644;/path/to/tmp"

this works with the session save path. maybe it also works with upload tmp dir...

I'm using Joomla when uploading, but I guess it's similar with other scripts.

The uploaded file gets 0600 permissions and is not readable by the apache.

I added the N;0644; in php.ini but now I get a Upload FAILED instead Sad

/E
11-04-2007 12:06 AM
Find all posts by this user Quote this message in a reply
rbtux Offline
Moderator
*****
Moderators

Posts: 1,847
Joined: Feb 2007
Reputation: 33
Post: #6
RE: PHP uploads are not readable
well then tis works only for the session save path... what a pity^^
11-04-2007 12:09 AM
Visit this user's website Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #7
RE: PHP uploads are not readable
Eminos Wrote:
joximu Wrote:with mod_php the mode of an uploaded file is 0600
with fastcgi the same - but the user/owner is another one.

Yes, but isn't that wrong? It should be 644 right ?
Coz this used to work with older versions of ISPCP.

/E

it's 0600 with mod_php (on my suse server) - so this seems to me as a default.

Which version of ispcp worked for you?

/J
11-04-2007 03:57 AM
Visit this user's website Find all posts by this user Quote this message in a reply
Eminos Offline
Junior Member
*

Posts: 159
Joined: Jan 2007
Reputation: 0
Post: #8
RE: PHP uploads are not readable
joximu Wrote:Which version of ispcp worked for you?

Hmm, I think RC2c or some nightly before that. I'm not sure tho.
But I know that me (and my customers) didn't have this problem when uploading pictures with Joomla.
I'm now using a month old nightly.

/E
11-04-2007 04:07 AM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #9
RE: PHP uploads are not readable
Well, it would help alot if we could locate the differences in the php settings from then to now.
11-04-2007 10:36 AM
Visit this user's website Find all posts by this user Quote this message in a reply
Eminos Offline
Junior Member
*

Posts: 159
Joined: Jan 2007
Reputation: 0
Post: #10
RE: PHP uploads are not readable
Tell me how I could help. I don't have the old server installation anymore.

/E
11-04-2007 11:49 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 2 Guest(s)