summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: bdbf67e)
raw | patch | inline | side by side (parent: bdbf67e)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 4 Apr 2007 10:14:38 +0000 (10:14 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 4 Apr 2007 10:14:38 +0000 (10:14 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@5975 594d385d-05f5-0310-b6e9-bd551577e9d8
setup/class_setupStep5.inc | patch | blob | history | |
setup/class_setupStep6.inc | patch | blob | history | |
setup/class_setupStep6a.inc | patch | blob | history | |
setup/setup_step6a.tpl | patch | blob | history |
index 01d6ed167c20db7323a6654cd55cbe5ca67af0fe..8b6acec6fba5674126e811647c8ca43b236db527 100644 (file)
function check()
{
$message = array();
+
+ if(preg_match("/,$/",$this->peopleou)){
+ $message[] =sprintf(_("Don't add a trailing comma to '%s'."),_("People storage ou"));
+ }
+
+ if(preg_match("/,$/",$this->groupou)){
+ $message[] =sprintf(_("Don't add a trailing comma to '%s'."),_("Group storage ou"));
+ }
+
if(!is_numeric($this->uidbase)){
$message[] = _("Uid base must be numeric");
}
index c9c61ec31333a90138809f8e76137ecbfef3365c..30dd7f931cacdd233eb14bc44ef6f573d99fff19 100644 (file)
function check()
{
$message = array();
+
+ if(isset($this->generic_settings['minid_active']) && !is_numeric($this->generic_settings['minid'])){
+ $message[] = sprintf(_("The specified value for '%s' must be a numeric value"),_("GID / UID min id"));
+ }
+
return($message);
}
index 35f9816155ca357ac9061d8ac69b058a751430a3..c2646799ff0976bdd7177ba40c3f38b78bdc4226 100644 (file)
function setup_step_6a()
{
$this->update_strings();
+
+ /* Look for samba password generation method */
+ if(file_exists("/usr/bin/mkntpasswd")){
+ $pwdhash = "/usr/bin/mkntpasswd";
+ } elseif (preg_match("/^Usage: mkntpwd /", shell_exec ("mkntpwd 2>&1"))){
+ $pwdhash= "mkntpwd";
+ } else {
+ $pwdhash= 'perl -MCrypt::SmbHash -e "print join(q[:], ntlmgen \$ARGV[0]), $/;"';
+ }
+
+ $this->optional['smbhash'] = $pwdhash;
}
foreach(array("enableCopyPaste","forceglobals","forcessl","warnssl","compile","debuglevel","session_lifetime","smbhash") as $name){
if(isset($_POST[$name])){
- $this->optional[$name] = $_POST[$name];
+ $this->optional[$name] = stripslashes($_POST[$name]);
}
}
function check()
{
$message = array();
+
+ if(!is_numeric( $this->optional['session_lifetime'])){
+ $message[] = _("Session lifetime must be a numeric value.");
+ }
+
+ if(!is_numeric( $this->optional['max_ldap_query_time'])){
+ $message[] = _("Maximal ldap query time must be a numeric value. ");
+ }
+
return($message);
}
diff --git a/setup/setup_step6a.tpl b/setup/setup_step6a.tpl
index de4d3da4d5d41b63cffee661a474e284498a8127..b7db260a1710eaeca1b477d16a5104119ebbecef 100644 (file)
--- a/setup/setup_step6a.tpl
+++ b/setup/setup_step6a.tpl
<b>{t}Optional settings{/t}</b>
</div>
-
-
<div class='step4_container'>
<div class='step4_name'>
{t}Enable Copy & Paste{/t}
</div>
</div>
- <div class='step4_container'>
- <div class='step4_name'>
+ <div class='step4_container' style='height:5em;'>
+ <div class='step4_name' style='height:5em;'>
{t}SMB hash{/t}
</div>
- <div class='step4_value'>
- <input style='width:90%' id='smbhash' name='smbhash'
- type='text' value='{$optional.smbhash}'>
- </div>
- <div class='step4_status'>
+ <div class='step4_value' style='height:5em;'>
+ <input {if $optional.smbhash == "/usr/bin/mkntpasswd"} checked {/if}
+ type='radio' name='smbhash' value='/usr/bin/mkntpasswd'>
+ /usr/bin/mkntpasswd<br>
+ <input {if $optional.smbhash == "mkntpwd"} checked {/if}
+ type='radio' name='smbhash' value='mkntpwd'>
+ mkntpwd<br>
+ <input {if $optional.smbhash == 'perl -MCrypt::SmbHash -e "print join(q[:], ntlmgen \$ARGV[0]), $/;"'} checked {/if}
+ type='radio' name='smbhash' value='perl -MCrypt::SmbHash -e "print join(q[:], ntlmgen \$ARGV[0]), $/;"'>
+ perl -MCrypt::SmbHash ...
+ </div>
+ <div class='step4_status' style='height:5em;'>
{t}Infos in FAQ{/t}
<img class='center' src='images/info_small.png' title='{t}Please read the FAQ for more informations{/t}'>
</div>