Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMickey Knox <mickey@netfreaks.org>2022-03-03 00:35:04 +0300
committerSimon L. (Rebase PR Action) <szaimen@e.mail.de>2022-03-08 13:17:55 +0300
commit4910724803d565547edc366dbd852202aebfb280 (patch)
treecf515db01da4392ed25c7cd620a9078a5bcf100a
parent36860214f8e960cf53a736d2a7342c612c53870b (diff)
Fix permittedPath comparison
Signed-off-by: Mickey Knox <mickey@netfreaks.org>
-rw-r--r--apps/settings/lib/Controller/CheckSetupController.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/settings/lib/Controller/CheckSetupController.php b/apps/settings/lib/Controller/CheckSetupController.php
index ebd31b3ec53..1809a47ff44 100644
--- a/apps/settings/lib/Controller/CheckSetupController.php
+++ b/apps/settings/lib/Controller/CheckSetupController.php
@@ -482,7 +482,7 @@ Raw output
// Check whether Nextcloud is allowed to use the OPcache API
$isPermitted = true;
$permittedPath = $this->iniGetWrapper->getString('opcache.restrict_api');
- if (isset($permittedPath) && $permittedPath !== '' && !str_starts_with(\OC::$SERVERROOT, $permittedPath)) {
+ if (isset($permittedPath) && $permittedPath !== '' && !str_starts_with(\OC::$SERVERROOT, rtrim($permittedPath, '/'))) {
$isPermitted = false;
}