Ticket #1871: 1871.patch
File 1871.patch, 2.3 KB (added by , 15 years ago) |
---|
-
editor/filemanager/connectors/php/commands.php
219 219 220 220 if ( is_file( $sFilePath ) ) 221 221 { 222 if ( isset( $Config['ChmodOnUpload'] ) && !$Config['ChmodOnUpload'] ) 223 { 224 break ; 225 } 226 227 $permissions = 0777; 228 229 if ( isset( $Config['ChmodOnUpload'] ) && $Config['ChmodOnUpload'] ) 230 { 231 $permissions = $Config['ChmodOnUpload'] ; 232 } 233 222 234 $oldumask = umask(0) ; 223 chmod( $sFilePath, 0777) ;235 chmod( $sFilePath, $permissions ) ; 224 236 umask( $oldumask ) ; 225 237 } 226 238 -
editor/filemanager/connectors/php/config.php
47 47 // following setting enabled. 48 48 $Config['ForceSingleExtension'] = true ; 49 49 50 // Perform additional checks for image files 51 // if set to true, validate image size (using getimagesize)50 // Perform additional checks for image files. 51 // If set to true, validate image size (using getimagesize). 52 52 $Config['SecureImageUploads'] = true; 53 53 54 // What the user can do with this connector 54 // What the user can do with this connector. 55 55 $Config['ConfigAllowedCommands'] = array('QuickUpload', 'FileUpload', 'GetFolders', 'GetFoldersAndFiles', 'CreateFolder') ; 56 56 57 // Allowed Resource Types 57 // Allowed Resource Types. 58 58 $Config['ConfigAllowedTypes'] = array('File', 'Image', 'Flash', 'Media') ; 59 59 60 60 // For security, HTML is allowed in the first Kb of data for files having the 61 61 // following extensions only. 62 62 $Config['HtmlExtensions'] = array("html", "htm", "xml", "xsd", "txt", "js") ; 63 63 64 // After file is uploaded, sometimes it is required to change its permissions 65 // so that it was possible to access it at the later time. 66 // If possible, it is recommended to set more restrictive permissions, like 0755. 67 // Set to 0 to disable this feature. 68 // Note: not needed on Windows-based servers. 69 $Config['ChmodOnUpload'] = 0777 ; 64 70 /* 65 71 Configuration settings for each Resource Type 66 72