Merge pull request #5422 from owncloud/fix_logfile_permissions

the logfile shoudn't be world readable.
This commit is contained in:
Frank Karlitschek 2013-10-18 09:10:24 -07:00
commit e6d13468d3
1 changed files with 1 additions and 0 deletions

View File

@ -61,6 +61,7 @@ class OC_Log_Owncloud {
$entry=array('app'=>$app, 'message'=>$message, 'level'=>$level, 'time'=> $time->format($format));
$entry = json_encode($entry);
$handle = @fopen(self::$logFile, 'a');
@chmod(self::$logFile, 0640);
if ($handle) {
fwrite($handle, $entry."\n");
fclose($handle);