4include_once 
'./Services/CAS/classes/class.ilCASSettings.php';
 
   37        $this->tabs_gui = $ilTabs;
 
   39        $this->lng->loadLanguageModule(
'registration');
 
   40        $this->lng->loadLanguageModule(
'auth');
 
   43        $this->ref_id = $a_auth_ref_id;
 
   68        $next_class = $this->ctrl->getNextClass($this);
 
   69        $cmd = $this->ctrl->getCmd(
"settings");
 
   71        if (!$ilAccess->checkAccess(
'read', 
'', $this->ref_id)) {
 
   72            $ilErr->raiseError($this->lng->txt(
'msg_no_perm_write'), 
$ilErr->WARNING);
 
   75        if (!$ilAccess->checkAccess(
'write', 
'', $this->ref_id) && $cmd != 
"settings") {
 
   77            $ilCtrl->redirect($this, 
"settings");
 
   81        switch ($next_class) {
 
   98        $this->lng->loadLanguageModule(
'auth');
 
   99        $this->lng->loadLanguageModule(
'radius');
 
  101        include_once(
"./Services/Form/classes/class.ilPropertyFormGUI.php");
 
  103        $form->setFormAction($this->ctrl->getFormAction($this));
 
  105        $form->setTitle($this->lng->txt(
'auth_cas_auth'));
 
  106        $form->setDescription($this->lng->txt(
"auth_cas_auth_desc"));
 
  110        $check->setChecked($this->
getSettings()->isActive() ? 
true : 
false);
 
  112        $form->addItem($check);
 
  116        $text->setRequired(
true);
 
  117        $text->setInfo($this->lng->txt(
'auth_cas_server_desc'));
 
  119        $text->setMaxLength(255);
 
  124        $port->setRequired(
true);
 
  125        $port->setMinValue(0);
 
  126        $port->setMaxValue(65535);
 
  128        $port->setMaxLength(5);
 
  129        $port->setInfo($this->lng->txt(
'auth_cas_port_desc'));
 
  130        $form->addItem($port);
 
  134        $text->setRequired(
true);
 
  135        $text->setInfo($this->lng->txt(
'auth_cas_uri_desc'));
 
  137        $text->setMaxLength(255);
 
  145        $sync->setRequired(
true);
 
  146        #$sync->setInfo($this->lng->txt('auth_radius_sync_info')); 
  151            $this->lng->txt(
'disabled'),
 
  155        #$dis->setInfo($this->lng->txt('auth_radius_sync_disabled_info')); 
  156        $sync->addOption($dis);
 
  160            $this->lng->txt(
'auth_sync_cas'),
 
  164        $rad->setInfo($this->lng->txt(
'auth_sync_cas_info'));
 
  165        $sync->addOption($rad);
 
  167        $select = 
new ilSelectInputGUI($this->lng->txt(
'auth_user_default_role'), 
'role');
 
  169        $select->setValue($this->
getSettings()->getDefaultRole());
 
  170        $rad->addSubItem($select);
 
  175        include_once 
'./Services/LDAP/classes/class.ilLDAPServer.php';
 
  178        if (count($server_ids)) {
 
  180                $this->lng->txt(
'auth_radius_ldap'),
 
  184            $ldap->setInfo($this->lng->txt(
'auth_radius_ldap_info'));
 
  185            $sync->addOption($ldap);
 
  187            $ldap_server_select = 
new ilSelectInputGUI($this->lng->txt(
'auth_ldap_server_ds'), 
'ldap_sid');
 
  188            $options[0] = $this->lng->txt(
'select_one');
 
  189            foreach ($server_ids as $ldap_sid) {
 
  191                $options[$ldap_sid] = $ldap_server->getName();
 
  193            $ldap_server_select->setOptions(
$options);
 
  194            $ldap_server_select->setRequired(
true);
 
  196            $ldap_server_select->setValue($ds);
 
  198            $ldap->addSubItem($ldap_server_select);
 
  211        $instruction = 
new ilTextAreaInputGUI($this->lng->txt(
'auth_login_instructions'), 
'instruction');
 
  212        $instruction->setCols(80);
 
  213        $instruction->setRows(6);
 
  214        $instruction->setValue($this->
getSettings()->getLoginInstruction());
 
  215        $form->addItem($instruction);
 
  218        $create->setInfo($this->lng->txt(
'auth_cas_allow_local_desc'));
 
  219        $create->setChecked($this->
getSettings()->isLocalAuthenticationEnabled() ? 
true : 
false);
 
  220        $create->setValue(1);
 
  221        $form->addItem($create);
 
  223        $form->addCommandButton(
'save', $this->lng->txt(
'save'));
 
  238        $this->tpl->setContent(
$form->getHTML());
 
  251        if (
$form->checkInput()) {
 
  262            include_once 
'./Services/LDAP/classes/class.ilLDAPServer.php';
 
  263            switch ((
int) 
$form->getInput(
'sync')) {
 
  273                    if (!(
int) $_REQUEST[
'ldap_sid']) {
 
  283            ilUtil::sendSuccess($this->lng->txt(
'settings_saved'), 
true);
 
  284            $this->ctrl->redirect($this, 
'settings');
 
  287        $form->setValuesByPost();
 
  289        $this->tpl->setContent(
$form->getHTML());
 
  296        global $rbacreview,$ilObjDataCache;
 
  299            $rbacreview->getGlobalRoles(),
 
  305        $select[0] = $this->lng->txt(
'links_select_one');
 
  306        foreach ($global_roles as $role_id) {
 
An exception for terminatinating execution or to throw for unit testing.
executeCommand()
Execute command.
__construct($a_auth_ref_id)
Constructor.
initFormSettings()
Init cas settings.
static getInstance()
Get singleton instance.
static getDataSource($a_auth_mode)
static disableDataSourceForAuthMode($a_authmode)
Disable data source.
static isDataSourceActive($a_auth_mode)
Check if a data source is active for a specific auth mode @global ilDB $ilDB.
static toggleDataSource($a_ldap_server_id, $a_auth_mode, $a_status)
Toggle Data Source.
static getAvailableDataSources($a_auth_mode)
static _lookupTitle($a_id)
lookup object title
This class represents an option in a radio group.
This class represents a text area property in a property form.
This class represents a text property in a property form.
static _sortIds($a_ids, $a_table, $a_field, $a_id_name)
Function that sorts ids by a given table field using WHERE IN E.g: __sort(array(6,...
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
if(isset($_POST['submit'])) $form