From 064e1133f5e6d31dd7b52f09227ca7462c2ef9ce Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Mon, 4 Aug 2025 14:10:58 +0200 Subject: [PATCH] feat: allow admins to configure additional sensitive config values Signed-off-by: Robin Appelman --- lib/private/SystemConfig.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/private/SystemConfig.php b/lib/private/SystemConfig.php index 57777b06ed601..7e8946f4d05e0 100644 --- a/lib/private/SystemConfig.php +++ b/lib/private/SystemConfig.php @@ -15,8 +15,9 @@ * fixes cyclic DI: AllConfig needs AppConfig needs Database needs AllConfig */ class SystemConfig { - /** @var array */ - protected $sensitiveValues = [ + protected array $sensitiveValues; + + protected const DEFAULT_SENSITIVE_VALUES = [ 'instanceid' => true, 'datadirectory' => true, 'dbname' => true, @@ -114,6 +115,7 @@ class SystemConfig { public function __construct( private Config $config, ) { + $this->sensitiveValues = array_merge(self::DEFAULT_SENSITIVE_VALUES, $this->config->getValue('config_extra_sensitive_values', [])); } /**