2005-06-02 05:39:41 +00:00
|
|
|
<?php
|
2007-01-04 04:52:42 +00:00
|
|
|
|
|
|
|
// set to defaults if undefined
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->host_url))
|
2007-01-04 04:52:42 +00:00
|
|
|
{ $config->host_url = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (empty($config->ldapencoding))
|
|
|
|
{ $config->ldapencoding = 'utf-8'; }
|
|
|
|
if (!isset($config->contexts))
|
2007-01-04 04:52:42 +00:00
|
|
|
{ $config->contexts = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->user_type))
|
|
|
|
{ $config->user_type = 'default'; }
|
|
|
|
if (!isset($config->user_attribute))
|
2007-01-04 04:52:42 +00:00
|
|
|
{ $config->user_attribute = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->search_sub))
|
2007-01-04 04:52:42 +00:00
|
|
|
{ $config->search_sub = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->opt_deref))
|
|
|
|
{ $config->opt_deref = LDAP_DEREF_NEVER; }
|
|
|
|
if (!isset($config->preventpassindb))
|
|
|
|
{ $config->preventpassindb = 0; }
|
|
|
|
if (!isset($config->bind_dn))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->bind_dn = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->bind_pw))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->bind_pw = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->version))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->version = '2'; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->objectclass))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->objectclass = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->memberattribute))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->memberattribute = ''; }
|
2007-03-29 15:53:09 +00:00
|
|
|
if (!isset($config->memberattribute_isdn))
|
|
|
|
{$config->memberattribute_isdn = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->creators))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->creators = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->create_context))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->create_context = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->expiration))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->expiration = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->expiration_warning))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->expiration_warning = '10'; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->expireattr))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->expireattr = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->gracelogins))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->gracelogins = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->graceattr))
|
2007-01-04 04:52:42 +00:00
|
|
|
{$config->graceattr = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->auth_user_create))
|
2005-09-21 14:58:41 +00:00
|
|
|
{$config->auth_user_create = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->forcechangepassword))
|
|
|
|
{$config->forcechangepassword = 0; }
|
2007-01-04 04:52:42 +00:00
|
|
|
if (!isset($config->stdchangepassword))
|
2007-02-20 17:03:36 +00:00
|
|
|
{$config->stdchangepassword = 0; }
|
2007-03-29 19:50:53 +00:00
|
|
|
if (!isset($config->passtype))
|
|
|
|
{$config->passtype = 'plaintext';}
|
2007-01-04 04:52:42 +00:00
|
|
|
if (!isset($config->changepasswordurl))
|
|
|
|
{$config->changepasswordurl = ''; }
|
2007-02-20 17:03:36 +00:00
|
|
|
if (!isset($config->removeuser))
|
|
|
|
{$config->removeuser = 0; }
|
2007-11-14 22:07:16 +00:00
|
|
|
if (!isset($config->ntlmsso_enabled))
|
|
|
|
{$config->ntlmsso_enabled = 0; }
|
|
|
|
if (!isset($config->ntlmsso_subnet))
|
|
|
|
{$config->ntlmsso_subnet = ''; }
|
2005-09-21 14:58:41 +00:00
|
|
|
|
|
|
|
$yesno = array( get_string('no'), get_string('yes') );
|
2007-02-20 17:03:36 +00:00
|
|
|
|
2007-01-04 04:52:42 +00:00
|
|
|
if (!function_exists('ldap_connect')) { // Is php4-ldap really there?
|
2007-01-11 00:05:47 +00:00
|
|
|
notify(get_string('auth_ldap_noextension','auth'));
|
2004-09-20 09:08:57 +00:00
|
|
|
}
|
2007-02-20 17:03:36 +00:00
|
|
|
|
2002-12-31 08:45:37 +00:00
|
|
|
?>
|
2007-04-20 07:54:42 +00:00
|
|
|
<table cellspacing="0" cellpadding="5" border="0">
|
2007-01-04 04:52:42 +00:00
|
|
|
|
2004-09-20 09:08:57 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('auth_ldap_server_settings', 'auth') ?> </h4>
|
2004-09-20 09:08:57 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="host_url"><?php print_string('auth_ldap_host_url_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="host_url" id="host_url" type="text" size="30" value="<?php echo $config->host_url?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['host_url'])) formerr($err['host_url']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_host_url','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2002-11-19 08:51:33 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menuversion"><?php print_string('auth_ldap_version_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2004-04-15 15:57:32 +00:00
|
|
|
<?php
|
2007-02-20 17:03:36 +00:00
|
|
|
$varsions = array();
|
2007-01-04 04:52:42 +00:00
|
|
|
$versions[2] = '2';
|
|
|
|
$versions[3] = '3';
|
|
|
|
choose_from_menu($versions, 'version', $config->version, '');
|
2007-02-20 17:03:36 +00:00
|
|
|
if (isset($err['version'])) formerr($err['version']);
|
2004-04-15 15:57:32 +00:00
|
|
|
?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_version','auth') ?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr valign="top" class="required">
|
|
|
|
<td align="right"><label for="ldapencoding"><?php print_string("auth_ldap_ldap_encoding_key", "auth") ?></label></td>
|
|
|
|
<td>
|
|
|
|
<input id="ldapencoding" name="ldapencoding" type="text" value="<?php echo $config->ldapencoding ?>" />
|
|
|
|
<?php
|
|
|
|
|
|
|
|
if (isset($err['ldapencoding'])) {
|
|
|
|
formerr($err['ldapencoding']);
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<td><?php print_string('auth_ldap_ldap_encoding', 'auth') ?></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
</tr>
|
2004-09-20 09:08:57 +00:00
|
|
|
|
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('auth_ldap_bind_settings', 'auth') ?> </h4>
|
2004-09-20 09:08:57 +00:00
|
|
|
</td>
|
2004-09-12 01:34:24 +00:00
|
|
|
</tr>
|
2004-04-15 15:57:32 +00:00
|
|
|
|
2005-07-14 15:25:43 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menupreventpassindb"><?php print_string('auth_ldap_preventpassindb_key','auth') ?></label></td>
|
2005-07-14 15:25:43 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php choose_from_menu($yesno, 'preventpassindb', $config->preventpassindb, ''); ?>
|
2005-07-14 15:25:43 +00:00
|
|
|
</td><td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_preventpassindb','auth') ?>
|
2005-07-14 15:25:43 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="bind_dn"><?php print_string('auth_ldap_bind_dn_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="bind_dn" id="bind_dn" type="text" size="30" value="<?php echo $config->bind_dn?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['bind_dn'])) formerr($err['bind_dn']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td><td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_bind_dn','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2004-09-20 09:08:57 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="bind_pw"><?php print_string('auth_ldap_bind_pw_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="bind_pw" id="bind_pw" type="password" size="30" value="<?php echo $config->bind_pw?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['bind_pw'])) formerr($err['bind_pw']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td><td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_bind_pw','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2004-09-20 09:08:57 +00:00
|
|
|
|
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('auth_ldap_user_settings', 'auth') ?> </h4>
|
2004-09-20 09:08:57 +00:00
|
|
|
</td>
|
2004-09-12 01:34:24 +00:00
|
|
|
</tr>
|
2002-11-19 08:51:33 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menuuser_type"><?php print_string('auth_ldap_user_type_key','auth') ?></label></td>
|
2004-09-24 06:49:57 +00:00
|
|
|
<td>
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php choose_from_menu($this->ldap_suppported_usertypes(), 'user_type', $config->user_type, ''); ?>
|
|
|
|
<?php if (isset($err['user_type'])) formerr($err['user_type']); ?>
|
2004-09-24 06:49:57 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_user_type', 'auth') ?>
|
2004-09-24 06:49:57 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="contexts"><?php print_string('auth_ldap_contexts_key','auth') ?></label></td>
|
2004-09-24 06:49:57 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="contexts" id="contexts" type="text" size="30" value="<?php echo $config->contexts?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['contexts'])) formerr($err['contexts']); ?>
|
2004-09-24 06:49:57 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_contexts', 'auth') ?>
|
2004-09-24 06:49:57 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menusearch_sub"><?php print_string('auth_ldap_search_sub_key','auth') ?></label></td>
|
2004-09-24 06:49:57 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php choose_from_menu($yesno, 'search_sub', $config->search_sub, ''); ?>
|
2004-09-24 06:49:57 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_search_sub','auth') ?>
|
2004-09-24 06:49:57 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2007-02-20 17:03:36 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menuopt_deref"><?php print_string('auth_ldap_opt_deref_key','auth') ?></label></td>
|
2004-11-08 18:13:00 +00:00
|
|
|
<td>
|
|
|
|
<?php
|
2007-02-20 17:03:36 +00:00
|
|
|
$opt_deref = array();
|
2007-01-04 04:52:42 +00:00
|
|
|
$opt_deref[LDAP_DEREF_NEVER] = get_string('no');
|
|
|
|
$opt_deref[LDAP_DEREF_ALWAYS] = get_string('yes');
|
2007-02-20 17:03:36 +00:00
|
|
|
choose_from_menu($opt_deref, 'opt_deref', $config->opt_deref, LDAP_DEREF_NEVER, '');
|
|
|
|
if (isset($err['opt_deref'])) formerr($err['opt_deref']);
|
2004-11-08 18:13:00 +00:00
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_opt_deref','auth') ?>
|
2004-11-08 18:13:00 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2004-09-24 06:49:57 +00:00
|
|
|
|
2004-09-20 09:08:57 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="user_attribute"><?php print_string('auth_ldap_user_attribute_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="user_attribute" id="user_attribute" type="text" size="30" value="<?php echo $config->user_attribute?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['user_attribute'])) formerr($err['user_attribute']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_user_attribute','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2004-09-20 09:08:57 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="memberattribute"><?php print_string('auth_ldap_memberattribute_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="memberattribute" id="memberattribute" type="text" size="30" value="<?php echo $config->memberattribute?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['memberattribute'])) formerr($err['memberattribute']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td><td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_memberattribute','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2002-11-19 08:51:33 +00:00
|
|
|
|
2007-03-29 15:53:09 +00:00
|
|
|
<tr valign="top" class="required">
|
|
|
|
<td align="right"><label for="memberattribute_isdn"><?php print_string('auth_ldap_memberattribute_isdn_key','auth') ?></label></td>
|
|
|
|
<td>
|
2007-05-30 08:49:19 +00:00
|
|
|
<input name="memberattribute_isdn" id="memberattribute_isdn" type="text" size="30" value="<?php echo $config->memberattribute_isdn?>" />
|
2007-03-29 15:53:09 +00:00
|
|
|
<?php if (isset($err['memberattribute_isdn'])) formerr($err['memberattribute_isdn']); ?>
|
|
|
|
</td><td>
|
|
|
|
<?php print_string('auth_ldap_memberattribute_isdn','auth') ?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="objectclass"><?php print_string('auth_ldap_objectclass_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="objectclass" id="objectclass" type="text" size="30" value="<?php echo $config->objectclass?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['objectclass'])) formerr($err['objectclass']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_objectclass','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2004-08-15 16:12:19 +00:00
|
|
|
|
2004-09-22 08:28:56 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('forcechangepassword', 'auth') ?> </h4>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right" valign="top"><label for="menuforcechangepassword"><?php print_string('forcechangepassword', 'auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php choose_from_menu($yesno, 'forcechangepassword', $config->forcechangepassword, ''); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td align="left" valign="top">
|
2007-02-20 17:03:36 +00:00
|
|
|
<p><?php print_string('forcechangepasswordfirst_help', 'auth') ?></p>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right" valign="top"><label for="menustdchangepassword"><?php print_string('stdchangepassword', 'auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php choose_from_menu($yesno, 'stdchangepassword', $config->stdchangepassword, ''); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td align="left" valign="top">
|
2007-02-20 17:03:36 +00:00
|
|
|
<p><?php print_string('stdchangepassword_expl', 'auth') ?></p>
|
|
|
|
<p><?php print_string('stdchangepassword_explldap', 'auth') ?></p>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2007-03-29 19:50:53 +00:00
|
|
|
<tr valign="top" class="required">
|
|
|
|
<td align="right"><label for="menupasstype"><?php print_string('auth_ldap_passtype_key', 'auth') ?></label></td>
|
|
|
|
<td>
|
|
|
|
<?php
|
|
|
|
$passtype = array();
|
|
|
|
$passtype['plaintext'] = get_string('plaintext', 'auth');
|
|
|
|
$passtype['md5'] = get_string('md5', 'auth');
|
|
|
|
$passtype['sha1'] = get_string('sha1', 'auth');
|
|
|
|
choose_from_menu($passtype, 'passtype', $config->passtype, '');
|
|
|
|
|
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td><?php print_string('auth_ldap_passtype', 'auth') ?></td>
|
|
|
|
</tr>
|
|
|
|
|
2007-01-04 04:52:42 +00:00
|
|
|
<tr valign="top">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="changepasswordurl"><?php print_string('auth_ldap_changepasswordurl_key','auth') ?></label></td>
|
2007-01-04 04:52:42 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="changepasswordurl" id="changepasswordurl" type="text" value="<?php echo $config->changepasswordurl ?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
if (isset($err['changepasswordurl'])) {
|
|
|
|
formerr($err['changepasswordurl']);
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td><?php print_string('changepasswordhelp', 'auth') ?></td>
|
|
|
|
</tr>
|
|
|
|
|
2004-09-22 08:28:56 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('auth_ldap_passwdexpire_settings', 'auth') ?> </h4>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menuexpiration"><?php print_string('auth_ldap_expiration_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
|
|
|
<?php
|
2007-02-20 17:03:36 +00:00
|
|
|
$expiration = array();
|
2007-01-04 04:52:42 +00:00
|
|
|
$expiration['0'] = 'no';
|
|
|
|
$expiration['1'] = 'LDAP';
|
|
|
|
choose_from_menu($expiration, 'expiration', $config->expiration, '');
|
2007-02-20 17:03:36 +00:00
|
|
|
if (isset($err['expiration'])) formerr($err['expiration']);
|
2004-09-22 08:28:56 +00:00
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_expiration_desc','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2004-09-27 14:19:32 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="expiration_warning"><?php print_string('auth_ldap_expiration_warning_key','auth') ?></label></td>
|
2004-09-27 14:19:32 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="expiration_warning" id="expiration_warning" type="text" size="2" value="<?php echo $config->expiration_warning?>" />
|
|
|
|
<?php if (isset($err['expiration_warning'])) formerr($err['expiration_warning']);
|
2004-09-27 14:19:32 +00:00
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_expiration_warning_desc','auth') ?>
|
2004-09-27 14:19:32 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="expireattr"><?php print_string('auth_ldap_expireattr_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="expireattr" id="expireattr" type="text" size="30" value="<?php echo $config->expireattr?>" />
|
|
|
|
<?php if (isset($err['expireattr'])) formerr($err['expireattr']);
|
2004-09-22 08:28:56 +00:00
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_expireattr_desc','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menugracelogins"><?php print_string('auth_ldap_gracelogins_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php choose_from_menu($yesno, 'gracelogins', $config->gracelogins, ''); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_gracelogins_desc','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="graceattr"><?php print_string('auth_ldap_gracelogin_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="graceattr" id="graceattr" type="text" size="30" value="<?php echo $config->graceattr?>" />
|
|
|
|
<?php if (isset($err['graceattr'])) formerr($err['graceattr']);
|
2004-09-22 08:28:56 +00:00
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_graceattr_desc','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
2004-09-20 09:08:57 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('auth_user_create', 'auth') ?> </h4>
|
2004-09-20 09:08:57 +00:00
|
|
|
</td>
|
2004-09-12 01:34:24 +00:00
|
|
|
</tr>
|
2002-11-19 08:51:33 +00:00
|
|
|
|
2007-01-04 04:52:42 +00:00
|
|
|
<tr valign="top">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="menuauth_user_create"><?php print_string('auth_ldap_auth_user_create_key','auth') ?></label></td>
|
2007-01-04 04:52:42 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php choose_from_menu($yesno, 'auth_user_create', $config->auth_user_create, ''); ?>
|
2007-01-04 04:52:42 +00:00
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<?php print_string("auth_user_creation","auth"); ?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="create_context"><?php print_string('auth_ldap_create_context_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="create_context" id="create_context" type="text" size="30" value="<?php echo $config->create_context?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['create_context'])) formerr($err['create_context']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td><td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_create_context','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
2002-11-19 08:51:33 +00:00
|
|
|
|
|
|
|
|
2004-09-20 09:08:57 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
2007-01-04 04:52:42 +00:00
|
|
|
<h4><?php print_string('coursecreators') ?> </h4>
|
2004-09-20 09:08:57 +00:00
|
|
|
</td>
|
2004-09-12 01:34:24 +00:00
|
|
|
</tr>
|
2003-02-24 18:48:55 +00:00
|
|
|
|
2005-02-09 12:55:34 +00:00
|
|
|
<tr valign="top" class="required">
|
2007-02-20 17:03:36 +00:00
|
|
|
<td align="right"><label for="creators"><?php print_string('auth_ldap_creators_key','auth') ?></label></td>
|
2004-09-22 08:28:56 +00:00
|
|
|
<td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<input name="creators" id="creators" type="text" size="30" value="<?php echo $config->creators?>" />
|
2007-01-04 04:52:42 +00:00
|
|
|
<?php if (isset($err['creators'])) formerr($err['creators']); ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td><td>
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php print_string('auth_ldap_creators','auth') ?>
|
2004-09-22 08:28:56 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2007-02-20 17:03:36 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
|
|
|
<h4><?php print_string('auth_sync_script', 'auth') ?> </h4>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr valign="top">
|
|
|
|
<td align="right"><label for="menuremoveuser"><?php print_string('auth_remove_user_key','auth') ?></label></td>
|
|
|
|
<td>
|
|
|
|
<?php
|
|
|
|
$deleteopt = array();
|
|
|
|
$deleteopt['0'] = get_string('auth_remove_keep','auth');
|
|
|
|
$deleteopt['1'] = get_string('auth_remove_suspend','auth');
|
|
|
|
$deleteopt['2'] = get_string('auth_remove_delete','auth');
|
|
|
|
choose_from_menu($deleteopt, 'removeuser', $config->removeuser, '');
|
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<?php print_string('auth_remove_user','auth') ?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2007-11-14 22:07:16 +00:00
|
|
|
<tr>
|
|
|
|
<td colspan="2">
|
|
|
|
<h4><?php print_string('auth_ntlmsso', 'auth') ?> </h4>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr valign="top">
|
|
|
|
<td align="right"><label for="ntlmsso_enabled"><?php print_string('auth_ntlmsso_enabled_key','auth') ?></label></td>
|
|
|
|
<td>
|
|
|
|
<?php
|
|
|
|
choose_from_menu($yesno, 'ntlmsso_enabled', $config->ntlmsso_enabled, '0');
|
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<?php print_string('auth_ntlmsso_enabled','auth') ?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr valign="top">
|
|
|
|
<td align="right"><label for="ntlmsso_subnet"><?php print_string('auth_ntlmsso_subnet_key','auth') ?></label></td>
|
|
|
|
<td><input name="ntlmsso_subnet" id="ntlmsso_subnet" type="text" size="30" value="<?php p($config->ntlmsso_subnet) ?>"
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<?php print_string('auth_ntlmsso_subnet','auth') ?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2007-02-20 17:03:36 +00:00
|
|
|
<?php
|
2004-09-22 08:28:56 +00:00
|
|
|
|
2007-01-04 04:52:42 +00:00
|
|
|
$help = get_string('auth_ldapextrafields','auth');
|
|
|
|
$help .= get_string('auth_updatelocal_expl','auth');
|
|
|
|
$help .= get_string('auth_fieldlock_expl','auth');
|
|
|
|
$help .= get_string('auth_updateremote_expl','auth');
|
2005-06-02 05:39:41 +00:00
|
|
|
$help .= '<hr />';
|
2007-01-04 04:52:42 +00:00
|
|
|
$help .= get_string('auth_updateremote_ldap','auth');
|
2004-09-22 08:28:56 +00:00
|
|
|
|
2007-02-20 17:03:36 +00:00
|
|
|
print_auth_lock_options('ldap', $user_fields, $help, true, true);
|
2004-09-22 08:28:56 +00:00
|
|
|
|
2007-01-04 04:52:42 +00:00
|
|
|
?>
|
2004-09-22 08:28:56 +00:00
|
|
|
|
2007-01-04 04:52:42 +00:00
|
|
|
</table>
|