function _init_cas_client() { global $prefs; // just make sure we're supposed to be here if ($prefs['auth_method'] != 'cas') { return false; } if (self::$cas_initialized === false) { // initialize phpCAS phpCAS::client($prefs['cas_version'], '' . $prefs['cas_hostname'], (int) $prefs['cas_port'], '' . $prefs['cas_path'], false); self::$cas_initialized = true; } return true; }