25 include_once(
'Auth/Auth.php');
56 #$_POST['username'] = utf8_decode($_POST['username']);
57 $_POST[
'password'] = utf8_decode($_POST[
'password']);
58 $this->log->write(__METHOD__.
': Decoded username and password to latin1.');
60 if(is_array($a_options))
62 $options = array_merge($this->radius_settings->toPearAuthArray(),$a_options);
66 $options = $this->radius_settings->toPearAuthArray();
70 parent::Auth(
'RADIUS',$options,
'',
false);
85 $this->force_creation =
true;
96 $user_data = array_change_key_case($this->getAuthData(),CASE_LOWER);
100 if(!$user_data[
'ilInternalAccount'])
102 if($this->radius_settings->enabledCreation())
108 $_SESSION[
'tmp_external_account'] = $a_username;
109 $_SESSION[
'tmp_pass'] = $_POST[
'password'];
110 $_SESSION[
'tmp_roles'] = array(0 => $this->radius_settings->getDefaultRole());
112 ilUtil::redirect(
'ilias.php?baseClass=ilStartUpGUI&cmd=showAccountMigration&cmdClass=ilstartupgui');
115 $new_name = $this->radius_user->create($a_username);
116 $this->setAuth($new_name);
130 $this->setAuth($user_data[
'ilInternalAccount']);
142 #$this->log->write($this->logCache);
143 $this->logCache =
'';
149 include_once
'Services/Radius/classes/class.ilRadiusSettings.php';
155 include_once(
'Services/Radius/classes/class.ilRadiusAttributeToUser.php');
165 $this->setLoginCallback(array($this,
'loginObserver'));
166 $this->setFailedLoginCallback(array($this,
'failedLoginObserver'));