From 2aa04c52307da8a9b1324805007a5ed7f0481cae Mon Sep 17 00:00:00 2001 From: Tim van Dijen Date: Sat, 30 Jan 2021 11:56:01 +0100 Subject: [PATCH] Do not tie debug mode to SSP debug logging --- config-templates/module_webauthn.php | 3 +++ www/authprocess.php | 4 ++-- www/regprocess.php | 4 ++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/config-templates/module_webauthn.php b/config-templates/module_webauthn.php index 1a763d6..944f03c 100644 --- a/config-templates/module_webauthn.php +++ b/config-templates/module_webauthn.php @@ -1,6 +1,9 @@ false, + /* required configuration parameters */ 'store' => [ 'webauthn:Database', diff --git a/www/authprocess.php b/www/authprocess.php index a313fe5..6abba62 100644 --- a/www/authprocess.php +++ b/www/authprocess.php @@ -21,8 +21,8 @@ ); } -$config = Configuration::getInstance(); -$debugEnabled = $config->getValue('logging.level', Logger::NOTICE) === Logger::DEBUG; +$moduleConfig = Configuration::getOptionalConfig('module_webauthn.php'); +$debugEnabled = $moduleConfig->getBoolean('debug', false); $id = $_REQUEST['StateId']; /** @var array $state */ diff --git a/www/regprocess.php b/www/regprocess.php index 6ac6a6c..a998d27 100644 --- a/www/regprocess.php +++ b/www/regprocess.php @@ -21,8 +21,8 @@ ); } -$config = Configuration::getInstance(); -$debugEnabled = $config->getValue('logging.level', Logger::NOTICE) === Logger::DEBUG; +$moduleConfig = Configuration::getOptionalConfig('module_webauthn.php'); +$debugEnabled = $moduleConfig->getBoolean('debug', false); $id = $_REQUEST['StateId']; /** @var array $state */