From c8e3daf5fd2ab7b4a6f9d0e7ec28fe1f6de72e5b Mon Sep 17 00:00:00 2001 From: Benjamin Renard Date: Tue, 22 Mar 2011 15:16:11 +0100 Subject: [PATCH] LSaddon::samba : Added generate_sambaProfilePath() function --- public_html/conf/LSaddons/config.LSaddons.samba.php | 6 +++++- public_html/includes/addons/LSaddons.samba.php | 12 ++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/public_html/conf/LSaddons/config.LSaddons.samba.php b/public_html/conf/LSaddons/config.LSaddons.samba.php index e7206ff3..6dc9d60c 100644 --- a/public_html/conf/LSaddons/config.LSaddons.samba.php +++ b/public_html/conf/LSaddons/config.LSaddons.samba.php @@ -56,5 +56,9 @@ define('LS_SAMBA_GIDNUMBER_ATTR','gidNumber'); define('LS_SAMBA_USERPASSWORD_ATTR','userPassword'); // Format du chemin du home -define('LS_SAMBA_HOME_PATH_FORMAT','\\SERVER\profiles'); +define('LS_SAMBA_HOME_PATH_FORMAT','\\SERVER\%{uid}'); + +// Format du chemin du profile +define('LS_SAMBA_PROFILE_PATH_FORMAT','\\SERVER\profiles\%{uid}'); + ?> diff --git a/public_html/includes/addons/LSaddons.samba.php b/public_html/includes/addons/LSaddons.samba.php index cdaf6afc..41c5e6d7 100644 --- a/public_html/includes/addons/LSaddons.samba.php +++ b/public_html/includes/addons/LSaddons.samba.php @@ -77,6 +77,7 @@ define('LS_SAMBA_INFINITY_TIME',2147483647); 'LS_SAMBA_DOMAIN_SID', 'LS_SAMBA_DOMAIN_NAME', 'LS_SAMBA_HOME_PATH_FORMAT', + 'LS_SAMBA_PROFILE_PATH_FORMAT', 'LS_SAMBA_DOMAIN_OBJECT_DN', 'LS_SAMBA_SID_BASE_USER', 'LS_SAMBA_SID_BASE_GROUP', @@ -342,4 +343,15 @@ define('LS_SAMBA_INFINITY_TIME',2147483647); return $ldapObject -> getFData(LS_SAMBA_HOME_PATH_FORMAT); } + /** + * Generation du sambaProfilePath + * + * @author Benjamin Renard + * + * @retval string Le sambaProfilePath + */ + function generate_sambaProfilePath($ldapObject) { + return $ldapObject -> getFData(LS_SAMBA_PROFILE_PATH_FORMAT); + } + ?>