Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
* added umask check
Signed-off-by: Björn Gottschall <[email protected]>
  • Loading branch information
Björn Gottschall committed Mar 18, 2022
commit 64060bd8721fe45e24c3b0ca8d155031dff4822c
10 changes: 10 additions & 0 deletions apps/settings/lib/Controller/CheckSetupController.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
* @author Timo Förster <[email protected]>
* @author Valdnet <[email protected]>
* @author MichaIng <[email protected]>
* @author Björn Gottschall <[email protected]>
*
* @license AGPL-3.0
*
Expand Down Expand Up @@ -793,6 +794,14 @@ protected function imageMagickLacksSVGSupport(): bool {
return extension_loaded('imagick') && count(\Imagick::queryFormats('SVG')) === 0;
}

/**
* Checks if the process umask has owner read/write/execute permissions
* @return bool
*/
protected function hasRecommendedUMask(): bool {
return ((umask() & 0700) === 0700);
}

/**
* @return DataResponse
* @AuthorizedAdminSetting(settings=OCA\Settings\Settings\Admin\Overview)
Expand Down Expand Up @@ -850,6 +859,7 @@ public function check() {
'isDefaultPhoneRegionSet' => $this->config->getSystemValueString('default_phone_region', '') !== '',
SupportedDatabase::class => ['pass' => $supportedDatabases->run(), 'description' => $supportedDatabases->description(), 'severity' => $supportedDatabases->severity()],
'temporaryDirectoryWritable' => $this->isTemporaryDirectoryWritable(),
'hasRecommendedUMask' => $this->hasRecommendedUMask(),
]
);
}
Expand Down