Jump to content

file write permissions


raman

Recommended Posts

I have a php script in which I get the user input from textbox and write it to a file or upload the file. For this I have created a folder called uploadfolder with path "/usr/local/apache2/htdocs/mywebdirectory/uploadfolder" where a user directory is created for every user and then chmod 777 is executed on that directory. I wish to have some other alternative for this because this is a security risk.

 

Also in my PHP script, I run a perl script on the uploaded file in which I have to copy the uploaded file into the main directory "/usr/local/apache2/htdocs/mywebdirectory/", but this is not possible without write permissions on the main web directory. My perl script is such that it can be run from the current directory only, which is the main web directory here. What should I do ?

Link to comment
https://forums.phpfreaks.com/topic/156680-file-write-permissions/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.