Forum Moderators: coopster

Message Too Old, No Replies

Creating a file on Windows Server?

fopen(), Windows Server, create file, write permission

         

andy_broom

10:21 am on Mar 30, 2009 (gmt 0)

10+ Year Member



Hi,

I am trying to write/create a new file into a directory on a Windows Server. I have been told that enabling write permissions on a folder is not a good idea for security reasons.

Does anyone know a better way to go about this? Is there a way to specify the user, in the script, as the owner of the folder so enabling the script to write files to the folder whilst other users, 'nobody', are still write disabled. I'm thinking along the lines of how we connect to a database if that makes sense? something like fopen('path-to-file', '$username');?

Any suggestioins appreciated.

Cheers,

Andy

coopster

7:46 pm on Apr 7, 2009 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Without proper permissions you will not be able to write a file to your filesystem. Open source CMS are built upon this premise, Joomla being one of many. Just lock it down tight, carefully manage who can upload what and where and reject anything except for that which you expect.