My hosting provider has got some special security-features. My problem is now: i want to set the right filepermissions for uploaded files automaticly. E.g. when I upload a pdf into a page, it should have the permissions 0640 and not anything other.
Is there a way to tell Silverstripe for which filetypes it shout use the right permissions?
Thanks for the reply!
Changing the permissions with an FTP-Client is no problem for me, but for my clients :)
I thought that there's perhaps a config-file where I can say Silverstripe what permissions it should use for the different types of files. Independent if they are self created or uploaded.
Is there a way to set then generally?
Not sure if this has any influence when uploading files, but it certainly does when you create folders via SilverStripe.
If that doesn't work, you could create a shell script that finds and updates files with the wrong permission. Then regularly run the script as a cron-job?
Thanks, this would be the first step. Do you know, if I can also set specific permissions for php-files?
I'll try, if uploaded files are influenced by this settings. The shell-script-cron-job-sollution is not a real sollution for me, because the files, I am talking about, will be uploaded by users. And you always got to wait, until the cron-job is through, before they can access the files...
Sorry I'm just in a hurry, so my answer is quite short. But thanks a lot for the tip with the _config.php!
Hehe, good idea, but I am far away from this!!!
No, my hosting provider has some special permissions for php-files. just "r--------" (0600). Therefore I wanted it.
But my problem is solved, because I changed now to hosteurope...