Projects
Kolab:3.4
kolab-webadmin
Log In
Username
Password
We truncated the diff of some files because they were too big. If you want to see the full diff for every file,
click here
.
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 49
View file
kolab-webadmin.spec
Changed
@@ -34,7 +34,7 @@ %global kolabr_group_id 414 Name: kolab-webadmin -Version: 3.2.2 +Version: 3.2.3 Release: 1%{?dist} Summary: Kolab Groupware Server Web Administration Interface License: AGPLv3+ @@ -43,10 +43,6 @@ Source0: http://mirror.kolabsys.com/pub/releases/%{name}-%{version}.tar.gz -Patch1: 0001-Fix-escaping-of-object-identifiers-in-javascript-com.patch -Patch2: 0002-Define-max-width-for-select-fields.patch -Patch3: 0003-Fix-handling-special-characters-e.g.-comma-in-organi.patch - BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -83,10 +79,6 @@ %prep %setup -q -%patch1 -p1 -%patch2 -p1 -%patch3 -p1 - for file in `find . -type f -name "*.enterprise"`; do if [ 0%{?kolab_enterprise} -gt 0 ]; then mv -v $file $(echo $file | sed -e 's/.enterprise$//g') @@ -175,6 +167,9 @@ %attr(0770,%{httpd_user},%{httpd_group}) %{_var}/log/%{name} %changelog +* Tue Nov 11 2014 Jeroen van Meeuwen <vanmeeuwen@kolabsys.com> - 3.2.3-1 +- New upstream release + * Fri Oct 10 2014 Jeroen van Meeuwen <vanmeeuwen@kolabsys.com> - 3.2.2-1 - New upstream release
View file
0001-Fix-escaping-of-object-identifiers-in-javascript-com.patch
Deleted
@@ -1,53 +0,0 @@ -From 3b4e4a7d263df3a864e542970dc27c21bd92bf97 Mon Sep 17 00:00:00 2001 -From: Aleksander Machniak <machniak@kolabsys.com> -Date: Fri, 10 Oct 2014 20:02:16 +0200 -Subject: [PATCH 1/3] Fix escaping of object identifiers in javascript command - (#3675) - ---- - lib/kolab_client_task.php | 2 +- - lib/kolab_utils.php | 17 +++++++++++++++++ - 2 files changed, 18 insertions(+), 1 deletion(-) - -diff --git a/lib/kolab_client_task.php b/lib/kolab_client_task.php -index 1fe3761..5713a5b 100644 ---- a/lib/kolab_client_task.php -+++ b/lib/kolab_client_task.php -@@ -1682,7 +1682,7 @@ class kolab_client_task - $i++; - $cells = array(); - $cells[] = array('class' => 'name', 'body' => kolab_html::escape($item), -- 'onclick' => "kadm.command('$task.info', '$idx')"); -+ 'onclick' => "kadm.command('$task.info', '" . kolab_utils::js_escape($idx) . "')"); - $rows[] = array('id' => $i, 'class' => implode(' ', $class), 'cells' => $cells); - } - } -diff --git a/lib/kolab_utils.php b/lib/kolab_utils.php -index e2602af..91dad55 100644 ---- a/lib/kolab_utils.php -+++ b/lib/kolab_utils.php -@@ -206,4 +206,21 @@ class kolab_utils - - return $str; - } -+ -+ /** -+ * Escape string for use in javascript code -+ * -+ * @param string $str String -+ * -+ * @return string Escaped string -+ */ -+ public static function js_escape($str) -+ { -+ return strtr($str, array( -+ '"' => '\\"', -+ "'" => "\\'", -+ "\\" => "\\\\", -+ "\n" => '\n', -+ )); -+ } - } --- -1.9.3 -
View file
0002-Define-max-width-for-select-fields.patch
Deleted
@@ -1,27 +0,0 @@ -From 1e9c4d1a80785895294a4503517fb51dfa2d8d70 Mon Sep 17 00:00:00 2001 -From: Aleksander Machniak <machniak@kolabsys.com> -Date: Fri, 10 Oct 2014 20:07:36 +0200 -Subject: [PATCH 2/3] Define max-width for select fields - ---- - public_html/skins/default/style.css | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/public_html/skins/default/style.css b/public_html/skins/default/style.css -index fcb47e5..2452eaf 100644 ---- a/public_html/skins/default/style.css -+++ b/public_html/skins/default/style.css -@@ -120,6 +120,10 @@ table.form td { - padding: 1px 5px; - } - -+table.form select { -+ max-width: 500px; -+} -+ - table.form tr.required input, - table.form tr.required select, - table.form tr.required textarea { --- -1.9.3 -
View file
0003-Fix-handling-special-characters-e.g.-comma-in-organi.patch
Deleted
@@ -1,99 +0,0 @@ -From 14b84021343d89f7f517709fc4d08b62f8f077d3 Mon Sep 17 00:00:00 2001 -From: Aleksander Machniak <machniak@kolabsys.com> -Date: Fri, 10 Oct 2014 21:40:11 +0200 -Subject: [PATCH 3/3] Fix handling special characters (e.g. comma) in - organizational unit names (#3744) Fix escaping of object identifiers in - javascript command (#3675) - for organizational units list - ---- - lib/client/kolab_client_task_ou.php | 45 ++++++++++++++++++++++++++----------- - 1 file changed, 32 insertions(+), 13 deletions(-) - -diff --git a/lib/client/kolab_client_task_ou.php b/lib/client/kolab_client_task_ou.php -index 6179518..a286d34 100644 ---- a/lib/client/kolab_client_task_ou.php -+++ b/lib/client/kolab_client_task_ou.php -@@ -108,7 +108,7 @@ class kolab_client_task_ou extends kolab_client_task - $cells[] = array( - 'class' => 'name', - 'body' => $tree . kolab_html::escape($item['name']), -- 'onclick' => "kadm.command('ou.info', '$idx')", -+ 'onclick' => "kadm.command('ou.info', '" . kolab_utils::js_escape($idx) . "')", - ); - - $rows[] = array( -@@ -196,11 +196,8 @@ class kolab_client_task_ou extends kolab_client_task - { - // build the list for sorting - foreach (array_keys($list) as $dn) { -- $name = kolab_utils::dn2ufn($dn); -- $name = explode(',', $name); -- -- $sort_name = array_pop($name) . ',' . implode(',', array_reverse($name)); -- -+ $names = $this->explode_dn($dn); -+ $sort_name = $names['domain'] . ':' . implode(',', array_reverse($names['path'])); - $list[$dn] = mb_strtolower($sort_name); - } - -@@ -237,7 +234,10 @@ class kolab_client_task_ou extends kolab_client_task - $parent = $this->domain_dn($item['domain']); - - foreach ($item['path'] as $sub) { -+ // convert special characters back into entities (# -+ $sub = str_replace(',', "\\2C", $sub); - $parent = "ou=$sub,$parent"; -+ - if (!isset($result[$parent])) { - $result[$parent] = $this->parse_dn($parent); - $last = $parent; -@@ -260,15 +260,13 @@ class kolab_client_task_ou extends kolab_client_task - */ - private function parse_dn($dn) - { -- $path = kolab_utils::dn2ufn($dn); -- $path = explode(', ', $path); -- $domain = array_pop($path); // remove domain -+ $items = $this->explode_dn($dn); - - return array( -- 'name' => array_shift($path), -- 'path' => array_reverse($path), -- 'level' => count($path), -- 'domain' => $domain, -+ 'name' => array_shift($items['path']), -+ 'path' => array_reverse($items['path']), -+ 'level' => count($items['path']), -+ 'domain' => $items['domain'], - ); - } - -@@ -279,4 +277,25 @@ class kolab_client_task_ou extends kolab_client_task - { - return "dc=" . implode(',dc=', explode('.', $domain)); - } -+ -+ private function explode_dn($dn) -+ { -+ $path = kolab_utils::explode_dn($dn); -+ $domain = array(); -+ -+ foreach ($path as $idx => $item) { -+ if (strpos($item, 'dc=') === 0) { -+ unset($path[$idx]); -+ $domain[] = substr($item, 3); -+ } -+ else { -+ $path[$idx] = substr($item, 3); -+ } -+ } -+ -+ return array( -+ 'domain' => implode('.', $domain), -+ 'path' => $path, -+ ); -+ } - } --- -1.9.3 -
View file
debian.changelog
Changed
@@ -1,3 +1,9 @@ +kolab-webadmin (3.2.3-0~kolab1) unstable; urgency=low + + * New upstream release 3.2.3 + + -- Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> Tue, 11 Nov 2014 22:08:00 +0100 + kolab-webadmin (3.2.2-0~kolab1) unstable; urgency=low * New upstream release 3.2.2
View file
debian.series
Changed
@@ -1,3 +0,0 @@ -0001-Fix-escaping-of-object-identifiers-in-javascript-com.patch -p1 -0002-Define-max-width-for-select-fields.patch -p1 -0003-Fix-handling-special-characters-e.g.-comma-in-organi.patch -p1
View file
kolab-webadmin-3.2.2.tar.gz/doc/kolab_wap.oracle.sql -> kolab-webadmin-3.2.3.tar.gz/doc/kolab_wap.oracle.sql
Changed
@@ -20,6 +20,7 @@ :NEW."id" := "group_types_seq".nextval; END IF; END; +/ INSERT ALL INTO "group_types" ("id", "key", "name", "description", "attributes", "is_default") @@ -69,6 +70,7 @@ :NEW."id" := "ou_types_seq".nextval; END IF; END; +/ INSERT ALL INTO "ou_types" ("id", "key", "name", "description", "attributes", "is_default") @@ -97,6 +99,7 @@ :NEW."id" := "resource_types_seq".nextval; END IF; END; +/ INSERT ALL INTO "resource_types" ("id", "key", "name", "description", "attributes", "is_default") @@ -133,6 +136,7 @@ :NEW."id" := "role_types_seq".nextval; END IF; END; +/ INSERT ALL INTO "role_types" ("id", "key", "name", "description", "attributes", "is_default") @@ -160,6 +164,7 @@ :NEW."id" := "sharedfolder_types_seq".nextval; END IF; END; +/ INSERT ALL INTO "sharedfolder_types" ("id", "key", "name", "description", "attributes", "is_default") @@ -200,6 +205,7 @@ :NEW."id" := "user_types_seq".nextval; END IF; END; +/ INSERT ALL INTO "user_types" ("id", "key", "name", "description", "attributes", "used_for", "is_default")
View file
kolab-webadmin-3.2.2.tar.gz/lib/Auth.php -> kolab-webadmin-3.2.3.tar.gz/lib/Auth.php
Changed
@@ -101,12 +101,14 @@ * This user is to be authenticated against the 'kolab' * 'primary_domain'. * - * @param string $username User name (DN or mail) - * @param string $password User password + * @param string $username User name (DN or mail) + * @param string $password User password + * @param string $domain User domain + * @param array $attributes List of result attributes * * @return bool|string User ID or False on failure */ - public function authenticate($username, $password, $domain = null) + public function authenticate($username, $password, $domain = null, &$attributes = null) { Log::info("Authentication request for $username against " . $this->domain); @@ -116,7 +118,7 @@ // TODO: Debug logging for the use of a current or the creation of // a new authentication class instance. - $result = $this->_auth[$this->domain]->authenticate($username, $password, $domain); + $result = $this->_auth[$this->domain]->authenticate($username, $password, $domain, $attributes); return $result; } @@ -211,9 +213,9 @@ return $this->auth_instance()->domain_find_by_attribute($attribute); } - public function domain_info($domaindata) + public function domain_info($domaindata, $attributes = array('*')) { - return $this->auth_instance()->domain_info($domaindata); + return $this->auth_instance()->domain_info($domaindata, $attributes); } public function domain_is_empty($domain) @@ -262,9 +264,9 @@ return $this->auth_instance()->group_find_by_attribute($attribute); } - public function group_info($groupdata) + public function group_info($groupdata, $attributes = array('*')) { - return $this->auth_instance()->group_info($groupdata); + return $this->auth_instance()->group_info($groupdata, $attributes); } public function group_members_list($groupdata, $recurse = true) @@ -332,9 +334,9 @@ return $this->auth_instance()->organizationalunit_find_by_attribute($attribute); } - public function organizationalunit_info($resourcedata) + public function organizationalunit_info($resourcedata, $attributes = array('*')) { - return $this->auth_instance()->organizationalunit_info($resourcedata); + return $this->auth_instance()->organizationalunit_info($resourcedata, $attributes); } public function resource_add($attributes, $typeid = null) @@ -357,9 +359,9 @@ return $this->auth_instance()->resource_find_by_attribute($attribute); } - public function resource_info($resourcedata) + public function resource_info($resourcedata, $attributes = array('*')) { - return $this->auth_instance()->resource_info($resourcedata); + return $this->auth_instance()->resource_info($resourcedata, $attributes); } public function role_add($role, $typeid = null) @@ -382,9 +384,9 @@ return $this->auth_instance()->role_find_by_attribute($attribute); } - public function role_info($roledata) + public function role_info($roledata, $attributes = array('*')) { - return $this->auth_instance()->role_info($roledata); + return $this->auth_instance()->role_info($roledata, $attributes); } public function sharedfolder_add($attributes, $typeid = null) @@ -407,9 +409,9 @@ return $this->auth_instance()->sharedfolder_find_by_attribute($attribute); } - public function sharedfolder_info($sharedfolderdata) + public function sharedfolder_info($sharedfolderdata, $attributes = array('*')) { - return $this->auth_instance()->sharedfolder_info($sharedfolderdata); + return $this->auth_instance()->sharedfolder_info($sharedfolderdata, $attributes); } public function search() @@ -449,9 +451,9 @@ return $this->auth_instance()->user_find_by_attribute($attribute); } - public function user_info($userdata) + public function user_info($userdata, $attributes = array('*')) { - return $this->auth_instance()->user_info($userdata); + return $this->auth_instance()->user_info($userdata, $attributes); } public function schema_attributes($object_classes)
View file
kolab-webadmin-3.2.2.tar.gz/lib/Auth/LDAP.php -> kolab-webadmin-3.2.3.tar.gz/lib/Auth/LDAP.php
Changed
@@ -125,19 +125,15 @@ * * @return bool|string User ID or False on failure */ - public function authenticate($username, $password, $domain = NULL) + public function authenticate($username, $password, $domain = null, &$attributes = null) { $this->_log(LOG_DEBUG, "Auth::LDAP: authentication request for $username against domain $domain"); - if (!$this->connect()) { - return false; - } - - if ($domain == NULL) { + if (!$domain) { $domain = $this->domain; } - $result = $this->login($username, $password, $domain); + $result = $this->login($username, $password, $domain, $attributes); if (!$result) { return false; @@ -1188,7 +1184,6 @@ } else { return $value; } - } public function _log($level, $msg) @@ -1418,18 +1413,6 @@ return $result; } - if (!$this->connect()) { - $this->_log(LOG_DEBUG, "Could not connect"); - return false; - } - - $bind_dn = $this->config_get("service_bind_dn", $this->conf->get("service_bind_dn")); - $bind_pw = $this->config_get("service_bind_pw", $this->conf->get("service_bind_pw")); - - if (!$this->bind($bind_dn, $bind_pw)) { - return false; - } - $this->_log(LOG_DEBUG, "Auth::LDAP::domain_root_dn(\$domain = $domain)"); if ($entry_attrs = $this->_find_domain($domain)) { @@ -1464,38 +1447,6 @@ return $domain_root_dn; } - /** - * Probe the root dn with the user credentials. - * - * When a list of domains is retrieved, this does not mean the user - * actually has access. Given the root dn for each domain however, we - * can in fact attempt to list / search the root dn and see if we get - * any results. If we don't, maybe this user is not authorized for the - * domain at all? - */ - private function _probe_root_dn($entry_root_dn) - { - //console("Running for entry root dn: " . $entry_root_dn); - if (($tmpconn = ldapconnect($this->_ldap_server)) == false) { - //message("LDAP Error: " . $this->_errstr()); - return false; - } - - //console("User DN: " . $_SESSION['user']->user_bind_dn); - - if (ldap_bind($tmpconn, $_SESSION['user']->user_bind_dn, $_SESSION['user']->user_bind_pw) === false) { - //message("LDAP Error: " . $this->_errstr()); - return false; - } - - if (($list_success = ldap_list($tmpconn, $entry_root_dn, '(objectClass=*)', array('*', 'aci'))) === false) { - //message("LDAP Error: " . $this->_errstr()); - return false; - } - - return true; - } - private function _read($entry_dn, $attributes = array('*')) { $result = $this->search($entry_dn, '(objectclass=*)', 'base', $attributes); @@ -1528,11 +1479,38 @@ { $this->_log(LOG_DEBUG, "Auth::LDAP::_find_domain($domain)"); - $ckey = 'domain::' . $domain; + $ckey = 'domain::' . $domain; + + if (isset($this->icache[$ckey])) { + return $this->icache[$ckey]; + } // use memcache - if ($domain_dn = $this->get_cache_data($ckey)) { - return $this->_read($domain_dn, $attributes); + $domain_dn = $this->get_cache_data($ckey); + + // connect and bind only if needed... + if (empty($this->_current_bind_dn)) { + $bind_dn = $_SESSION['user'] ? $_SESSION['user']->user_bind_dn : null; + + // ...and it is needed if we ned to call _read() or _search() below + if (!$domain_dn || !$bind_dn) { + if ($bind_dn) { + $bind_pw = $_SESSION['user']->user_bind_pw; + } + else { + $bind_dn = $this->conf->get('service_bind_dn'); + $bind_pw = $this->conf->get('service_bind_pw'); + } + + if (!$this->bind($bind_dn, $bind_pw)) { + return false; + } + } + } + + // Got cached domain DN, no need for searching, just read + if ($domain_dn) { + return $this->icache[$ckey] = $this->_read($domain_dn, $attributes); } $domain_base_dn = $this->conf->get('ldap', 'domain_base_dn'); @@ -1552,9 +1530,9 @@ if (count($result) == 1) { $this->set_cache_data($ckey, key($result)); } - - return $result; } + + return $this->icache[$ckey] = $result; } /**
View file
kolab-webadmin-3.2.2.tar.gz/lib/User.php -> kolab-webadmin-3.2.3.tar.gz/lib/User.php
Changed
@@ -35,17 +35,16 @@ private $working_domain; - public function authenticate($username, $password, $domain = null, $method = false) + public function authenticate($username, $password, $domain = null, &$attributes = null) { - //console("Running with domain", $domain); - if (empty($domain)) { $this->auth = Auth::get_instance(); - } else { + } + else { $this->auth = Auth::get_instance($domain); } - $result = $this->auth->authenticate($username, $password); + $result = $this->auth->authenticate($username, $password, $domain, $attributes); if ($result) { $this->_authenticated = true; @@ -57,13 +56,17 @@ // set unique attribute value as userid if ($this->userid != 'cn=Directory Manager') { $unique_attr = kolab_api_service::unique_attribute(); - if ($result = $this->auth->get_entry_attribute($result, $unique_attr)) { - $this->userid = $result; + + if ($attributes && $attributes[$unique_attr]) { + $this->userid = $attributes[$unique_attr]; + } + else if ($uid = $this->auth->get_entry_attribute($result, $unique_attr)) { + $this->userid = $uid; } } } - return $this->_authenticated; + return $result; } public function authenticated()
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_domain.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_domain.php
Changed
@@ -250,7 +250,8 @@ } $auth = Auth::get_instance(); - $result = $auth->domain_info($getdata['id']); + $attrs = $this->object_attributes('domain'); + $result = $auth->domain_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('domain', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_form_value.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_form_value.php
Changed
@@ -1304,15 +1304,23 @@ foreach ($list as $idx => $value) { if (!empty($value['displayname'])) { $list[$idx] = $value['displayname']; - } elseif (!empty($value['cn'])) { + } + else if (!empty($value['cn'])) { $list[$idx] = $value['cn']; - } else { - //console("No display name or cn for $idx"); + } + else { + $list[$idx] = ''; } if (!empty($value['mail'])) { $list[$idx] .= ' <' . $value['mail'] . '>'; } + + $list[$idx] = trim($list[$idx]); + + if ($list[$idx] === '') { + unset($list[$idx]); + } } // Sort and slice @@ -1367,7 +1375,12 @@ $idx = $value[$result_key]; } - $result[$idx] = $ret; + $ret = trim($ret); + + // sanity check (#3822) + if ($ret !== '') { + $result[$idx] = $ret; + } } return $result; @@ -1406,12 +1419,13 @@ foreach ($list as $idx => $value) { if (!empty($value['displayname'])) { $list[$idx] = $value['displayname']; - } elseif (!empty($value['cn'])) { + } + elseif (!empty($value['cn'])) { $list[$idx] = $value['cn']; - } else { - //console("No display name or cn for $idx"); } - + else { + unset($list[$idx]); + } } return $list;
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_group.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_group.php
Changed
@@ -155,7 +155,8 @@ } $auth = Auth::get_instance(); - $result = $auth->group_info($getdata['id']); + $attrs = $this->object_attributes('group'); + $result = $auth->group_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('group', $result); @@ -194,7 +195,8 @@ } // get group data - $result = $auth->group_info(key($groups['list'])); + $attrs = $this->object_attributes('group'); + $result = $auth->group_info(key($groups['list']), $attrs); // normalize result $result = $this->parse_result_attributes('group', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_ou.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_ou.php
Changed
@@ -163,7 +163,8 @@ } $auth = Auth::get_instance(); - $result = $auth->organizationalunit_info($getdata['id']); + $attrs = $this->object_attributes('ou'); + $result = $auth->organizationalunit_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('ou', $result); @@ -206,7 +207,8 @@ } // get OU data - $result = $auth->organizationalunit_info(key($units['list'])); + $attrs = $this->object_attributes('ou'); + $result = $auth->organizationalunit_info(key($units['list']), $attrs); // normalize result $result = $this->parse_result_attributes('ou', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_resource.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_resource.php
Changed
@@ -168,7 +168,8 @@ } // get resource data - $result = $auth->resource_info(key($resources['list'])); + $attrs = $this->object_attributes('resource'); + $result = $auth->resource_info(key($resources['list']), $attrs); // normalize result $result = $this->parse_result_attributes('resource', $result); @@ -195,7 +196,8 @@ } $auth = Auth::get_instance(); - $result = $auth->resource_info($getdata['id']); + $attrs = $this->object_attributes('resource'); + $result = $auth->resource_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('resource', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_role.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_role.php
Changed
@@ -169,7 +169,8 @@ } $auth = Auth::get_instance(); - $result = $auth->role_info($getdata['id']); + $attrs = $this->object_attributes('role'); + $result = $auth->role_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('role', $result); @@ -206,7 +207,8 @@ } // get role data - $result = $auth->role_info(key($roles['list'])); + $attrs = $this->object_attributes('role'); + $result = $auth->role_info(key($roles['list']), $attrs); // normalize result $result = $this->parse_result_attributes('role', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_sharedfolder.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_sharedfolder.php
Changed
@@ -158,7 +158,8 @@ } $auth = Auth::get_instance(); - $result = $auth->sharedfolder_info($getdata['id']); + $attrs = $this->object_attributes('sharedfolder'); + $result = $auth->sharedfolder_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('sharedfolder', $result); @@ -195,7 +196,8 @@ } // get shared folder data - $result = $auth->sharedfolder_info(key($sharedfolders['list'])); + $attrs = $this->object_attributes('sharedfolder'); + $result = $auth->sharedfolder_info(key($sharedfolders['list']), $attrs); // normalize result $result = $this->parse_result_attributes('sharedfolder', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/api/kolab_api_service_user.php -> kolab-webadmin-3.2.3.tar.gz/lib/api/kolab_api_service_user.php
Changed
@@ -168,9 +168,8 @@ } $auth = Auth::get_instance(); - $result = $auth->user_info($getdata['id']); - - Log::trace("user.info on " . $getdata['id'] . " result: " . var_export($result, TRUE)); + $attrs = $this->object_attributes('user'); + $result = $auth->user_info($getdata['id'], $attrs); // normalize result $result = $this->parse_result_attributes('user', $result); @@ -213,7 +212,8 @@ } // get user data - $result = $auth->user_info(key($users['list'])); + $attrs = $this->object_attributes('user'); + $result = $auth->user_info(key($users['list']), $attrs); // normalize result $result = $this->parse_result_attributes('user', $result);
View file
kolab-webadmin-3.2.2.tar.gz/lib/client/kolab_client_task_ou.php -> kolab-webadmin-3.2.3.tar.gz/lib/client/kolab_client_task_ou.php
Changed
@@ -108,7 +108,7 @@ $cells[] = array( 'class' => 'name', 'body' => $tree . kolab_html::escape($item['name']), - 'onclick' => "kadm.command('ou.info', '$idx')", + 'onclick' => "kadm.command('ou.info', '" . kolab_utils::js_escape($idx) . "')", ); $rows[] = array( @@ -196,11 +196,8 @@ { // build the list for sorting foreach (array_keys($list) as $dn) { - $name = kolab_utils::dn2ufn($dn); - $name = explode(',', $name); - - $sort_name = array_pop($name) . ',' . implode(',', array_reverse($name)); - + $names = $this->explode_dn($dn); + $sort_name = $names['root'] . ':' . implode(',', array_reverse($names['path'])); $list[$dn] = mb_strtolower($sort_name); } @@ -234,10 +231,13 @@ if ($item['level']) { // create a parent unit entry if it does not exist (search result) - $parent = $this->domain_dn($item['domain']); + $parent = $item['root']; foreach ($item['path'] as $sub) { + // convert special characters back into entities (#3744) + $sub = str_replace(',', "\\2C", $sub); $parent = "ou=$sub,$parent"; + if (!isset($result[$parent])) { $result[$parent] = $this->parse_dn($parent); $last = $parent; @@ -260,23 +260,41 @@ */ private function parse_dn($dn) { - $path = kolab_utils::dn2ufn($dn); - $path = explode(', ', $path); - $domain = array_pop($path); // remove domain + $items = $this->explode_dn($dn); return array( - 'name' => array_shift($path), - 'path' => array_reverse($path), - 'level' => count($path), - 'domain' => $domain, + 'name' => array_shift($items['path']), + 'path' => array_reverse($items['path']), + 'level' => count($items['path']), + 'root' => $items['root'], ); } /** - * Converts domain name into DN string + * Tokenizes OU's DN string */ - private function domain_dn($domain) + private function explode_dn($dn) { - return "dc=" . implode(',dc=', explode('.', $domain)); + $path = kolab_utils::explode_dn($dn); + $root = array(); + + foreach ($path as $idx => $item) { + $pos = strpos($item, '='); + $key = substr($item, 0, $pos); + + if ($key != 'ou') { + unset($path[$idx]); + // convert special characters back into entities (#3744) + $root[] = str_replace(',', "\\2C", $item); + } + else { + $path[$idx] = substr($item, $pos + 1); + } + } + + return array( + 'root' => implode(',', $root), + 'path' => $path, + ); } }
View file
kolab-webadmin-3.2.2.tar.gz/lib/client/kolab_client_task_resource.php -> kolab-webadmin-3.2.3.tar.gz/lib/client/kolab_client_task_resource.php
Changed
@@ -101,6 +101,8 @@ 'alias' => 'system', 'mailalternateaddress' => 'system', + 'owner' => 'system', + 'member' => 'system', 'uniquemember' => 'system', 'memberurl' => 'system', @@ -117,6 +119,9 @@ 'kolabdelegate' => 'system', 'kolaballowsmtprecipient' => 'system', 'kolaballowsmtpsender' => 'system', + 'kolabtargetfolder' => 'system', + + 'kolabdescattribute' => 'other', ); // Prepare fields
View file
kolab-webadmin-3.2.2.tar.gz/lib/client/kolab_client_task_settings.php -> kolab-webadmin-3.2.3.tar.gz/lib/client/kolab_client_task_settings.php
Changed
@@ -32,7 +32,7 @@ ); protected $form_element_types = array( - 'text', 'select', 'multiselect', 'list', 'list-autocomplete', 'checkbox', 'password', 'ldap_url', + 'text', 'text-separated', 'select', 'multiselect', 'list', 'list-autocomplete', 'checkbox', 'password', 'ldap_url', 'text-quota', 'aci', 'imap_acl', );
View file
kolab-webadmin-3.2.2.tar.gz/lib/ext/Net/LDAP3.php -> kolab-webadmin-3.2.3.tar.gz/lib/ext/Net/LDAP3.php
Changed
@@ -1011,7 +1011,7 @@ return $replica_hosts; } - public function login($username, $password, $domain = null) + public function login($username, $password, $domain = null, &$attributes = null) { $this->_debug("Net_LDAP3::login(\$username = '" . $username . "', \$password = '****', \$domain = '" . $domain . "')"); @@ -1045,6 +1045,12 @@ return null; } + // fetch user attributes if requested + if (!empty($attributes)) { + $attributes = $this->get_entry($entry_dn, $attributes); + $attributes = self::normalize_entry($attributes, true); + } + return $entry_dn; } @@ -1092,7 +1098,7 @@ $this->_debug("Net::LDAP3::login() actual filter: " . $filter); - $result = $this->search($base_dn, $filter, 'sub'); + $result = $this->search($base_dn, $filter, 'sub', $attributes); if (!$result) { $this->_debug("Could not search $base_dn with $filter"); @@ -1108,9 +1114,8 @@ return null; } - $entries = $result->entries(); - $entry = self::normalize_result($entries); - $entry_dn = key($entry); + $entries = $result->entries(true); + $entry_dn = key($entries); $bound = $this->bind($entry_dn, $password); @@ -1119,6 +1124,11 @@ return null; } + // replace attributes list with key-value data + if (!empty($attributes)) { + $attributes = $entries[$entry_dn]; + } + return $entry_dn; } @@ -1690,10 +1700,11 @@ * Turn an LDAP entry into a regular PHP array with attributes as keys. * * @param array $entry Attributes array as retrieved from ldap_get_attributes() or ldap_get_entries() + * @param bool $flat Convert one-element-array values into strings * * @return array Hash array with attributes as keys */ - public static function normalize_entry($entry) + public static function normalize_entry($entry, $flat = false) { $rec = array(); for ($i=0; $i < $entry['count']; $i++) { @@ -1701,6 +1712,10 @@ for ($j=0; $j < $entry[$attr]['count']; $j++) { $rec[$attr][$j] = $entry[$attr][$j]; } + + if ($flat && count($rec[$attr]) == 1) { + $rec[$attr] = $rec[$attr][0]; + } } return $rec; @@ -1718,34 +1733,19 @@ $result = array(); for ($x = 0; $x < $_result['count']; $x++) { - $dn = $_result[$x]['dn']; - $result[$dn] = array(); - for ($y = 0; $y < $_result[$x]['count']; $y++) { - $attr = $_result[$x][$y]; - if ($_result[$x][$attr]['count'] == 1) { - switch ($attr) { - case 'objectclass': - $result[$dn][$attr] = array(strtolower($_result[$x][$attr][0])); - break; - default: - $result[$dn][$attr] = $_result[$x][$attr][0]; - break; - } + $dn = $_result[$x]['dn']; + $entry = self::normalize_entry($_result[$x], true); + + if (!empty($entry['objectclass'])) { + if (is_array($entry['objectclass'])) { + $entry['objectclass'] = array_map('strtolower', $entry['objectclass']); } else { - $result[$dn][$attr] = array(); - for ($z = 0; $z < $_result[$x][$attr]['count']; $z++) { - switch ($attr) { - case 'objectclass': - $result[$dn][$attr][] = strtolower($_result[$x][$attr][$z]); - break; - default: - $result[$dn][$attr][] = $_result[$x][$attr][$z]; - break; - } - } + $entry['objectclass'] = strtolower($entry['objectclass']); } } + + $result[$dn] = $entry; } return $result; @@ -1756,16 +1756,15 @@ switch ($scope) { case 2: return 'sub'; - break; + case 1: return 'one'; - break; + case 0: return 'base'; - break; + default: $this->_debug("Scope $scope is not a valid scope integer"); - break; } } @@ -1780,7 +1779,7 @@ { switch ($scope) { case 'sub': - $function = $ns_function = 'ldap_search'; + $function = $ns_function = 'ldap_search'; break; case 'base': $function = $ns_function = 'ldap_read';
View file
kolab-webadmin-3.2.2.tar.gz/lib/kolab_api_controller.php -> kolab-webadmin-3.2.3.tar.gz/lib/kolab_api_controller.php
Changed
@@ -293,8 +293,6 @@ { Log::trace("Authenticating user: " . $postdata['username']); - $valid = false; - // destroy old session if ($this->session_validate($postdata)) { session_destroy(); @@ -303,38 +301,50 @@ session_start(); $_SESSION['user'] = new User(); + $attributes = null; + $password = $postdata['password']; + $username = $postdata['username']; + $domain = $postdata['domain']; - if (empty($postdata['domain'])) { + // find user domain + if (empty($domain)) { Log::debug("No login domain specified. Attempting to derive from username."); - if (count(explode('@', $postdata['username'])) > 1) { - $login = explode('@', $postdata['username']); + if (count(explode('@', $username)) == 2) { + $login = explode('@', $username); $username = array_shift($login); - $domain = array_shift($login); + $domain = array_shift($login); } else { Log::debug("No domain name space in the username, using the primary domain"); $domain = $this->config->get('kolab', 'primary_domain'); } } - else { - $domain = $postdata['domain']; - } - if (empty($username)) { - $username = $postdata['username']; + // user info requested (it's not possible to get manager info) + if ($postdata['info'] && ($username != 'cn=Directory Manager')) { + $service = $this->get_service('user'); + $attributes = $service->object_attributes('user'); } - $valid = $_SESSION['user']->authenticate($username, $postdata['password'], $domain); + // authenticate + $user_dn = $_SESSION['user']->authenticate($username, $password, $domain, $attributes); // start new (PHP) session - if ($valid) { + if ($user_dn) { $_SESSION['time'] = time(); - return array( + $result = array( 'user' => $_SESSION['user']->get_username(), 'userid' => $_SESSION['user']->get_userid(), 'domain' => $_SESSION['user']->get_domain(), 'session_token' => session_id(), ); + + if (!empty($attributes)) { + $attributes = array($user_dn => $attributes); + $result['info'] = $service->parse_result_attributes('user', $attributes); + } + + return $result; } return false;
View file
kolab-webadmin-3.2.2.tar.gz/lib/kolab_api_service.php -> kolab-webadmin-3.2.3.tar.gz/lib/kolab_api_service.php
Changed
@@ -469,15 +469,12 @@ * * @return array Entry attributes */ - protected function parse_result_attributes($object_name, $attrs = array()) + public function parse_result_attributes($object_name, $attrs = array()) { - //console("parse_result_attributes($object_name, \$attrs = ", $attrs); - if (empty($attrs) || !is_array($attrs)) { return $attrs; } - $auth = Auth::get_instance(); $dn = key($attrs); $attrs = $attrs[$dn]; $extra_attrs = array(); @@ -486,7 +483,6 @@ // Search for attributes associated with the type_id that are not part // of the result returned earlier. Example: nsrole / nsroledn / aci, etc. - // @TODO: this should go to LDAP class if ($type_id) { $uta = $this->object_type_attributes($object_name, $type_id); @@ -506,8 +502,10 @@ // remove attributes not listed in object type definition // @TODO: make this optional? $attributes = array_flip(array_merge($attributes, array($unique_attr))); - $attrs = array_intersect_key($attrs, $attributes); + $attrs = array_intersect_key($attrs, $attributes); } +/* + $auth = Auth::get_instance(); // Insert the persistent, unique attribute if (!array_key_exists($unique_attr, $attrs)) { @@ -522,7 +520,7 @@ $attrs = array_merge($attrs, $extra_attrs); } } - +*/ // Replace unique attribute with 'id' key $attrs['id'] = $attrs[$unique_attr]; unset($attrs[$unique_attr]); @@ -545,6 +543,46 @@ } /** + * Returns all supported attributes of specified object type + * + * @param string $object_name Name of the object (user, group, etc.) + * + * @return array Entry attributes + */ + public function object_attributes($object_name) + { + $unique_attr = self::unique_attribute(); + $object_types = $this->object_types($object_name); + $attributes = array(); + + // because we don't know the object type identifier before + // we get it from LDAP we need to get try attributes of all types + foreach ($object_types as $type) { + $attributes = array_merge( + $attributes, + array_keys((array) $type['attributes']['auto_form_fields']), + array_keys((array) $type['attributes']['form_fields']), + array_keys((array) $type['attributes']['fields']) + ); + } + + // use array_values, because ldap_read() does not like an array + // with removed elements (holes in the index) + $attributes = array_values(array_unique($attributes)); + + if (empty($attributes)) { + $attributes = array('*'); + } + + // Insert the persistent, unique attribute + if (!array_key_exists($unique_attr, $attributes)) { + $attributes[] = $unique_attr; + } + + return $attributes; + } + + /** * Compare two score values * * @param string $s1 Score
View file
kolab-webadmin-3.2.2.tar.gz/lib/kolab_client_api.php -> kolab-webadmin-3.2.3.tar.gz/lib/kolab_client_api.php
Changed
@@ -95,15 +95,18 @@ * * @param string $username User name * @param string $password User password + * @param string $domain User domain + * @param bool $get_info Request user info in result * * @return kolab_client_api_result Request response */ - public function login($username, $password, $domain = null) + public function login($username, $password, $domain = null, $get_info = false) { $query = array( 'username' => $username, 'password' => $password, - 'domain' => $domain + 'domain' => $domain, + 'info' => $get_info ? 1 : 0, ); $response = $this->post('system.authenticate', null, $query);
View file
kolab-webadmin-3.2.2.tar.gz/lib/kolab_client_task.php -> kolab-webadmin-3.2.3.tar.gz/lib/kolab_client_task.php
Changed
@@ -202,7 +202,7 @@ $login = $this->get_input('login', 'POST'); if ($login['username']) { - $result = $this->api->login($login['username'], $login['password'], $login['domain']); + $result = $this->api->login($login['username'], $login['password'], $login['domain'], true); if ($token = $result->get('session_token')) { $user = array( @@ -219,8 +219,11 @@ $user['fullname'] = ucwords($m[1]); } else { - $res = $this->api->get('user.info', array('id' => $user['id'])); - $res = $res->get(); + $res = $result->get('info'); + if (empty($res)) { + $res = $this->api->get('user.info', array('id' => $user['id'])); + $res = $res->get(); + } if (is_array($res) && !empty($res)) { $user['language'] = $res['preferredlanguage']; @@ -912,6 +915,11 @@ ); break; + case 'text-separated': + $result['type'] = kolab_form::INPUT_TEXTAREA; + $result['data-type'] = 'separated'; + break; + default: $result['type'] = kolab_form::INPUT_TEXT; @@ -1062,25 +1070,11 @@ $extra_fields[$idx] = true; - // build auto_attribs and event_fields lists - $is_data = 0; + // build event_fields list if (!empty($field['data'])) { - foreach ($field['data'] as $fd) { - $event_fields[$fd][] = $idx; - if (isset($data[$fd])) { - $is_data++; - } - } - if (count($field['data']) == $is_data) { - $auto_attribs[] = $idx; - } - } - else { - //console("\$field['data'] is empty for \$auto_fields[\$idx] (idx: $idx)"); - $auto_attribs[] = $idx; - // Unset the $auto_field array key to prevent the form field from - // becoming disabled/readonly - unset($auto_fields[$idx]); + foreach ($field['data'] as $fd) { + $event_fields[$fd][] = $idx; + } } } @@ -1104,6 +1098,33 @@ } } + // Re-parse auto_fields again, to get attributes for auto-generation + // Need to do this after form_fields have been initialized (#2980) + foreach ($auto_fields as $idx => $field) { + // build auto_attribs and event_fields lists + if (!empty($field['data'])) { + $is_data = 0; + foreach ($field['data'] as $fd) { + if (!isset($data[$fd]) && isset($fields[$fd]['value'])) { + $data[$fd] = $fields[$fd]['value']; + } + if (isset($data[$fd])) { + $is_data++; + } + } + + if (count($field['data']) == $is_data) { + $auto_attribs[] = $idx; + } + } + else { + $auto_attribs[] = $idx; + // Unset the $auto_fields array key to prevent the form field from + // becoming disabled/readonly + unset($auto_fields[$idx]); + } + } + // Get the rights on the entry and attribute level $data['effective_rights'] = $this->effective_rights($name, $data['id']); $attribute_rights = (array) $data['effective_rights']['attribute']; @@ -1682,7 +1703,7 @@ $i++; $cells = array(); $cells[] = array('class' => 'name', 'body' => kolab_html::escape($item), - 'onclick' => "kadm.command('$task.info', '$idx')"); + 'onclick' => "kadm.command('$task.info', '" . kolab_utils::js_escape($idx) . "')"); $rows[] = array('id' => $i, 'class' => implode(' ', $class), 'cells' => $cells); } }
View file
kolab-webadmin-3.2.2.tar.gz/lib/kolab_recipient_policy.php -> kolab-webadmin-3.2.3.tar.gz/lib/kolab_recipient_policy.php
Changed
@@ -23,9 +23,10 @@ +--------------------------------------------------------------------------+ */ -class kolab_recipient_policy { - - static function format() { +class kolab_recipient_policy +{ + static function format() + { $_args = func_get_args(); $args = array(); @@ -139,56 +140,9 @@ } $primary_mail = $conf->get_raw($userdata['domain'], 'primary_mail'); - - preg_match_all('/%\((\w+)\)s/', $primary_mail, $substrings); - - // Update userdata array - for ($x = 0; $x < count($substrings[0]); $x++) { - if (array_key_exists($substrings[1][$x], $userdata)) { - if (!empty($substrings[2][$x])) { - if (!empty($substrings[3][$x])) { - $primary_mail = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - substr( - $userdata[$substrings[1][$x]], - $substrings[2][$x], - $substrings[3][$x] - ), - $primary_mail - ); - } else { - $primary_mail = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - substr( - $userdata[$substrings[1][$x]], - $substrings[2][$x] - ), - $primary_mail - ); - } - } elseif (!empty($substrings[3][$x])) { - $primary_mail = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - substr( - $userdata[$substrings[1][$x]], - 0, - $substrings[3][$x] - ), - $primary_mail - ); - } else { - $primary_mail = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - $userdata[$substrings[1][$x]], - $primary_mail - ); - } - } else { - Log::error("Recipient policy finds that key " . $substrings[1][$x] . " does not exist in \$userdata (primary_mail)"); - } - } - + $primary_mail = self::apply_formats($primary_mail, $userdata); $parsed_email = self::parse_email($primary_mail); + return $parsed_email; } @@ -385,78 +339,7 @@ ); $policy_uid = preg_replace('/(\{\d+\})/', '%s', $policy_uid); - - preg_match_all('/%\((\w+)\)s/', $policy_uid, $substrings); - - // Update userdata array - for ($x = 0; $x < count($substrings[0]); $x++) { - if (array_key_exists($substrings[1][$x], $userdata)) { - if (!empty($substrings[2][$x])) { - if (!empty($substrings[3][$x])) { - $policy_uid = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - substr( - $userdata[$substrings[1][$x]], - $substrings[2][$x], - $substrings[3][$x] - ), - $policy_uid - ); - - } else { - $policy_uid = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - substr( - $userdata[$substrings[1][$x]], - $substrings[2][$x] - ), - $policy_uid - ); - - } - } elseif (!empty($substrings[3][$x])) { - $policy_uid = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - substr( - $userdata[$substrings[1][$x]], - 0, - $substrings[3][$x] - ), - $policy_uid - ); - - } else { - $policy_uid = preg_replace( - '/%\(' . $substrings[1][$x]. '\)s/', - $userdata[$substrings[1][$x]], - $policy_uid - ); - - } - } - } - - preg_match_all('/.*\'(.*)\'\[(\d+):(\d+)\].*/', $policy_uid, $substrings); - - for ($x = 0; $x < count($substrings[0]); $x++) { - if (!empty($substrings[2][$x])) { - $start = $substrings[2][$x]; - } else { - $start = 0; - } - - if (!empty($substrings[3][$x])) { - $end = $substrings[3][$x]; - } else { - $end = 0; - } - - $policy_uid = preg_replace( - "/'" . $substrings[1][$x] . "'\[" . $substrings[2][$x] . ':' . $substrings[3][$x] . "\]/", - substr($substrings[1][$x], $start, $end), - $policy_uid - ); - } + $policy_uid = self::apply_formats($policy_uid, $userdata); foreach ($functions as $match => $replace) { while (preg_match('/' . $match . '/', $policy_uid, $strings)) { @@ -510,4 +393,73 @@ return $email_parts[0] . '@' . $email_parts[1]; } + /** + * Implements string replacement according to defined format + */ + static private function apply_formats($subject, $userdata) + { + preg_match_all('/%\((\w+)\)s/', $subject, $substrings); + + // Update userdata array + for ($x = 0; $x < count($substrings[0]); $x++) { + if (array_key_exists($substrings[1][$x], $userdata)) { + if (!empty($substrings[2][$x])) { + if (!empty($substrings[3][$x])) { + $subject = preg_replace( + '/%\(' . $substrings[1][$x]. '\)s/', + substr($userdata[$substrings[1][$x]], $substrings[2][$x], $substrings[3][$x]), + $subject + ); + } + else { + $subject = preg_replace( + '/%\(' . $substrings[1][$x]. '\)s/', + substr($userdata[$substrings[1][$x]], $substrings[2][$x]), + $subject + ); + } + } + else if (!empty($substrings[3][$x])) { + $subject = preg_replace( + '/%\(' . $substrings[1][$x]. '\)s/', + substr($userdata[$substrings[1][$x]], 0, $substrings[3][$x]), + $subject + ); + } + else { + $subject = preg_replace( + '/%\(' . $substrings[1][$x]. '\)s/', + $userdata[$substrings[1][$x]], + $subject + ); + } + } + } +
View file
kolab-webadmin-3.2.2.tar.gz/lib/kolab_utils.php -> kolab-webadmin-3.2.3.tar.gz/lib/kolab_utils.php
Changed
@@ -206,4 +206,21 @@ return $str; } + + /** + * Escape string for use in javascript code + * + * @param string $str String + * + * @return string Escaped string + */ + public static function js_escape($str) + { + return strtr($str, array( + '"' => '\\"', + "'" => "\\'", + "\\" => "\\\\", + "\n" => '\n', + )); + } }
View file
kolab-webadmin-3.2.2.tar.gz/lib/locale/en_US.php -> kolab-webadmin-3.2.3.tar.gz/lib/locale/en_US.php
Changed
@@ -243,6 +243,7 @@ $LANG['resource.edit.success'] = 'Resource updated successfully.'; $LANG['resource.kolabtargetfolder'] = 'Target Folder'; $LANG['resource.kolabinvitationpolicy'] = 'Invitation Policy'; +$LANG['resource.kolabdescattribute'] = 'Attributes'; $LANG['resource.list'] = 'Resource (Collection) List'; $LANG['resource.mail'] = 'Mail Address'; $LANG['resource.member'] = 'Collection Members';
View file
kolab-webadmin-3.2.2.tar.gz/public_html/js/kolab_admin.js -> kolab-webadmin-3.2.3.tar.gz/public_html/js/kolab_admin.js
Changed
@@ -806,6 +806,11 @@ data.json = kadm.form_aci_element_submit(this.name, data.json, form); }); + // text-separated fields (convert text into array) + $('textarea[data-type="separated"]:not(:disabled)', form).each(function() { + data.json[this.name] = data.json[this.name] ? data.json[this.name].split(/[\r\n]+/) : ''; + }); + // quota inputs $('input[data-type="quota"]', form).each(function() { var unit = $('select[name="' + this.name + '-unit"]').val(); @@ -2891,7 +2896,7 @@ $('select[name="attr_type"]').val(type); $('select[name="attr_value"]').val(attr ? data.valtype : 'normal'); - $('select[name="attr_validate"]').val(data.validate || ''); + $('select[name="attr_validate"]').val(data.validate || 'default'); $('input[name="attr_default"]').val(data['default'] || ''); $('input[name="attr_optional"]').prop('checked', attr ? data.optional : false); $('input[name="attr_data"]').val(data.data || '');
View file
kolab-webadmin-3.2.2.tar.gz/public_html/skins/default/style.css -> kolab-webadmin-3.2.3.tar.gz/public_html/skins/default/style.css
Changed
@@ -120,6 +120,10 @@ padding: 1px 5px; } +table.form select { + max-width: 500px; +} + table.form tr.required input, table.form tr.required select, table.form tr.required textarea {
View file
kolab-webadmin-3.2.2.tar.gz/public_html/skins/default/templates/error.html -> kolab-webadmin-3.2.3.tar.gz/public_html/skins/default/templates/error.html
Changed
@@ -7,12 +7,12 @@ <link rel="shortcut icon" type="image/png" href="{$skin_path}images/favicon.png" /> </head> <body> + <img id="logo" src="{$skin_path}images/logo.png" alt="logo" /> <div id="message" class="error" style="display: block"> <div> <span><b>{$engine->translate('error')} {$error_code}:</b><br />{$error_message}</span> </div> </div> - <div id="logo"></div> <div id="topmenu"></div> <div id="navigation"></div> <div id="task_navigation"></div>
View file
kolab-webadmin-3.2.2.tar.gz/public_html/skins/default/templates/login.html -> kolab-webadmin-3.2.3.tar.gz/public_html/skins/default/templates/login.html
Changed
@@ -9,7 +9,7 @@ <script src="js/kolab_admin.js"></script> </head> <body> - <div id="logo"></div> + <img id="logo" src="{$skin_path}images/logo.png" alt="logo" /> <div id="topmenu"></div> <div id="navigation"></div> <div id="task_navigation"></div>
View file
kolab-webadmin-3.2.2.tar.gz/public_html/skins/default/templates/main.html -> kolab-webadmin-3.2.3.tar.gz/public_html/skins/default/templates/main.html
Changed
@@ -12,7 +12,7 @@ <script src="{$skin_path}ui.js"></script> </head> <body> - <div id="logo" onclick="document.location='.'"></div> + <img id="logo" src="{$skin_path}images/logo.png" alt="logo" onclick="document.location='.'" /> <div id="topmenu"> <span class="login">{$user.fullname}</span> <span id="domain-selector" class="domain">
View file
kolab-webadmin-3.2.2.tar.gz/public_html/skins/default/templates/signup.html -> kolab-webadmin-3.2.3.tar.gz/public_html/skins/default/templates/signup.html
Changed
@@ -14,7 +14,7 @@ </head> <body> <div id="bodybox"> - <div id="logo"></div> + <img id="logo" src="{$skin_path}images/logo.png" alt="logo" /> <div id="content"> <div id="task_content" class="signup"> <h1>{$engine->translate('signup.headline')}</h1>
View file
kolab-webadmin-3.2.2.tar.gz/public_html/skins/default/ui.js -> kolab-webadmin-3.2.3.tar.gz/public_html/skins/default/ui.js
Changed
@@ -170,6 +170,11 @@ function ui_load() { domain_selector(); + + // set minimum width of the page + var width = $('#logo').width() + 50; + $('#navigation li').each(function() { width += $(this).width(); }); + $('body').css('min-width', width); }; // API response handler
View file
kolab-webadmin.dsc
Changed
@@ -2,7 +2,7 @@ Source: kolab-webadmin Binary: kolab-webadmin Architecture: all -Version: 3.2.2-0~kolab1 +Version: 3.2.3-0~kolab1 Maintainer: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> Uploaders: Paul Klos <kolab@klos2day.nl> Homepage: http://www.kolab.org/ @@ -13,5 +13,5 @@ Package-List: kolab-webadmin deb admin extra Files: - 00000000000000000000000000000000 0 kolab-webadmin-3.2.2.tar.gz + 00000000000000000000000000000000 0 kolab-webadmin-3.2.3.tar.gz 00000000000000000000000000000000 0 debian.tar.gz
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.