summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b66b09a)
raw | patch | inline | side by side (parent: b66b09a)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 11 May 2010 06:59:20 +0000 (06:59 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 11 May 2010 06:59:20 +0000 (06:59 +0000) |
-Fixed usage of above mentioned properties.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18311 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18311 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/include/class_core.inc | patch | blob | history | |
gosa-core/include/functions.inc | patch | blob | history |
index 90aaf37b2f0d3b39e3797181b63f5a078ede2633..808f5a309c8c3586689911cdad02238da504fbda 100644 (file)
{
$list = array();
switch($name){
+ case 'idAllocationMethod':
+ $list = array('traditional' => _('Traditional'), 'pool' => _('Use samba pool'));
+ break;
case 'passwordDefaultHash':
$tmp = passwordMethod::get_available_methods();
foreach($tmp['name'] as $id => $method){
"description" => "The 'gidNumberBase' statement defines where to start looking for a new free group id. This should be synced with your 'adduser.conf' to avoid overlapping gidNumber values between local and LDAP based lookups. The gidNumberBase can even be dynamic. Take a look at the 'nextIdHook' definition.",
"check" => "gosaProperty::isInteger",
"migrate" => "",
- "group" => "core",
+ "group" => "id",
+ "mandatory" => TRUE),
+ array(
+ "name" => "gidNumberPoolMin",
+ "type" => "integer",
+ "default" => 10000,
+ "description" => "The 'uidNumberPoolMin/gidNumberPoolMin' statement defines the lowest assignable user/group id for use with the 'idAllocationMethod = pool'.",
+ "check" => "gosaProperty::isInteger",
+ "migrate" => "",
+ "group" => "id",
+ "mandatory" => TRUE),
+
+ array(
+ "name" => "gidNumberPoolMax",
+ "type" => "integer",
+ "default" => 40000,
+ "description" => "The 'uidNumberPoolMax/gidNumberPoolMax' statement defines the highest assignable user/group id for use with the 'idAllocationMethod = pool'.",
+ "check" => "gosaProperty::isInteger",
+ "migrate" => "",
+ "group" => "id",
+ "mandatory" => TRUE),
+
+ array(
+ "name" => "uidNumberPoolMin",
+ "type" => "integer",
+ "default" => 10000,
+ "description" => "The 'uidNumberPoolMin/gidNumberPoolMin' statement defines the lowest assignable user/group id for use with the 'idAllocationMethod = pool'.",
+ "check" => "gosaProperty::isInteger",
+ "migrate" => "",
+ "group" => "id",
+ "mandatory" => TRUE),
+
+ array(
+ "name" => "uidNumberPoolMax",
+ "type" => "integer",
+ "default" => 40000,
+ "description" => "The 'uidNumberPoolMax/gidNumberPoolMax' statement defines the highest assignable user/group id for use with the 'idAllocationMethod = pool'.",
+ "check" => "gosaProperty::isInteger",
+ "migrate" => "",
+ "group" => "id",
"mandatory" => TRUE),
array(
"description" => "The 'uidNumberBase' statement defines where to start looking for a new free user id. This should be synced with your 'adduser.conf' to avoid overlapping uidNumber values between local and LDAP based lookups. The uidNumberBase can even be dynamic. Take a look at the 'baseIdHook' definition.",
"check" => "gosaProperty::isInteger",
"migrate" => "",
- "group" => "core",
+ "group" => "id",
"mandatory" => TRUE),
array(
"description" => "The 'nextIdHook' statement defines a script to be called for finding the next free id for users or groups externaly. It gets called with the current entry \"dn\" and the attribute to be ID'd. It should return an integer value.",
"check" => "gosaProperty::isCommand",
"migrate" => "",
- "group" => "core",
+ "group" => "id",
"mandatory" => FALSE),
array(
array(
"name" => "minId",
"type" => "integer",
- "default" => "",
+ "default" => 40,
"description" => "The 'minId' statement defines the minimum assignable user or group id to avoid security leaks with uid 0 accounts. This is used for the 'traditional' method.",
"check" => "gosaProperty::isInteger",
"migrate" => "",
- "group" => "core",
+ "group" => "id",
"mandatory" => FALSE),
array(
"group" => "snapshot",
"mandatory" => FALSE),
+ array(
+ "name" => "idAllocationMethod",
+ "type" => "switch",
+ "default" => "traditional",
+ "defaults" => "core::getPropertyValues",
+ "description" => "The 'idAllocationMethod' statement defines how GOsa generates numeric user and group id values. If it is set to 'traditional' GOsa will do create a lock and perform a search for the next free ID. The lock will be removed after the procedure completes. 'pool' will use the sambaUnixIdPool objectclass settings inside your LDAP. This one is unsafe, because it does not check for concurrent LDAP access and already used IDs in this range. On the other hand it is much faster.",
+ "check" => "",
+ "migrate" => "",
+ "group" => "id",
+ "mandatory" => TRUE),
array(
"name" => "snapshotURI",
"type" => "uri",
index 2a27f7a66482d365dbfcf55e41835573fcb18bd1..76dd67aa57a00ac829d4a1824be012eebd02fd8d 100644 (file)
global $config;
/* Fill informational values */
- $min= $config->get_cfg_value("core","${attrib}PoolMin", 10000);
- $max= $config->get_cfg_value("core","${attrib}PoolMax", 40000);
+ $min= $config->get_cfg_value("core","${attrib}PoolMin");
+ $max= $config->get_cfg_value("core","${attrib}PoolMax");
/* Sanity check */
if ($min >= $max) {
/* If it does not exist, create one with these defaults */
if ($ldap->count() == 0) {
/* Fill informational values */
- $minUserId= $config->get_cfg_value("core","uidPoolMin", 10000);
- $minGroupId= $config->get_cfg_value("core","gidPoolMin", 10000);
+ $minUserId= $config->get_cfg_value("core","uidNumberPoolMin");
+ $minGroupId= $config->get_cfg_value("core","gidNumberPoolMin");
/* Add as default */
$attrs= array("objectClass" => array("organizationalUnit", "sambaUnixIdPool"));