4 require_once
'Services/TermsOfService/classes/class.ilTermsOfServiceHelper.php';
33 $this->lng->loadLanguageModule(
'auth');
36 $ilCtrl->saveParameter($this,
array(
"rep_ref_id",
"lang",
"target",
"client_id"));
45 $cmd = $this->ctrl->getCmd(
"processIndexPHP",
array(
'processIndexPHP',
'showLoginPage'));
46 $next_class = $this->ctrl->getNextClass($this);
50 case 'ilLoginPageGUI':
53 case "ilaccountregistrationgui":
54 require_once(
"Services/Registration/classes/class.ilAccountRegistrationGUI.php");
57 case "ilpasswordassistancegui":
58 require_once(
"Services/Init/classes/class.ilPasswordAssistanceGUI.php");
81 $this->ctrl->setCmdClass(
"ilaccountregistrationgui");
82 $this->ctrl->setCmd(
"");
92 $this->ctrl->setCmdClass(
"ilpasswordassistancegui");
93 $this->ctrl->setCmd(
"");
100 protected function showLoginPageOrStartupPage()
105 $auth_session =
$GLOBALS[
'DIC'][
'ilAuthSession'];
107 $force_login =
false;
109 !is_array($_REQUEST[
'cmd']) &&
110 strcmp($_REQUEST[
'cmd'],
'force_login') === 0
118 $this->logger->debug(
'Force login');
119 if($auth_session->isValid())
121 $this->logger->debug(
'Valid session -> logout current user');
123 $auth_session->logout();
125 $GLOBALS[
'ilAppEventHandler']->raise(
126 'Services/Authentication',
133 $this->logger->debug(
'Show login page');
140 if($auth_session->isValid())
142 $this->logger->debug(
'Valid session -> redirect to starting page');
143 return ilInitialisation::redirectToStartingPage();
145 $this->logger->debug(
'No valid session -> show login');
158 $this->
getLogger()->debug(
'Showing login page');
161 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendCredentialsApache.php';
163 $frontend->tryAuthenticationOnLoginPage();
166 self::initStartUpTemplate(
"tpl.login.html");
170 $page_editor_html = $this->
showLoginForm($page_editor_html, $form);
174 $page_editor_html = $this->showTermsOfServiceLink($page_editor_html);
179 $tpl->setVariable(
"PAGETITLE",
"- ".$this->lng->txt(
"startpage"));
180 $tpl->setVariable(
"ILIAS_RELEASE", $ilSetting->get(
"ilias_version"));
182 $this->ctrl->setTargetScript(
"ilias.php");
185 if(
$GLOBALS[
'DIC'][
'ilAuthSession']->isExpired())
191 if(strlen($page_editor_html))
193 $tpl->setVariable(
'LPE',$page_editor_html);
196 $tpl->fillWindowTitle();
197 $tpl->fillCssFiles();
198 $tpl->fillJavaScriptFiles();
199 $tpl->show(
"DEFAULT",
false);
212 $this->
getLogger()->warning(
'Using deprecated startup method');
215 $status = $ilAuth->getStatus();
216 if ($status ==
"" && isset(
$_GET[
"auth_stat"]))
218 $status =
$_GET[
"auth_stat"];
221 if($ilAuth->getAuth() && !$status)
224 if (
$_GET[
"rep_ref_id"] !=
"")
228 include_once
'./Services/Init/classes/class.ilInitialisation.php';
229 ilInitialisation::redirectToStartingPage();
236 if (empty(
$_GET[
'cookies']))
238 $additional_params =
'';
241 "&ext_uid=".
$_GET[
"ext_uid"].
"&cookies=nocookies&client_id=".
242 rawurlencode(CLIENT_ID).
"&lang=".$lng->getLangKey().$additional_params);
251 unset(
$_GET[
'cookies']);
254 if ($ilSetting->get(
"shib_active") && $ilSetting->get(
"shib_hos_type"))
256 require_once
"./Services/AuthShibboleth/classes/class.ilShibbolethWAYF.php";
261 if (isset($WAYF) && $WAYF->is_selection())
263 if ($WAYF->is_valid_selection())
266 $WAYF->setSAMLCookie();
276 if (isset(
$_GET[
'reg_confirmation_msg']) && strlen(trim(
$_GET[
'reg_confirmation_msg'])))
278 $lng->loadLanguageModule(
'registration');
279 if(
$_GET[
'reg_confirmation_msg'] ==
'reg_account_confirmation_successful')
288 else if(isset(
$_GET[
'reached_session_limit']) &&
$_GET[
'reached_session_limit'])
290 $failure = $lng->txt(
"reached_session_limit");
292 else if(isset(
$_GET[
'accdel']) &&
$_GET[
'accdel'])
294 $lng->loadLanguageModule(
'user');
295 $failure = $lng->txt(
"user_account_deleted_confirmation");
308 $failure = $lng->txt(
"err_session_expired");
312 $failure = $lng->txt(
"err_auth_cas_no_ilias_user");
316 $failure = $lng->txt(
"err_auth_soap_no_ilias_user");
320 $failure = $lng->txt(
"err_auth_ldap_no_ilias_user");
324 $failure = $lng->txt(
"err_auth_radius_no_ilias_user");
328 $failure = $lng->txt(
"err_auth_mode_inactive");
332 $failure = $lng->txt(
"err_auth_apache_failed");
336 $lng->loadLanguageModule(
'cptch');
340 $failure = $lng->txt(
"cptch_wrong_input");
351 $failure = sprintf($lng->txt(
'wrong_ip_detected'),
$_SERVER[
'REMOTE_ADDR']);
359 $failure = $lng->txt(
"simultaneous_login_detected");
364 $username = $ilAuth->getExceededUserName();
368 if($ilSetting->get(
'user_reactivate_code'))
375 $failure = $lng->txt(
"time_limit_reached");
383 $failure = $lng->txt(
"err_inactive");
389 case AUTH_WRONG_LOGIN:
392 $auth_error = $ilias->getAuthError();
393 if (is_object($auth_error))
395 $add =
"<br>".$auth_error->getMessage();
397 $failure = $lng->txt(
"err_wrong_login").$add;
404 $lng->loadLanguageModule(
"auth");
405 $success = $lng->txt(
"auth_account_code_used");
412 self::initStartUpTemplate(
"tpl.login.html");
431 $page_editor_html = $this->showTermsOfServiceLink($page_editor_html);
435 $tpl->setVariable(
"PAGETITLE",
"- ".$lng->txt(
"startpage"));
436 $tpl->setVariable(
"ILIAS_RELEASE", $ilSetting->get(
"ilias_version"));
438 $this->ctrl->setTargetScript(
"ilias.php");
439 $tpl->setVariable(
"PHP_SELF",
$_SERVER[
'PHP_SELF']);
442 if (isset(
$_GET[
'cookies']) &&
$_GET[
'cookies'] ==
'nocookies')
447 if(strlen($page_editor_html))
449 $tpl->setVariable(
'LPE',$page_editor_html);
452 $tpl->fillWindowTitle();
453 $tpl->fillCssFiles();
454 $tpl->fillJavaScriptFiles();
456 $tpl->show(
"DEFAULT",
false);
463 self::initStartUpTemplate(
"tpl.login_reactivate_code.html");
472 $tpl->setVariable(
"FORM", $a_form->getHTML());
473 $tpl->show(
"DEFAULT",
false);
480 $lng->loadLanguageModule(
"auth");
482 include_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
485 $form->setFormAction($ilCtrl->getFormAction($this,
'showcodeform'));
486 $form->setTitle($lng->txt(
'auth_account_code_title'));
488 $count =
new ilTextInputGUI($lng->txt(
'auth_account_code'),
'code');
490 $count->setInfo($lng->txt(
'auth_account_code_info'));
491 $form->addItem($count);
495 $uname->setValue($a_username);
496 $form->addItem($uname);
498 $form->addCommandButton(
'processCode', $lng->txt(
'send'));
517 if($uname && $form->checkInput())
519 $code = $form->getInput(
"code");
521 include_once
"Services/User/classes/class.ilAccountCode.php";
532 $invalid_code =
false;
535 if($valid_until ===
"0")
537 $user->setTimeLimitUnlimited(
true);
541 if(is_numeric($valid_until))
543 $valid_until = strtotime(
"+".$valid_until.
"days");
547 $valid_until = explode(
"-", $valid_until);
548 $valid_until = mktime(23, 59, 59, $valid_until[1],
549 $valid_until[2], $valid_until[0]);
550 if($valid_until <
time())
552 $invalid_code =
true;
558 $user->setTimeLimitUnlimited(
false);
559 $user->setTimeLimitUntil($valid_until);
565 $user->setActive(
true);
577 $ilCtrl->setParameter($this,
"cu", 1);
578 $GLOBALS[
'DIC']->language()->loadLanguageModule(
'auth');
580 $ilCtrl->redirect($this,
"showLoginPage");
584 $lng->loadLanguageModule(
"user");
585 $field = $form->getItemByPostVar(
"code");
586 $field->setAlert($lng->txt(
"user_account_code_not_valid"));
589 $form->setValuesByPost();
600 include_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
602 $form->setFormAction($this->ctrl->getFormAction($this,
''));
603 $form->setName(
"formlogin");
604 $form->setShowTopButtons(
false);
605 $form->setTitle($this->lng->txt(
"login_to_ilias"));
607 include_once
'./Services/Authentication/classes/class.ilAuthModeDetermination.php';
612 $visible_auth_methods =
array();
616 if(isset($option[
'hide_in_ui']) && $option[
'hide_in_ui'])
622 $radg->addOption($op1);
623 if (isset($option[
'checked']))
625 $radg->setValue($key);
627 $visible_auth_methods[] = $op1;
630 if(count($visible_auth_methods) == 1)
632 $first_auth_method = current($visible_auth_methods);
634 $hidden_auth_method->setValue($first_auth_method->getValue());
635 $form->addItem($hidden_auth_method);
639 $form->addItem($radg);
643 $ti =
new ilTextInputGUI($this->lng->txt(
"username"),
"username");
645 $ti->setRequired(
true);
650 $pi->setRetype(
false);
651 $pi->setSkipSyntaxCheck(
true);
653 $pi->setDisableHtmlAutoComplete(
false);
654 $pi->setRequired(
true);
657 require_once
'Services/Captcha/classes/class.ilCaptchaUtil.php';
658 if(ilCaptchaUtil::isActiveForLogin())
660 require_once
'Services/Captcha/classes/class.ilCaptchaInputGUI.php';
661 $captcha =
new ilCaptchaInputGUI($this->lng->txt(
'captcha_code'),
'captcha_code');
663 $form->addItem($captcha);
666 $form->addCommandButton(
"doStandardAuthentication", $this->lng->txt(
"log_in"));
676 $this->
getLogger()->debug(
'Trying shibboleth authentication');
678 include_once
'./Services/AuthShibboleth/classes/class.ilAuthFrontendCredentialsShibboleth.php';
680 $credentials->initFromRequest();
682 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
686 include_once
'./Services/Authentication/classes/class.ilAuthStatus.php';
689 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendFactory.php';
692 $frontend = $frontend_factory->getFrontend(
699 $frontend->authenticate();
701 switch($status->getStatus())
705 include_once
'./Services/Init/classes/class.ilInitialisation.php';
706 ilInitialisation::redirectToStartingPage();
710 return $GLOBALS[
'ilCtrl']->redirect($this,
'showAccountMigration');
714 $GLOBALS[
'ilCtrl']->redirect($this,
'showLoginPage');
730 $this->
getLogger()->debug(
'Trying cas authentication');
732 include_once
'./Services/CAS/classes/class.ilAuthFrontendCredentialsCAS.php';
735 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
739 include_once
'./Services/Authentication/classes/class.ilAuthStatus.php';
742 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendFactory.php';
745 $frontend = $frontend_factory->getFrontend(
752 $frontend->authenticate();
753 switch($status->getStatus()) {
755 $this->
getLogger()->debug(
'Authentication successful.');
756 ilInitialisation::redirectToStartingPage();
773 $this->
getLogger()->debug(
'Trying apache authentication');
775 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendCredentialsApache.php';
777 $credentials->initFromRequest();
779 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
783 include_once
'./Services/Authentication/classes/class.ilAuthStatus.php';
786 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendFactory.php';
789 $frontend = $frontend_factory->getFrontend(
796 $frontend->authenticate();
798 switch($status->getStatus())
802 if($credentials->hasValidTargetUrl())
808 require_once
'./Services/Init/classes/class.ilInitialisation.php';
809 ilInitialisation::redirectToStartingPage();
814 return $GLOBALS[
'ilCtrl']->redirect($this,
'showAccountMigration');
820 $GLOBALS[
'ilCtrl']->getLinkTarget($this,
'showLoginPage',
'',
false,
false),
838 if($form->checkInput())
840 $this->
getLogger()->debug(
'Trying to authenticate user.');
842 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendCredentials.php';
844 $credentials->setUsername($form->getInput(
'username'));
845 $credentials->setPassword($form->getInput(
'password'));
846 $credentials->setCaptchaCode($form->getInput(
'captcha_code'));
849 include_once
'./Services/Authentication/classes/class.ilAuthModeDetermination.php';
853 $credentials->setAuthMode($form->getInput(
'auth_mode'));
856 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
858 $providers = $provider_factory->getProviders($credentials);
860 include_once
'./Services/Authentication/classes/class.ilAuthStatus.php';
863 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendFactory.php';
866 $frontend = $frontend_factory->getFrontend(
873 $frontend->authenticate();
875 switch($status->getStatus())
879 include_once
'./Services/Init/classes/class.ilInitialisation.php';
880 ilInitialisation::redirectToStartingPage();
887 return $GLOBALS[
'ilCtrl']->redirect($this,
'showAccountMigration');
918 $ilSetting->get(
"shib_auth_allow_local")) &&
919 $ilSetting->get(
"auth_mode") !=
AUTH_CAS)
935 return $page_editor_html;
947 if(strlen($page_editor_html))
950 return $page_editor_html;
953 $loginSettings =
new ilSetting(
"login_settings");
954 $information = $loginSettings->get(
"login_message_".$lng->getLangKey());
956 if(strlen(trim($information)))
958 $tpl->setVariable(
"TXT_LOGIN_INFORMATION", $information);
960 return $page_editor_html;
975 if ($ilSetting->get(
"cas_active"))
977 $tpl =
new ilTemplate(
'tpl.login_form_cas.html',
true,
true,
'Services/Init');
978 $tpl->setVariable(
"TXT_CAS_LOGIN", $lng->txt(
"login_to_ilias_via_cas"));
980 $tpl->setVariable(
"TXT_CAS_LOGIN_INSTRUCTIONS", $ilSetting->get(
"cas_login_instructions"));
981 $this->ctrl->setParameter($this,
"forceCASLogin",
"1");
982 $tpl->setVariable(
"TARGET_CAS_LOGIN",$this->ctrl->getLinkTarget($this,
"doCasAuthentication"));
983 $this->ctrl->setParameter($this,
"forceCASLogin",
"");
989 '[list-cas-login-form]',
993 return $page_editor_html;
1009 if ($ilSetting->get(
"shib_active")) {
1010 $tpl =
new ilTemplate(
'tpl.login_form_shibboleth.html',
true,
true,
'Services/Init');
1012 $tpl->setVariable(
'SHIB_FORMACTION',
'./shib_login.php');
1014 if ($ilSetting->get(
"shib_hos_type") ==
'external_wayf') {
1015 $tpl->setCurrentBlock(
"shibboleth_login");
1016 $tpl->setVariable(
"TXT_SHIB_LOGIN", $lng->txt(
"login_to_ilias_via_shibboleth"));
1017 $tpl->setVariable(
"IL_TARGET",
$_GET[
"target"]);
1018 $tpl->setVariable(
"TXT_SHIB_FEDERATION_NAME", $ilSetting->get(
"shib_federation_name"));
1019 $tpl->setVariable(
"TXT_SHIB_LOGIN_BUTTON", $ilSetting->get(
"shib_login_button"));
1020 $tpl->setVariable(
"TXT_SHIB_LOGIN_INSTRUCTIONS", sprintf($lng->txt(
"shib_general_login_instructions"), $ilSetting->get(
"shib_federation_name")) .
' <a href="mailto:' . $ilSetting->get(
"admin_email") .
'">ILIAS ' . $lng->txt(
"administrator") .
'</a>.');
1021 $tpl->setVariable(
"TXT_SHIB_CUSTOM_LOGIN_INSTRUCTIONS", $ilSetting->get(
"shib_login_instructions"));
1022 $tpl->parseCurrentBlock();
1023 } elseif ($ilSetting->get(
"shib_hos_type") ==
'embedded_wayf') {
1024 $tpl->setCurrentBlock(
"shibboleth_custom_login");
1025 $customInstructions = stripslashes($ilSetting->get(
"shib_login_instructions"));
1026 $tpl->setVariable(
"TXT_SHIB_CUSTOM_LOGIN_INSTRUCTIONS", $customInstructions);
1027 $tpl->parseCurrentBlock();
1029 $tpl->setCurrentBlock(
"shibboleth_wayf_login");
1030 $tpl->setVariable(
"TXT_SHIB_LOGIN", $lng->txt(
"login_to_ilias_via_shibboleth"));
1031 $tpl->setVariable(
"TXT_SHIB_FEDERATION_NAME", $ilSetting->get(
"shib_federation_name"));
1032 $tpl->setVariable(
"TXT_SELECT_HOME_ORGANIZATION", sprintf($lng->txt(
"shib_select_home_organization"), $ilSetting->get(
"shib_federation_name")));
1033 $tpl->setVariable(
"TXT_CONTINUE", $lng->txt(
"btn_next"));
1034 $tpl->setVariable(
"TXT_SHIB_HOME_ORGANIZATION", $lng->txt(
"shib_home_organization"));
1035 $tpl->setVariable(
"TXT_SHIB_LOGIN_INSTRUCTIONS", $lng->txt(
"shib_general_wayf_login_instructions") .
' <a href="mailto:' . $ilSetting->get(
"admin_email") .
'">ILIAS ' . $lng->txt(
"administrator") .
'</a>.');
1036 $tpl->setVariable(
"TXT_SHIB_CUSTOM_LOGIN_INSTRUCTIONS", $ilSetting->get(
"shib_login_instructions"));
1038 require_once
"./Services/AuthShibboleth/classes/class.ilShibbolethWAYF.php";
1041 $tpl->setVariable(
"TXT_SHIB_INVALID_SELECTION", $WAYF->showNotice());
1042 $tpl->setVariable(
"SHIB_IDP_LIST", $WAYF->generateSelection());
1043 $tpl->setVariable(
"ILW_TARGET",
$_GET[
"target"]);
1044 $tpl->parseCurrentBlock();
1050 return $page_editor_html;
1065 if(!strlen($page_editor_html))
1067 $tpl->setVariable($fallback_tplvar,$element_html);
1068 return $page_editor_html;
1071 if(!stristr($page_editor_html, $placeholder))
1073 $tpl->setVariable($fallback_tplvar,$element_html);
1074 return $page_editor_html;
1076 return str_replace($placeholder, $element_html, $page_editor_html);
1087 include_once
'./Services/Authentication/classes/class.ilAuthLoginPageEditorSettings.php';
1089 $active_lang = $lpe->getIliasEditorLanguage($lng->getLangKey());
1097 include_once
'./Services/COPage/classes/class.ilPageUtil.php';
1103 include_once
'./Services/Authentication/classes/class.ilLoginPage.php';
1104 include_once
'./Services/Authentication/classes/class.ilLoginPageGUI.php';
1106 include_once(
"./Services/Style/Content/classes/class.ilObjStyleSheet.php");
1108 $tpl->setCurrentBlock(
"SyntaxStyle");
1110 $tpl->parseCurrentBlock();
1115 include_once(
"./Services/Style/Content/classes/class.ilObjStyleSheet.php");
1116 $page_gui->setStyleId(0,
'auth');
1118 $page_gui->setPresentationTitle(
"");
1119 $page_gui->setTemplateOutput(
false);
1120 $page_gui->setHeader(
"");
1121 $ret = $page_gui->showPage();
1138 $rtpl =
new ilTemplate(
'tpl.login_registration_links.html',
true,
true,
'Services/Init');
1141 include_once
'Services/Registration/classes/class.ilRegistrationSettings.php';
1144 $rtpl->setCurrentBlock(
"new_registration");
1145 $rtpl->setVariable(
"REGISTER", $lng->txt(
"registration"));
1146 $rtpl->setVariable(
"CMD_REGISTER",
1147 $this->ctrl->getLinkTargetByClass(
"ilaccountregistrationgui",
""));
1148 $rtpl->parseCurrentBlock();
1151 if ($ilSetting->get(
"password_assistance"))
1153 $rtpl->setCurrentBlock(
"password_assistance");
1154 $rtpl->setVariable(
"FORGOT_PASSWORD", $lng->txt(
"forgot_password"));
1155 $rtpl->setVariable(
"FORGOT_USERNAME", $lng->txt(
"forgot_username"));
1156 $rtpl->setVariable(
"CMD_FORGOT_PASSWORD",
1157 $this->ctrl->getLinkTargetByClass(
"ilpasswordassistancegui",
""));
1158 $rtpl->setVariable(
"CMD_FORGOT_USERNAME",
1159 $this->ctrl->getLinkTargetByClass(
"ilpasswordassistancegui",
"showUsernameAssistanceForm"));
1160 $rtpl->setVariable(
"LANG_ID", $lng->getLangKey());
1161 $rtpl->parseCurrentBlock();
1164 if ($ilSetting->get(
"pub_section") &&
1165 $ilAccess->checkAccessOfUser(ANONYMOUS_USER_ID,
"read",
"", ROOT_FOLDER_ID))
1167 $rtpl->setCurrentBlock(
"homelink");
1168 $rtpl->setVariable(
"CLIENT_ID",
"?client_id=".
$_COOKIE[
"ilClientId"].
"&lang=".$lng->getLangKey());
1169 $rtpl->setVariable(
"TXT_HOME",$lng->txt(
"home"));
1170 $rtpl->parseCurrentBlock();
1173 if ($ilIliasIniFile->readVariable(
"clients",
"list"))
1175 $rtpl->setCurrentBlock(
"client_list");
1176 $rtpl->setVariable(
"TXT_CLIENT_LIST", $lng->txt(
"to_client_list"));
1177 $rtpl->setVariable(
"CMD_CLIENT_LIST",$this->ctrl->getLinkTarget($this,
"showClientList"));
1178 $rtpl->parseCurrentBlock();
1185 '[list-registration-link]',
1186 'REG_PWD_CLIENT_LINKS' 1195 protected function showTermsOfServiceLink($page_editor_html)
1203 require_once
'Services/TermsOfService/classes/class.ilTermsOfServiceSignableDocumentFactory.php';
1207 $utpl =
new ilTemplate(
'tpl.login_terms_of_service_link.html',
true,
true,
'Services/Init');
1208 $utpl->setVariable(
'TXT_TERMS_OF_SERVICE', $lng->txt(
'usr_agreement'));
1209 $utpl->setVariable(
'LINK_TERMS_OF_SERVICE', $this->ctrl->getLinkTarget($this,
'showTermsOfService'));
1215 '[list-user-agreement]',
1224 '[list-user-agreement]',
1238 '[list-language-selection] ',
1239 '[list-registration-link]',
1240 '[list-user-agreement]',
1241 '[list-login-form]',
1242 '[list-cas-login-form]',
1243 '[list-shibboleth-login-form]' 1245 array(
'',
'',
'',
'',
'',
'',
''),
1254 public function showAccountMigration($a_message =
'')
1262 $lng->loadLanguageModule(
'auth');
1263 self::initStartUpTemplate(
'tpl.login_account_migration.html');
1265 include_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
1267 $form->setFormAction($this->ctrl->getFormAction($this,
'migrateAccount'));
1269 $form->setTitle($lng->txt(
'auth_account_migration'));
1270 $form->addCommandButton(
'migrateAccount', $lng->txt(
'save'));
1271 $form->addCommandButton(
'showLogin', $lng->txt(
'cancel'));
1277 $lng->txt(
'auth_account_migration_keep'),
1278 static::ACCOUNT_MIGRATION_MIGRATE,
1279 $lng->txt(
'auth_info_migrate')
1282 $user->setRequired(
true);
1285 $user->setMaxLength(128);
1289 $pass->setRetype(
false);
1290 $pass->setRequired(
true);
1293 $pass->setMaxLength(128);
1294 $keep->addSubItem(
$pass);
1295 $rad->addOption($keep);
1298 $lng->txt(
'auth_account_migration_new'),
1299 static::ACCOUNT_MIGRATION_NEW,
1300 $lng->txt(
'auth_info_add')
1302 $rad->addOption(
$new);
1304 $form->addItem($rad);
1306 $tpl->setVariable(
'MIG_FORM',$form->getHTML());
1308 if(strlen($a_message))
1313 $tpl->show(
'DEFAULT');
1322 if(!isset(
$_POST[
'account_migration']))
1324 $this->showAccountMigration(
1331 (
$_POST[
'account_migration'] == self::ACCOUNT_MIGRATION_MIGRATE) &&
1332 (!strlen(
$_POST[
'mig_username']) || !strlen(
$_POST[
'mig_password']))
1335 $this->showAccountMigration(
1341 if((
int)
$_POST[
'account_migration'] == self::ACCOUNT_MIGRATION_MIGRATE)
1345 if((
int)
$_POST[
'account_migration'] == static::ACCOUNT_MIGRATION_NEW)
1356 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontend.php';
1358 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendCredentials.php';
1362 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
1366 $this->logger->debug(
'Using provider: ' . get_class(
$provider).
' for further processing.');
1368 include_once
'./Services/Authentication/classes/class.ilAuthStatus.php';
1371 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendFactory.php';
1374 $frontend = $frontend_factory->getFrontend(
1381 if($frontend->migrateAccountNew())
1383 include_once
'./Services/Init/classes/class.ilInitialisation.php';
1384 ilInitialisation::redirectToStartingPage();
1388 $this->ctrl->redirect($this,
'showAccountMigration');
1399 include_once
'./Services/Authentication/classes/class.ilAuthFactory.php';
1401 $this->logger->debug(
'Starting account migration for user: ' . (
string)
ilSession::get(
'mig_ext_account'));
1404 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendCredentials.php';
1406 $credentials->setUsername((
string)
$_POST[
'mig_username']);
1407 $credentials->setPassword((
string) $_POST[
'mig_password']);
1409 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
1413 include_once
'./Services/Authentication/classes/class.ilAuthStatus.php';
1416 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendFactory.php';
1419 $frontend = $frontend_factory->getFrontend(
1426 $frontend->authenticate();
1428 switch($status->getStatus())
1431 $this->
getLogger()->debug(
'Account migration: authentication successful for ' . (
string) $_POST[
'mig_username']);
1433 $provider = $provider_factory->getProviderByAuthMode(
1438 $frontend = $frontend_factory->getFrontend(
1445 $frontend->migrateAccount(
$GLOBALS[
'DIC'][
'ilAuthSession'])
1448 include_once
'./Services/Init/classes/class.ilInitialisation.php';
1449 ilInitialisation::redirectToStartingPage();
1454 $this->ctrl->redirect($this,
'showAccountMigration');
1459 $this->
getLogger()->info(
'Account migration failed for user ' . (
string) $_POST[
'mig_username']);
1460 $this->showAccountMigration(
$GLOBALS[
'lng']->txt(
'err_wrong_login'));
1474 global
$lng,$ilClientIniFile,
$ilLog,$rbacadmin;
1476 $lng->loadLanguageModule(
'auth');
1478 if(!isset(
$_POST[
'account_migration']))
1480 $this->showAccountMigration($lng->txt(
'err_choose_migration_type'));
1485 $_POST[
'account_migration'] == static::ACCOUNT_MIGRATION_MIGRATE
and 1486 (!strlen(
$_POST[
'mig_username'])
or !strlen(
$_POST[
'mig_password'])))
1488 $this->showAccountMigration($lng->txt(
'err_wrong_login'));
1492 if(
$_POST[
'account_migration'] == static::ACCOUNT_MIGRATION_MIGRATE)
1496 $this->showAccountMigration($lng->txt(
'err_wrong_login'));
1499 include_once
'./Services/Authentication/classes/class.ilAuthFactory.php';
1500 include_once
'./Services/Database/classes/class.ilAuthContainerMDB2.php';
1503 include_once
'./Services/Authentication/classes/Frontend/class.ilAuthFrontendCredentials.php';
1505 $credentials->setUsername(
$_POST[
'mig_username']);
1506 $credentials->setPassword(
$_POST[
'mig_password']);
1509 include_once
'./Services/Authentication/classes/class.ilAuthModeDetermination.php';
1513 $credentials->setAuthMode($form->getInput(
'auth_mode'));
1516 include_once
'./Services/Authentication/classes/Provider/class.ilAuthProviderFactory.php';
1523 switch($status->getStatus())
1529 $this->showAccountMigration($lng->txt(
'err_wrong_login'));
1538 if(!$ilAuth->checkAuth())
1541 $this->showAccountMigration($lng->txt(
'err_wrong_login'));
1550 $user->setExternalAccount(
ilSession::get(
'tmp_external_account'));
1551 $user->setActive(
true);
1559 $rbacadmin->assignUser((
int) $role,$user->getId());
1566 elseif(
$_POST[
'account_migration'] == static::ACCOUNT_MIGRATION_NEW)
1574 include_once(
'Services/AuthApache/classes/class.ilAuthContainerApache.php');
1576 $container->forceCreation(
true);
1586 include_once(
'Services/LDAP/classes/class.ilAuthContainerLDAP.php');
1588 $container->forceCreation(
true);
1597 include_once
'./Services/Authentication/classes/class.ilAuthFactory.php';
1598 include_once
'./Services/Radius/classes/class.ilAuthContainerRadius.php';
1601 $container->forceCreation(
true);
1608 include_once
'./Services/Init/classes/class.ilInitialisation.php';
1609 ilInitialisation::redirectToStartingPage();
1621 $GLOBALS[
'DIC'][
'ilAuthSession']->logout();
1623 $GLOBALS[
'ilAppEventHandler']->raise(
1624 'Services/Authentication',
1636 self::initStartUpTemplate(
"tpl.logout.html");
1638 if ($ilSetting->get(
"pub_section"))
1640 $tpl->setCurrentBlock(
"homelink");
1641 $tpl->setVariable(
"CLIENT_ID",
"?client_id=".
$client_id.
"&lang=".$lng->getLangKey());
1642 $tpl->setVariable(
"TXT_HOME",$lng->txt(
"home"));
1643 $tpl->parseCurrentBlock();
1646 if ($ilIliasIniFile->readVariable(
"clients",
"list"))
1648 $tpl->setCurrentBlock(
"client_list");
1649 $tpl->setVariable(
"TXT_CLIENT_LIST", $lng->txt(
"to_client_list"));
1650 $this->ctrl->setParameter($this,
"client_id",
$client_id);
1651 $tpl->setVariable(
"CMD_CLIENT_LIST",
1652 $this->ctrl->getLinkTarget($this,
"showClientList"));
1653 $tpl->parseCurrentBlock();
1654 $this->ctrl->setParameter($this,
"client_id",
"");
1657 $tpl->setVariable(
"TXT_PAGEHEADLINE", $lng->txt(
"logout"));
1658 $tpl->setVariable(
"TXT_LOGOUT_TEXT", $lng->txt(
"logout_text"));
1659 $tpl->setVariable(
"TXT_LOGIN", $lng->txt(
"login_to_ilias"));
1660 $tpl->setVariable(
"CLIENT_ID",
"?client_id=".
$client_id.
"&lang=".$lng->getLangKey());
1673 $valid = $ilAuth->getValidationData();
1675 self::initStartUpTemplate(
"tpl.user_mapping_selection.html");
1679 if ($ilAuth->getSubStatus() == AUTH_WRONG_LOGIN)
1684 include_once(
'./Services/User/classes/class.ilObjUser.php');
1685 if (count($email_user) == 1)
1688 $tpl->setCurrentBlock(
"one_user");
1689 $tpl->setVariable(
"TXT_USERNAME", $lng->txt(
"username"));
1690 $tpl->setVariable(
"VAL_USERNAME", current($email_user));
1691 $tpl->setVariable(
"USER_ID", key($email_user));
1692 $tpl->parseCurrentBlock();
1696 foreach($email_user as $key => $login)
1698 $tpl->setCurrentBlock(
"user");
1699 $tpl->setVariable(
"USR_ID", $key);
1700 $tpl->setVariable(
"VAL_USER", $login);
1701 $tpl->parseCurrentBlock();
1703 $tpl->setCurrentBlock(
"multpiple_user");
1704 $tpl->parseCurrentBlock();
1707 $tpl->setCurrentBlock(
"content");
1708 $this->ctrl->setParameter($this,
"ext_uid", urlencode(
$_GET[
"ext_uid"]));
1709 $this->ctrl->setParameter($this,
"soap_pw", urlencode(
$_GET[
"soap_pw"]));
1710 $this->ctrl->setParameter($this,
"auth_stat",
$_GET[
"auth_stat"]);
1711 $tpl->setVariable(
"FORMACTION",
1712 $this->ctrl->getFormAction($this));
1713 $tpl->setVariable(
"TXT_ILIAS_LOGIN", $lng->txt(
"login_to_ilias"));
1714 if (count($email_user) == 1)
1716 $tpl->setVariable(
"TXT_EXPLANATION", $lng->txt(
"ums_explanation"));
1717 $tpl->setVariable(
"TXT_EXPLANATION_2", $lng->txt(
"ums_explanation_2"));
1721 $tpl->setVariable(
"TXT_EXPLANATION", $lng->txt(
"ums_explanation_3"));
1722 $tpl->setVariable(
"TXT_EXPLANATION_2", $lng->txt(
"ums_explanation_4"));
1724 $tpl->setVariable(
"TXT_CREATE_USER", $lng->txt(
"ums_create_new_account"));
1725 $tpl->setVariable(
"TXT_PASSWORD", $lng->txt(
"password"));
1727 $tpl->setVariable(
"TXT_SUBMIT", $lng->txt(
"login"));
1739 if (!$ilIliasIniFile->readVariable(
"clients",
"list"))
1745 $tpl =
new ilTemplate(
"tpl.main.html",
true,
true);
1746 $tpl->setAddFooter(
false);
1748 $tpl->setVariable(
"PAGETITLE", $lng->txt(
"clientlist_clientlist"));
1752 self::initStartUpTemplate(
"tpl.client_list.html");
1755 $tpl->addBlockfile(
"CLIENT_LIST",
"client_list",
"tpl.table.html");
1758 $tpl->addBlockfile(
"TBL_CONTENT",
"tbl_content",
"tpl.obj_tbl_rows.html");
1761 require_once(
"setup/classes/class.ilClientList.php");
1762 require_once(
"setup/classes/class.ilClient.php");
1763 require_once(
"setup/classes/class.ilDBConnections.php");
1764 require_once(
"./Services/Table/classes/class.ilTableGUI.php");
1767 $list = $clientlist->getClients();
1769 if (count($list) == 0)
1771 header(
"Location: ./setup/setup.php");
1775 $hasPublicSection =
false;
1776 foreach ($list as $key =>
$client)
1782 $this->ctrl->setParameter($this,
"client_id", $key);
1785 $tmp[] =
"<a href=\"".
"login.php?cmd=force_login&client_id=".urlencode($key).
"\">".$lng->txt(
"clientlist_login_page").
"</a>";
1787 if(
$client->getSetting(
'pub_section'))
1789 $hasPublicSection =
true;
1790 $tmp[] =
"<a href=\"" .
"ilias.php?baseClass=ilRepositoryGUI&client_id=" . urlencode($key) .
"\">".$lng->txt(
"clientlist_start_page").
"</a>";
1805 if($hasPublicSection)
1807 $tbl->setTitle($lng->txt(
"clientlist_available_clients"));
1808 $tbl->setHeaderNames(
array($lng->txt(
"clientlist_installation_name"), $lng->txt(
"clientlist_login"), $lng->txt(
"clientlist_public_access")));
1809 $tbl->setHeaderVars(
array(
"name",
"index",
"login"));
1810 $tbl->setColumnWidth(
array(
"50%",
"25%",
"25%"));
1814 $tbl->setTitle($lng->txt(
"clientlist_available_clients"));
1815 $tbl->setHeaderNames(
array($lng->txt(
"clientlist_installation_name"), $lng->txt(
"clientlist_login"),
''));
1816 $tbl->setHeaderVars(
array(
"name",
"login",
''));
1817 $tbl->setColumnWidth(
array(
"70%",
"25%",
'1px'));
1821 $tbl->setOrderColumn(
$_GET[
"sort_by"],
"name");
1822 $tbl->setOrderDirection(
$_GET[
"sort_order"]);
1829 $tbl->disable(
"icon");
1830 $tbl->disable(
"numinfo");
1831 $tbl->disable(
"sort");
1832 $tbl->disable(
"footer");
1836 $tpl->show(
"DEFAULT",
true,
true);
1848 $str =
"<p style=\"margin:15px;\"> 1849 You need to enable Session Cookies in your Browser to use ILIAS. 1852 <br/>Tools -> Options -> Privacy -> Cookies 1853 <br/>Enable 'Allow sites to set cookies' and activate option 'Keep 1854 <br/>cookies' auf 'until I close Firefox' 1856 <br/><b>Mozilla/Netscape</b> 1857 <br/>Edit -> Preferences -> Privacy&Security -> Cookies 1858 <br/>Go to 'Cookie Lifetime Policy' and check option 'Accept for current 1861 <br/><b>Internet Explorer</b> 1862 <br/>Tools -> Internet Options -> Privacy -> Advanced 1863 <br/>- Check 'Override automatic cookie handling' 1864 <br/>- Check 'Always allow session cookies' 1866 $tpl->setVariable(
"CONTENT", $str);
1875 $this->showTermsOfService();
1881 protected function showTermsOfService()
1891 $back_to_login = (
'getAcceptance' != $this->ctrl->getCmd());
1893 self::initStartUpTemplate(
'tpl.view_terms_of_service.html', $back_to_login, !$back_to_login);
1894 $tpl->setVariable(
'TXT_PAGEHEADLINE', $lng->txt(
'usr_agreement'));
1896 require_once
'Services/TermsOfService/classes/class.ilTermsOfServiceSignableDocumentFactory.php';
1898 if($document->exists())
1900 if(
'getAcceptance' == $this->ctrl->getCmd())
1902 if(isset(
$_POST[
'status']) &&
'accepted' ==
$_POST[
'status'])
1904 require_once
'Services/TermsOfService/classes/class.ilTermsOfServiceHelper.php';
1919 $tpl->setVariable(
'FORM_ACTION', $this->ctrl->getFormAction($this, $this->ctrl->getCmd()));
1921 $tpl->setVariable(
'ACCEPT_TERMS_OF_SERVICE', $lng->txt(
'accept_usr_agreement'));
1922 $tpl->setVariable(
'TXT_SUBMIT', $lng->txt(
'submit'));
1925 $tpl->setVariable(
'TERMS_OF_SERVICE_CONTENT', $document->getContent());
1929 include_once(
"./Modules/SystemFolder/classes/class.ilSystemSupportContacts.php");
1944 if(
$GLOBALS[
'DIC'][
'ilAuthSession']->isValid())
1946 include_once
'./Services/Init/classes/class.ilInitialisation.php';
1947 ilInitialisation::redirectToStartingPage();
1957 !isset(
$_GET[
"client_id"]) &&
1958 (
$_GET[
"cmd"] ==
"") &&
1959 $ilIliasIniFile->readVariable(
"clients",
"list"))
1964 if(
$GLOBALS[
'ilSetting']->
get(
'pub_section',
false)
1977 global $objDefinition, $ilPluginAdmin,
$ilUser;
1979 if (is_object($ilPluginAdmin))
1982 $pl_names = $ilPluginAdmin->getActivePluginsForSlot(
IL_COMP_SERVICE,
"UIComponent",
"uihk");
1985 foreach ($pl_names as $pl)
1988 $gui_class = $ui_plugin->getUIClassInstance();
1989 $resp = $gui_class->checkGotoHook($a_target);
1990 if ($resp[
"target"] !==
false)
1992 $a_target = $resp[
"target"];
1998 if ($a_target ==
"")
2003 $t_arr = explode(
"_", $a_target);
2011 if ($type ==
"pg" | $type ==
"st")
2016 $class = $objDefinition->getClassName($type);
2022 $location = $objDefinition->getLocation($type);
2023 $full_class =
"ilObj".$class.
"Access";
2024 include_once(
$location.
"/class.".$full_class.
".php");
2026 $ret = call_user_func(
array($full_class,
"_checkGoto"), $a_target);
2030 !stristr($a_target,
"_wsp") &&
2031 $ilUser->getId() != ANONYMOUS_USER_ID &&
2032 !$objDefinition->isAdministrationObject($type) &&
2033 $objDefinition->isRBACObject($type) &&
2036 global $tree, $rbacsystem, $ilAccess;
2039 if($t_arr[0] ==
"pg")
2041 if(isset($t_arr[2]))
2060 include_once
"Services/Membership/classes/class.ilParticipants.php";
2061 $block_obj =
array();
2066 foreach(
$path as $path_ref_id)
2068 $redirect_infopage =
false;
2069 $add_member_role =
false;
2075 if(!$ilAccess->doActivationCheck(
"read",
"", $path_ref_id, $ilUser->getId(), $pobj_id, $ptype) ||
2076 !$ilAccess->doStatusCheck(
"read",
"", $path_ref_id, $ilUser->getId(), $pobj_id, $ptype))
2081 else if($ptype ==
"crs")
2084 include_once
"Modules/Course/classes/class.ilCourseParticipant.php";
2086 if(!$participants->isAssigned())
2089 include_once
"Modules/Course/classes/class.ilObjCourse.php";
2093 $block_obj[] = $path_ref_id;
2094 $add_member_role =
true;
2098 $redirect_infopage =
true;
2102 else if($ptype ==
"grp")
2105 include_once
"Modules/Group/classes/class.ilGroupParticipants.php";
2109 include_once
"Modules/Group/classes/class.ilObjGroup.php";
2111 if($group_obj->isRegistrationEnabled())
2113 $block_obj[] = $path_ref_id;
2114 $add_member_role =
true;
2118 $redirect_infopage =
true;
2124 if($add_member_role)
2127 $rbacsystem->resetPACache($ilUser->getId(), $path_ref_id);
2128 if(!$rbacsystem->checkAccess(
"join", $path_ref_id))
2130 $redirect_infopage =
true;
2134 $rbacsystem->addTemporaryRole($ilUser->getId(),
2140 if($redirect_infopage)
2142 if($rbacsystem->checkAccess(
"visible", $path_ref_id))
2145 "&ref_id=".$path_ref_id.
"&cmd=infoScreen");
2155 $rbacsystem->resetPACache($ilUser->getId(),
$ref_id);
2156 if($rbacsystem->checkAccess(
"read",
$ref_id) &&
sizeof($block_obj))
2163 $_SESSION[
"pending_goto"] =
"goto.php?target=".$a_target;
2167 "&ref_id=".array_shift($block_obj));
2180 if(!isset(
$_GET[
'rh']) || !strlen(trim(
$_GET[
'rh'])))
2182 ilUtil::redirect(
'./login.php?cmd=force_login®_confirmation_msg=reg_confirmation_hash_not_passed');
2187 require_once
'Services/Registration/classes/class.ilRegistrationSettings.php';
2192 $oUser->setActive(
true);
2193 if($oRegSettings->passwordGenerationEnabled())
2196 $password = $passwd[0];
2198 $oUser->setLastPasswordChangeTS(
time() );
2202 $usr_lang = $oUser->getPref(
'language');
2204 if($lng->getLangKey() != $usr_lang)
2209 $target = $oUser->getPref(
'reg_target');
2217 include_once(
"Services/Mail/classes/class.ilAccountMail.php");
2218 include_once
'./Services/User/classes/class.ilObjUserFolder.php';
2220 if (trim($amail[
"body"]) !=
"" && trim($amail[
"subject"]) !=
"")
2223 $acc_mail->setUser($oUser);
2224 if($oRegSettings->passwordGenerationEnabled())
2226 $acc_mail->setUserPassword($password);
2232 include_once
'Services/Mail/classes/class.ilMail.php';
2233 $mail_obj =
new ilMail(ANONYMOUS_USER_ID);
2236 $subject = $lng->txt(
"reg_mail_subject");
2239 $body = $lng->txt(
"reg_mail_body_salutation").
" ".$oUser->getFullname().
",\n\n".
2240 $lng->txt(
"reg_mail_body_text1").
"\n\n".
2241 $lng->txt(
"reg_mail_body_text2").
"\n".
2242 ILIAS_HTTP_PATH.
"/login.php?client_id=".CLIENT_ID.
"\n";
2243 $body .= $lng->txt(
"login").
": ".$oUser->getLogin().
"\n";
2245 if($oRegSettings->passwordGenerationEnabled())
2247 $body.= $lng->txt(
"passwd").
": ".$password.
"\n";
2251 $body.= $lng->txt(
'reg_mail_body_forgot_password_info').
"\n";
2255 $body .= ($lng->txt(
"reg_mail_body_text3").
"\n\r");
2256 $body .= $oUser->getProfileAsString($lng);
2257 $mail_obj->enableSoap(
false);
2258 $mail_obj->appendInstallationSignature(
true);
2259 $mail_obj->sendMail($oUser->getEmail(),
'',
'',
2265 ilUtil::redirect(
'./login.php?cmd=force_login®_confirmation_msg=reg_account_confirmation_successful&lang='.$usr_lang);
2269 include_once
'Services/WebServices/SOAP/classes/class.ilSoapClient.php';
2271 $soap_client->setResponseTimeout(1);
2272 $soap_client->enableWSDL(
true);
2273 $soap_client->init();
2275 $ilLog->write(__METHOD__.
': Triggered soap call (background process) for deletion of inactive user objects with expired confirmation hash values (dual opt in) ...');
2279 'deleteExpiredDualOptInUserObjects',
2283 $exception->getCode()
2287 ilUtil::redirect(
'./login.php?cmd=force_login®_confirmation_msg='.$exception->getMessage().
"&lang=".$usr_lang);
2291 ilUtil::redirect(
'./login.php?cmd=force_login®_confirmation_msg='.$exception->getMessage().
"&lang=".$usr_lang);
2301 public static function initStartUpTemplate($a_tmpl, $a_show_back =
false, $a_show_logout =
false)
2313 include_once(
"./Services/jQuery/classes/class.iljQueryUtil.php");
2317 include_once(
"./Services/UICore/classes/class.ilUIFramework.php");
2320 $tpl->addBlockfile(
'CONTENT',
'content',
'tpl.startup_screen.html',
'Services/Init');
2326 $param =
'client_id=' .
$_COOKIE[
'ilClientId'] .
'&lang=' . $lng->getLangKey();
2328 $tpl->setCurrentBlock(
'link_item_bl');
2329 $tpl->setVariable(
'LINK_TXT', $lng->txt(
'login_to_ilias'));
2330 $tpl->setVariable(
'LINK_URL',
'login.php?cmd=force_login&'.$param);
2331 $tpl->parseCurrentBlock();
2333 if($ilSetting->get(
'pub_section') &&
2334 $ilAccess->checkAccessOfUser(ANONYMOUS_USER_ID,
'read',
'', ROOT_FOLDER_ID))
2336 $tpl->setVariable(
'LINK_URL',
'index.php?'.$param);
2337 $tpl->setVariable(
'LINK_TXT', $lng->txt(
'home'));
2338 $tpl->parseCurrentBlock();
2341 else if($a_show_logout)
2343 $tpl->setCurrentBlock(
'link_item_bl');
2344 $tpl->setVariable(
'LINK_TXT', $lng->txt(
'logout'));
2345 $tpl->setVariable(
'LINK_URL', ILIAS_HTTP_PATH .
'/logout.php');
2346 $tpl->parseCurrentBlock();
2349 if(is_array($a_tmpl))
2351 $template_file = $a_tmpl[0];
2352 $template_dir = $a_tmpl[1];
2356 $template_file = $a_tmpl;
2357 $template_dir =
'Services/Init';
2361 include_once(
"./Modules/SystemFolder/classes/class.ilObjSystemFolder.php");
2362 $header_top_title = ilObjSystemFolder::_getHeaderTitle();
2363 if (trim($header_top_title) !=
"" && $tpl->blockExists(
"header_top_title"))
2365 $tpl->setCurrentBlock(
"header_top_title");
2366 $tpl->setVariable(
"TXT_HEADER_TITLE", $header_top_title);
2367 $tpl->parseCurrentBlock();
2371 $selection = self::getLanguageSelection();
2374 $tpl->setCurrentBlock(
"lang_select");
2375 $tpl->setVariable(
"TXT_LANGSELECT", $lng->txt(
"language"));
2376 $tpl->setVariable(
"LANG_SELECT", $selection);
2377 $tpl->parseCurrentBlock();
2380 $tpl->addBlockFile(
'STARTUP_CONTENT',
'startup_content', $template_file, $template_dir);
2389 include_once(
"./Services/MainMenu/classes/class.ilMainMenuGUI.php");
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
showLogout()
show logout screen
static _lookupLogin($a_user_id)
lookup login
static applyRoleAssignments(ilObjUser $user, $code)
static _checkGoto($a_target)
static prepareFormOutput($a_str, $a_strip=false)
prepares string output for html forms public
This class represents an option in a radio group.
const ACCOUNT_MIGRATION_NEW
const ACCOUNT_MIGRATION_MIGRATE
static _lookupRegistrationType()
initCodeForm($a_username)
const SESSION_CLOSE_CAPTCHA
showLoginForm($page_editor_html, ilPropertyFormGUI $form=null)
Show login form ilSetting $ilSetting.
static _isParticipant($a_ref_id, $a_usr_id)
Static function to check if a user is a participant of the container object.
if((!isset($_SERVER['DOCUMENT_ROOT'])) OR(empty($_SERVER['DOCUMENT_ROOT']))) $_SERVER['DOCUMENT_ROOT']
static applyAccessLimits(ilObjUser $user, $code)
showCodeForm($a_username=null, $a_form=null)
getLoginPageEditorHTML()
Get HTML of ILIAS login page editor.
Administrates DB connections in setup.
const CONTEXT_STANDARD_FORM
static _hasMultipleAuthenticationMethods()
Class ilAccountRegistrationGUI.
static getStyleSheetLocation($mode="output", $a_css_name="", $a_css_location="")
get full style sheet file name (path inclusive) of current user
const SESSION_CLOSE_INACTIVE
static _registrationEnabled($a_obj_id)
Registration enabled? Method is in Access class, since it is needed by Access/ListGUI.
Overwritten Pear class AuthContainerLDAP This class is overwritten to support nested groups...
Class for user related exception handling in ILIAS.
const STATUS_AUTHENTICATION_FAILED
showShibbolethLoginForm($page_editor_html)
Show shibboleth login form.
const AUTH_CAPTCHA_INVALID
Factory for auth frontend classes.
$GLOBALS['loaded']
Global hash that tracks already loaded includes.
static get($a_var)
Get a value.
const AUTH_RADIUS_NO_ILIAS_USER
static set($a_var, $a_val)
Set a value.
static _lookupId($a_user_str)
Lookup id by login.
static goToPublicSection()
go to public section
migrateAccount()
Migrate Account.
const AUTH_CAS_NO_ILIAS_USER
static generatePasswords($a_number)
Generate a number of passwords.
static _lookupContObjID($a_id)
get learning module / digibook id for lm object
static init($a_tpl=null)
Init.
static getDefaultMemberRole($a_ref_id)
processIndexPHP()
process index.php
Authentication against ILIAS database.
getAcceptance()
Get terms of service.
const AUTH_USER_TIME_LIMIT_EXCEEDED
executeCommand()
execute command
static _getAllReferences($a_id)
get all reference ids of object
doShibbolethAuthentication()
Trying shibboleth authentication.
static _verifyRegistrationHash($a_hash)
Verifies a registration hash.
initStandardLoginForm()
Initialize the standard.
showLoginPage(ilPropertyFormGUI $form=null)
substituteLoginPageElements($tpl, $page_editor_html, $element_html, $placeholder, $fallback_tplvar)
Substitute login page elements.
static setCookie($a_cookie_name, $a_cookie_value='', $a_also_set_super_global=true, $a_set_cookie_invalid=false)
static appendUrlParameterString($a_url, $a_par, $xml_style=false)
append URL parameter string ("par1=value1&par2=value2...") to given URL string
setValue($a_value)
Set Value.
static _existsAndNotEmpty($a_parent_type, $a_id, $a_lang="-")
checks whether page exists and is not empty (may return true on some empty pages) ...
Description of class class.
static _getLocalAccountsForEmail($a_email)
check whether external account and authentication method matches with a user
doApacheAuthentication()
Try apache auth.
addSubItem($a_item)
Add Subitem.
const AUTH_SOAP_NO_ILIAS_USER
static getByLanguageObject(ilLanguage $lng)
static _lookupNewAccountMail($a_lang)
static _getMultipleAuthModeOptions($lng)
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
This class handles base functions for mail handling.
migrateAccount2()
migrate account
static _lookupObjId($a_id)
doCasAuthentication()
Try CAS auth.
special template class to simplify handling of ITX/PEAR
purgePlaceholders($page_editor_html)
Purge page editor html from unused placeholders.
doMigrationNewAccount()
Create new account for migration.
setSize($a_size)
Set Size.
static getLanguageSelection($a_in_topbar=false)
This class represents a text property in a property form.
showRegistrationLinks($page_editor_html)
Show registration, password forgotten, client slection links ilLanguage $lng ilSetting $ilSetting ...
static getPluginObject($a_ctype, $a_cname, $a_slot_id, $a_pname)
Get Plugin Object.
showClientList()
show client list
Add a drawing to the header
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
static getSyntaxStylePath()
get syntax style path
doStandardAuthentication()
Check form input; authenticate user.
static getInstanceByObjId($a_obj_id, $stop_on_error=true)
get an instance of an Ilias object by object id
Create styles array
The data for the language used.
static _lookupType($a_id, $a_reference=false)
lookup object type
Password assistance facility for users who have forgotten their password or for users for whom no pas...
static trackAcceptance(ilObjUser $user, ilTermsOfServiceSignableDocument $document)
static getCodeValidUntil($code)
const AUTH_USER_SIMULTANEOUS_LOGIN
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
doMigration()
Do migration of existing ILIAS database user account.
const AUTH_LDAP_NO_ILIAS_USER
static getContentStylePath($a_style_id)
get content style path
showNoCookiesScreen()
show help screen, if cookies are disabled
const SESSION_CLOSE_SIMUL
const STATUS_AUTHENTICATED
const MIG_EXTERNAL_ACCOUNT
Class ilObjAuthSettingsGUI.
static getLanguageSelection()
language selection list
static _isActivated($a_obj_id)
Is activated.
const STATUS_CODE_ACTIVATION_REQUIRED
static _getInstance()
Get instance.
showUserMappingSelection()
Show user selection screen, if external account could not be mapped to an ILIAS account, but the provided e-mail address is known.
static setClosingContext($a_context)
set closing context (for statistics)
static getInstance()
Get status instance.
showLoginInformation($page_editor_html)
Show login information.
Overwritten Pear class AuthContainerRadius This class is overwritten to support to perform Radius aut...
Authentication against ILIAS database.
static lookupId($a_lang_key)
Lookup obj_id of language ilDB $ilDB.
Description of class class.
static factory(ilAuthContainerBase $deco)
The factory.
static initjQuery($a_tpl=null)
Init jQuery.
static isUnusedCode($code)
static getLogger($a_component_id)
Get component logger.
Add data(end) time
Method that wraps PHPs time in order to allow simulations with the workflow.
static getInstance()
Get singelton instance.
Class for user related exception handling in ILIAS.
const MIG_TRIGGER_AUTHMODE
static redirect($a_script)
http redirect to other script
Auth status implementation.
showCASLoginForm($page_editor_html)
Show cas login ilSetting $ilSetting.
Description of class class.
const STATUS_ACCOUNT_MIGRATION_REQUIRED
static formCheckbox($checked, $varname, $value, $disabled=false)
??? public
jumpToPasswordAssistance()
jump to password assistance
jumpToRegistration()
jump to registration gui
Auth frontend credentials for CAS auth.