summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2024-04-17 22:01:47 -0100
committerMaxence Lange <maxence@artificial-owl.com>2024-04-17 22:01:47 -0100
commit99968efe7b0f39caed5eea8220e7b2490ca5fadc (patch)
tree621589115d6b3e8e0dc8889e63ab29c019c075e3 /lib
parent053cb7455b270cd35d7797be6874abf7ffb6c22b (diff)
downloadnextcloud-server-99968efe7b0f39caed5eea8220e7b2490ca5fadc.tar.gz
nextcloud-server-99968efe7b0f39caed5eea8220e7b2490ca5fadc.zip
fix(appconfig): returns correct value on details
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/AppConfig.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/private/AppConfig.php b/lib/private/AppConfig.php
index 5d753a6ee9c..ccd07b1c20a 100644
--- a/lib/private/AppConfig.php
+++ b/lib/private/AppConfig.php
@@ -1032,14 +1032,20 @@ class AppConfig implements IAppConfig {
throw new AppConfigUnknownKeyException('unknown config key');
}
+ $value = $cache[$app][$key];
+ $sensitive = $this->isSensitive($app, $key, null);
+ if ($sensitive && str_starts_with($value, self::ENCRYPTION_PREFIX)) {
+ $value = $this->crypto->decrypt(substr($value, self::ENCRYPTION_PREFIX_LENGTH));
+ }
+
return [
'app' => $app,
'key' => $key,
- 'value' => $cache[$app][$key],
+ 'value' => $value,
'type' => $type,
'lazy' => $lazy,
'typeString' => $typeString,
- 'sensitive' => $this->isSensitive($app, $key, null)
+ 'sensitive' => $sensitive
];
}