From d89430abdfd5877f8d61f247d272e077f83101e2 Mon Sep 17 00:00:00 2001 From: paca70 Date: Mon, 27 Sep 2004 14:19:32 +0000 Subject: [PATCH] Changes to configuration interface --- auth/ldap/config.html | 178 +++++++++++++++++++++++------------------- auth/ldap/lib.php | 3 +- lang/en/auth.php | 3 +- 3 files changed, 100 insertions(+), 84 deletions(-) diff --git a/auth/ldap/config.html b/auth/ldap/config.html index 5e2dd73791..ae88ccab59 100644 --- a/auth/ldap/config.html +++ b/auth/ldap/config.html @@ -13,6 +13,7 @@ optional_variable($config->ldap_creators, ""); optional_variable($config->ldap_create_context, ""); optional_variable($config->ldap_expiration, ""); + optional_variable($config->ldap_expiration_warning, "10"); optional_variable($config->ldap_expireattr, ""); optional_variable($config->ldap_gracelogins, ""); optional_variable($config->ldap_graceattr, ""); @@ -20,14 +21,14 @@ optional_variable($config->auth_user_create, ""); optional_variable($config->auth_ldap_forcepasswordchange, ""); - optional_variable($config->auth_user_firstname_updatelocal, ""); - optional_variable($config->auth_user_firstname_editlock, ""); + optional_variable($config->auth_user_firstname_updatelocal, "1"); + optional_variable($config->auth_user_firstname_editlock, "1"); optional_variable($config->auth_user_firstname_updateremote, ""); - optional_variable($config->auth_user_lastname_updatelocal, ""); - optional_variable($config->auth_user_lastname_editlock, ""); + optional_variable($config->auth_user_lastname_updatelocal, "1"); + optional_variable($config->auth_user_lastname_editlock, "1"); optional_variable($config->auth_user_lastname_updateremote, ""); - optional_variable($config->auth_user_email_updatelocal, ""); - optional_variable($config->auth_user_email_editlock, ""); + optional_variable($config->auth_user_email_updatelocal, "1"); + optional_variable($config->auth_user_email_editlock, "1"); optional_variable($config->auth_user_email_updateremote, ""); optional_variable($config->auth_user_phone1_updatelocal, ""); optional_variable($config->auth_user_phone1_editlock, ""); @@ -207,9 +208,9 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?
@@ -224,9 +225,9 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?
@@ -259,6 +260,19 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there? + + +

ldap_expiration_warning: + + + + + + + + +

ldap_exprireattr: @@ -349,23 +363,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?




@@ -387,23 +401,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -417,23 +431,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -447,23 +461,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -477,23 +491,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -507,23 +521,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -537,23 +551,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -567,23 +581,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -597,23 +611,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -627,23 +641,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -657,23 +671,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



@@ -687,23 +701,23 @@ if (!function_exists('ldap_connect')){ // Is php4-ldap really there?



diff --git a/auth/ldap/lib.php b/auth/ldap/lib.php index eacd58ab82..737fb29e42 100644 --- a/auth/ldap/lib.php +++ b/auth/ldap/lib.php @@ -494,6 +494,7 @@ function auth_user_update($olduser, $newuser) { } + function auth_user_update_password($username, $newpassword) { /// called when the user password is updated -- it assumes it is called by an admin /// or that you've otherwise checked the user's credentials @@ -535,7 +536,7 @@ function auth_ldap_suppported_usertypes (){ $types['edir']='Novell Edirectory'; $types['posix']='posixAccount (rfc2307)'; $types['samba']='sambaSamAccount (v.3.0.7)'; - $types['ad']='ActiveDirectory'; + $types['ad']='MS ActiveDirectory'; return $types; } diff --git a/lang/en/auth.php b/lang/en/auth.php index e6b8e69986..3a9e429eed 100644 --- a/lang/en/auth.php +++ b/lang/en/auth.php @@ -38,7 +38,8 @@ $string['auth_ldap_bind_settings'] = 'Bind settings'; $string['auth_ldap_contexts'] = 'List of contexts where users are located. Separate different contexts with \';\'. For example: \'ou=users,o=org; ou=others,o=org\''; $string['auth_ldap_create_context'] = 'If you enable user creation with email confirmation, specify the context where users are created. This context should be different from other users to prevent security issues. You don\'t need to add this context to ldap_context-variable, Moodle will search for users from this context automatically.
Note! You have to modify function auth_user_create() in file auth/ldap/lib.php to make user creation work'; $string['auth_ldap_creators'] = 'List of groups whose members are allowed to create new courses. Separate multiple groups with \';\'. Usually something like \'cn=teachers,ou=staff,o=myorg\''; -$string['auth_ldap_expiration_desc'] = 'Select No to disable expired password checking or LDAP to read passwordexpiration time directly from LDAP.Remeber to fill attribute name ldap_expireattr'; +$string['auth_ldap_expiration_desc'] = 'Select No to disable expired password checking or LDAP to read passwordexpiration time directly from LDAP'; +$string['auth_ldap_expiration_warning_desc'] = 'Number of days before password expiration warning is issued.'; $string['auth_ldap_expireattr_desc'] = 'Optional: overrides ldap-attribute what stores password expiration time asswordAxpirationTime'; $string['auth_ldap_graceattr_desc'] = 'Optional: Overrides gracelogin attribute'; $string['auth_ldap_gracelogins_desc'] = 'Enable LDAP gracelogin support. After password has expired user can login until gracelogin count is 0. Enabling this setting displays grace login message if password is exprired.'; -- 2.39.5