summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9c71155)
raw | patch | inline | side by side (parent: 9c71155)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 19 Apr 2007 13:26:51 +0000 (13:26 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 19 Apr 2007 13:26:51 +0000 (13:26 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6135 594d385d-05f5-0310-b6e9-bd551577e9d8
index 8f3e499a73b0f7d0c1fc6b0aaf3f983a02b972f3..8eab8885f68696eb644f538ff0bad3ff01c94abf 100644 (file)
var $samba_settings = array( "samba_sid" => "0-815-4711",
"samba_sid_active" => FALSE,
"samba_rid" => 1000,
+ "smbhash" => 'SMBHASH',
"samba_rid_active" => FALSE);
var $attributes = array("governmentmode","sambaidmapping","cyrusunixstyle","mail");
foreach($tmp['name'] as $name){
$this->mail_methods[$name] = $name;
}
+
+ /* 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->samba_settings['smbhash'] = $pwdhash;
}
}else{
$this->samba_settings['samba_rid_active'] = FALSE;
}
+ if(isset($_POST['smbhash'])){
+ $this->samba_settings['smbhash'] = $_POST['smbhash'];
+ }
}
index 680fdebd79d2f67699b855b4d37758fff4253005..365a66ffe9644995900158865b4692ab4a8a1d94 100644 (file)
"kioskpath" => "/var/spool/kiosk",
"kioskpath_active" => FALSE,
- "noprimarygroup" => FALSE,
- "smbhash" => 'SMBHASH');
+ "noprimarygroup" => FALSE);
function Step_Config3()
{
$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("strict_units","noprimarygroup","forceglobals","forcessl","warnssl","compile","debuglevel","session_lifetime","smbhash") as $name){
+ foreach(array("strict_units","noprimarygroup","forceglobals","forcessl","warnssl","compile","debuglevel","session_lifetime") as $name){
if(isset($_POST[$name])){
$this->optional[$name] = stripslashes($_POST[$name]);
}
index 433ace1adb065f899f51309e52b8e7e47608883a..679fee9a273c2eb6d471c7ed93cd20a0f8cd2a1d 100644 (file)
--- a/setup/setup_config2.tpl
+++ b/setup/setup_config2.tpl
<div class='default' style='margin:12px; '>
<p><b>{t}Samba settings{/t}</b></p>
+
+ <div class='step4_container'>
+ <div class='step4_name'>
+ {t}Samba hash generator{/t}
+ </div>
+ <div class='step4_value'>
+ <input size=40 id='smbhash' name='smbhash' type='text' value='{$samba_settings.smbhash}' >
+ </div>
+ </div>
+
<div class='step4_container'>
<div class='step4_name'>
{t}Samba SID{/t}
index f3155981b3798708903b0b6e661dee8cbebff664..89b7f9999e7fe12f6b6fd054743ee75148dda847 100644 (file)
--- a/setup/setup_config3.tpl
+++ b/setup/setup_config3.tpl
</div>
</div>
- <div class='step4_container' style='height:5em;'>
- <div class='step4_name' style='height:5em;'>
- {t}SMB hash{/t}
- </div>
- <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>
-
<div class='step4_container'>
<div class='step4_name'>
{t}Session lifetime{/t}