From afacbf004aaee146bef9a7b34d4cad4fc2fa994a Mon Sep 17 00:00:00 2001 From: iarenaza Date: Tue, 30 Jun 2009 23:33:11 +0000 Subject: [PATCH] CAS authentication: MDL-19671 phpCAS::getUser can return a mixed-case username, so lower-case it for comparison. Merged from MOODLE_18_STABLE --- auth/cas/auth.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/auth/cas/auth.php b/auth/cas/auth.php index 919e84bfae..b85fc861d6 100644 --- a/auth/cas/auth.php +++ b/auth/cas/auth.php @@ -59,7 +59,7 @@ class auth_plugin_cas extends auth_plugin_base { */ function user_login ($username, $password) { $this->connectCAS(); - return phpCAS::isAuthenticated() && (phpCAS::getUser() == $username); + return phpCAS::isAuthenticated() && (trim(moodle_strtolower(phpCAS::getUser())) == $username); } /** * Returns true if this authentication plugin is 'internal'. -- 2.39.5