fopen() security


Posted on 16th Feb 2014 07:03 pm by admin

As i understood the usage of fopen() for it to function correctly the Dir you write to has to be rw enabled for the php group, so that fopen() can acces the Dir to write to it.

When I try to write to the Dir that has permissions 666 I get the error "Permission Denied". If I try to write to the Dir and the permissions are set to 777 read/ write/ecexute for every one everything works as intended and fopen() write to the dir normally.

Did you know?Explore Trending and Topic pages for more stories like this.
My question:
Why does a folder have to be executable for php to write to it using fopen()?

(using up to date versions of Lamp on Debian Lenny 64-bit)
No comments posted yet

Your Answer:

Login to answer
344 Like 9 Dislike
Previous forums Next forums
Other forums

MFC GUI Programming
I am working on a project right now that requires me to create a MFC Windows GUI. Basically it need

Problem with creating FI documents
Hi, Experts!

when i create Fi doc. with standart transaction, i ve been had such problem

Creating Images from images in PHP
Okay well I am trying to make a 'dynamic' calender image with PHP.

I have images like this:

Is there a way to override built in php functions without APD?
I am trying to use the
rename_function()
override_function()
options that are built into

Problem with PHP code- simple contact form
I'm relativily new to PHP; I know HTML and CSS stuff but I have a problem- I have a contact form wit

php code generators
All

Whilst enjoying learning a new language i have come accross a number of free code generat

Allowing ' and "
Hello everyone,

I am creating a form where users submit information to go into a database. I

Keeping data in form
How can I keep whatever I write in the form?

Working with Global Variables
hi, I'm not really sure why the following code is returning a "Call to a member function getBan

Log $_POST
How would i log submits on a form, by everyone? I want to then echo the number of submissions.

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash