diff --git a/lib/SimpleSAML/Locale/Translate.php b/lib/SimpleSAML/Locale/Translate.php index ebbac327575e74acf27c6274234ebf8ce02bf190..dba41a86af314eafc29b9d1d45d77d57f43e5707 100644 --- a/lib/SimpleSAML/Locale/Translate.php +++ b/lib/SimpleSAML/Locale/Translate.php @@ -56,7 +56,7 @@ class Translate // for backwards compatibility - print warning $backtrace = debug_backtrace(); $where = $backtrace[0]['file'].':'.$backtrace[0]['line']; - \SimpleSAML_Logger::warning( + \SimpleSAML\Logger::warning( 'Deprecated use of new SimpleSAML\Locale\Translate(...) at '.$where. '. The last parameter is now a dictionary name, which should not end in ".php".' ); @@ -96,7 +96,7 @@ class Translate if ($sepPos !== false) { $module = substr($name, 0, $sepPos); $fileName = substr($name, $sepPos + 1); - $dictDir = \SimpleSAML_Module::getModuleDir($module).'/dictionaries/'; + $dictDir = \SimpleSAML\Module::getModuleDir($module).'/dictionaries/'; } else { $dictDir = $this->configuration->getPathValue('dictionarydir', 'dictionaries/'); $fileName = $name; @@ -255,14 +255,14 @@ class Translate // old style call to t(...). Print warning to log $backtrace = debug_backtrace(); $where = $backtrace[0]['file'].':'.$backtrace[0]['line']; - \SimpleSAML_Logger::warning( + \SimpleSAML\Logger::warning( 'Deprecated use of SimpleSAML_Template::t(...) at '.$where. '. Please update the code to use the new style of parameters.' ); // for backwards compatibility if (!$replacements && $this->getTag($tag) === null) { - \SimpleSAML_Logger::warning( + \SimpleSAML\Logger::warning( 'Code which uses $fallbackdefault === FALSE should be updated to use the getTag() method instead.' ); return null; @@ -277,7 +277,7 @@ class Translate $tagData = $this->getTag($tag); if ($tagData === null) { // tag not found - \SimpleSAML_Logger::info('Template: Looking up ['.$tag.']: not translated at all.'); + \SimpleSAML\Logger::info('Template: Looking up ['.$tag.']: not translated at all.'); return $this->getStringNotTranslated($tag, $fallbackdefault); } } @@ -332,7 +332,7 @@ class Translate throw new \Exception("Inline translation should be string or array. Is ".gettype($translation)." now!"); } - \SimpleSAML_Logger::debug('Template: Adding inline language translation for tag ['.$tag.']'); + \SimpleSAML\Logger::debug('Template: Adding inline language translation for tag ['.$tag.']'); $this->langtext[$tag] = $translation; } @@ -355,7 +355,7 @@ class Translate } $lang = $this->readDictionaryFile($filebase.$file); - \SimpleSAML_Logger::debug('Template: Merging language array. Loading ['.$file.']'); + \SimpleSAML\Logger::debug('Template: Merging language array. Loading ['.$file.']'); $this->langtext = array_merge($this->langtext, $lang); } @@ -376,7 +376,7 @@ class Translate $lang = json_decode($fileContent, true); if (empty($lang)) { - \SimpleSAML_Logger::error('Invalid dictionary definition file ['.$definitionFile.']'); + \SimpleSAML\Logger::error('Invalid dictionary definition file ['.$definitionFile.']'); return array(); } @@ -426,7 +426,7 @@ class Translate { assert('is_string($filename)'); - \SimpleSAML_Logger::debug('Template: Reading ['.$filename.']'); + \SimpleSAML\Logger::debug('Template: Reading ['.$filename.']'); $jsonFile = $filename.'.definition.json'; if (file_exists($jsonFile)) { @@ -438,7 +438,7 @@ class Translate return $this->readDictionaryPHP($filename); } - \SimpleSAML_Logger::error( + \SimpleSAML\Logger::error( $_SERVER['PHP_SELF'].' - Template: Could not find dictionary file at ['.$filename.']' ); return array(); diff --git a/lib/SimpleSAML/XHTML/Template.php b/lib/SimpleSAML/XHTML/Template.php index 8214ac154b320f5d905617bc17706543fdfd0b68..8f895261b60a38d473b75f313dc4b169b56b48b4 100644 --- a/lib/SimpleSAML/XHTML/Template.php +++ b/lib/SimpleSAML/XHTML/Template.php @@ -118,11 +118,11 @@ class SimpleSAML_XHTML_Template if ($themeModule !== null) { // .../module/<themeModule>/themes/<themeName>/<templateModule>/<templateName> - $filename = SimpleSAML_Module::getModuleDir($themeModule). + $filename = SimpleSAML\Module::getModuleDir($themeModule). '/themes/'.$themeName.'/'.$templateModule.'/'.$templateName; } elseif ($templateModule !== 'default') { // .../module/<templateModule>/templates/<themeName>/<templateName> - $filename = SimpleSAML_Module::getModuleDir($templateModule).'/templates/'.$templateName; + $filename = SimpleSAML\Module::getModuleDir($templateModule).'/templates/'.$templateName; } else { // .../templates/<theme>/<templateName> $filename = $this->configuration->getPathValue('templatedir', 'templates/').$templateName; @@ -133,7 +133,7 @@ class SimpleSAML_XHTML_Template } // not found in current theme - SimpleSAML_Logger::debug( + SimpleSAML\Logger::debug( $_SERVER['PHP_SELF'].' - Template: Could not find template file ['. $template.'] at ['. $filename.'] - now trying the base template' ); @@ -141,7 +141,7 @@ class SimpleSAML_XHTML_Template // try default theme if ($templateModule !== 'default') { // .../module/<templateModule>/templates/<templateName> - $filename = SimpleSAML_Module::getModuleDir($templateModule).'/templates/'.$templateName; + $filename = SimpleSAML\Module::getModuleDir($templateModule).'/templates/'.$templateName; } else { // .../templates/<templateName> $filename = $this->configuration->getPathValue('templatedir', 'templates/').'/'.$templateName; @@ -153,7 +153,7 @@ class SimpleSAML_XHTML_Template // not found in default template - log error and throw exception $error = 'Template: Could not find template file ['.$template.'] at ['.$filename.']'; - SimpleSAML_Logger::critical($_SERVER['PHP_SELF'].' - '.$error); + SimpleSAML\Logger::critical($_SERVER['PHP_SELF'].' - '.$error); throw new Exception($error); } diff --git a/modules/authwindowslive/lib/Auth/Source/LiveID.php b/modules/authwindowslive/lib/Auth/Source/LiveID.php index c52505a4417ae3755b165dcbb9da7e840ab0c812..8de392c22831c05dd53820bcdf323b8e07a8a4c7 100644 --- a/modules/authwindowslive/lib/Auth/Source/LiveID.php +++ b/modules/authwindowslive/lib/Auth/Source/LiveID.php @@ -77,7 +77,7 @@ class sspmod_authwindowslive_Auth_Source_LiveID extends SimpleSAML_Auth_Source . '?client_id=' . $this->key . '&response_type=code' . '&response_mode=query' - . '&redirect_uri=' . urlencode(SimpleSAML_Module::getModuleUrl('authwindowslive') . '/linkback.php') + . '&redirect_uri=' . urlencode(SimpleSAML\Module::getModuleUrl('authwindowslive') . '/linkback.php') . '&state=' . urlencode($stateID) . '&scope=' . urlencode('openid https://graph.microsoft.com/user.read') ; @@ -104,7 +104,7 @@ class sspmod_authwindowslive_Auth_Source_LiveID extends SimpleSAML_Auth_Source . '&client_secret=' . urlencode($this->secret) . '&scope=' . urlencode('https://graph.microsoft.com/user.read') . '&grant_type=authorization_code' - . '&redirect_uri=' . urlencode(SimpleSAML_Module::getModuleUrl('authwindowslive') . '/linkback.php') + . '&redirect_uri=' . urlencode(SimpleSAML\Module::getModuleUrl('authwindowslive') . '/linkback.php') . '&code=' . urlencode($state['authwindowslive:verification_code']); $context = array( diff --git a/modules/core/lib/Stats/Output/Log.php b/modules/core/lib/Stats/Output/Log.php index 9c50dfad6f1d04c01dfd7589631b9c2d9dc7303e..70e914e4bb4316cb4d2b83a1a4370e6b68175f29 100644 --- a/modules/core/lib/Stats/Output/Log.php +++ b/modules/core/lib/Stats/Output/Log.php @@ -22,7 +22,7 @@ class sspmod_core_Stats_Output_Log extends SimpleSAML_Stats_Output { public function __construct(SimpleSAML_Configuration $config) { $logLevel = $config->getString('level', 'notice'); - $this->logger = array('SimpleSAML_Logger', $logLevel); + $this->logger = array('SimpleSAML\Logger', $logLevel); if (!is_callable($this->logger)) { throw new Exception('Invalid log level: ' . var_export($logLevel, TRUE)); } diff --git a/modules/negotiate/docs/negotiate.md b/modules/negotiate/docs/negotiate.md index 62ae6f52c3e4736120940f5c244611a09972e2e5..a57044de9bb5f059a1c0767b5751c5c29f95c7b4 100644 --- a/modules/negotiate/docs/negotiate.md +++ b/modules/negotiate/docs/negotiate.md @@ -227,7 +227,7 @@ if($this->data['nego']['disable_perm']) { echo '<span id="login-extra-info-uio.no" class="login-extra-info">' . '<span class="login-extra-info-divider"></span>' . $this->t('{feide:login:login_uio_negotiate_disabled_session_info}') - . '<br><a href="'.SimpleSAML_Module::getModuleURL('negotiate/retry.php', array('AuthState' => $this->data['nego']['retry_id'])).'">' + . '<br><a href="'.SimpleSAML\Module::getModuleURL('negotiate/retry.php', array('AuthState' => $this->data['nego']['retry_id'])).'">' . $this->t('{feide:login:login_uio_negotiate_disabled_session_info_link}') . '</a>' . '</span>';