Running ColdFusion 10 currently, but this has been an ongoing issue for years, perhaps throughout CF6/7.
As part of a CMS, part of the validation is that the images are uploaded to a directory e.g.
<cffile action="UPLOAD" filefield="image" destination="media/img/" nameconflict="MAKEUNIQUE" accept="image/jpeg,image/gif,image/pjpeg" mode="644">
They are then read by a script which checks dimensions.
If everything passes, the process script moves it to it's destination directory e.g.
<cffile action="MOVE" source="media/img/imagename" destination="media/img/#hexdir#/imagename" mode="644">
If it fails it should be deleted.
<cffile action="DELETE" file="media/img/imagename">
Every once in a while the /img/ directory becomes read only, the file cannot be written. But I cannot identify the cause of this.
Is there a bug that I am not aware of? any ideas?
Thanks
Additional information
I considered using CFDirectory to change the folder permission in a script, so it can be quickly resolved if it happens again.
I found two issues
On UNIX and Linux, cfdirectory action = "list" does not return any information in the mode column.
Also
Using the rename folder with permissions of 644,777,111 do not seem to affect the permissions of the folder that I can view in FileZilla.
Could this mean that CF could not have changed the folder permission in the first place?