Branch 'pykolab-0.6' - 4 commits - pykolab/auth pykolab/setup share/templates

Jeroen van Meeuwen vanmeeuwen at kolabsys.com
Mon Feb 10 10:34:16 CET 2014


 pykolab/auth/ldap/auth_cache.py                            |    1 
 pykolab/setup/setup_roundcube.py                           |    1 
 share/templates/roundcubemail/config.inc.php.tpl           |    3 +
 share/templates/roundcubemail/kolab_delegation.inc.php.tpl |   26 +++++++++++++
 4 files changed, 30 insertions(+), 1 deletion(-)

New commits:
commit 7023454904b0a030b37f9b3fe8ab66c942be77b4
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Mon Feb 10 10:33:35 2014 +0100

    Actually commit the auth_cache db purge_entries() deletion of stale records

diff --git a/pykolab/auth/ldap/auth_cache.py b/pykolab/auth/ldap/auth_cache.py
index ba14262..35fbebb 100644
--- a/pykolab/auth/ldap/auth_cache.py
+++ b/pykolab/auth/ldap/auth_cache.py
@@ -116,6 +116,7 @@ def set_entry(key, value):
 
 def purge_entries(db):
     db.query(Entry).filter(Entry.last_change <= (datetime.datetime.now() - datetime.timedelta(1))).delete()
+    db.commit()
 
 def init_db():
     """


commit c89ae37758b918354e4fb60820c554921ced88f2
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat Feb 8 12:51:21 2014 +0100

    Add kolab_delegation configuration

diff --git a/pykolab/setup/setup_roundcube.py b/pykolab/setup/setup_roundcube.py
index 215da69..e375f9b 100644
--- a/pykolab/setup/setup_roundcube.py
+++ b/pykolab/setup/setup_roundcube.py
@@ -92,6 +92,7 @@ def execute(*args, **kw):
             'calendar.inc.php',
             'config.inc.php',
             'kolab_auth.inc.php',
+            'kolab_delegation.inc.php',
             'kolab_files.inc.php',
             'kolab_folders.inc.php',
             'libkolab.inc.php',
diff --git a/share/templates/roundcubemail/kolab_delegation.inc.php.tpl b/share/templates/roundcubemail/kolab_delegation.inc.php.tpl
new file mode 100644
index 0000000..563534d
--- /dev/null
+++ b/share/templates/roundcubemail/kolab_delegation.inc.php.tpl
@@ -0,0 +1,26 @@
+<?php
+    // This will overwrite defined LDAP filter
+    // Note: LDAP addressbook defined for kolab_auth plugin is used
+    \$config['kolab_delegation_filter'] = '(|(objectClass=kolabInetOrgPerson)(objectclass=kolabsharedfolder))';
+
+    // Delegates field (from fieldmap configuration) to get delegates list
+    // Note: This is a field name, not LDAP attribute name
+    // Note: LDAP addressbook defined for kolab_auth plugin is used
+    \$config['kolab_delegation_delegate_field'] = 'kolabDelegate';
+
+    // User authentication ID field (from fieldmap configuration)
+    // See kolab_auth plugin config
+    \$config['kolab_delegation_login_field'] = 'email';
+
+    // Use this fields (from fieldmap configuration) for identities
+    // If the value array contains more than one field, first non-empty will be used
+    // Note: These are not LDAP attributes, but field names in config
+    // Note: If there are more than one email address, as many identities will be created
+    // See kolab_auth plugin config
+    \$config['kolab_delegation_name_field']  = array('name', 'cn');
+    \$config['kolab_delegation_email_field'] = array('email');
+
+    // Remove all user identities which do not match the users primary or alias
+    // addresses and delegators addresses
+    \$config['kolab_delegation_purge_identities'] = false;
+?>


commit d7e2ecacd63ab37b03a58fc8570b81bccc1a6fcb
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat Feb 8 12:47:10 2014 +0100

    Add the kolab_delegation plugin

diff --git a/share/templates/roundcubemail/config.inc.php.tpl b/share/templates/roundcubemail/config.inc.php.tpl
index 68e5a64..4582c58 100644
--- a/share/templates/roundcubemail/config.inc.php.tpl
+++ b/share/templates/roundcubemail/config.inc.php.tpl
@@ -53,6 +53,7 @@
             'kolab_activesync',
             'kolab_addressbook',
             'kolab_config',
+            'kolab_delegation',
             'kolab_files',
             'kolab_folders',
             'libkolab',


commit e717bdb4656bc52e0625f7d38bd76f522356bf50
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat Feb 8 12:46:42 2014 +0100

    Make sure the kolab_auth plugin is loaded first, so it can disable the loading of other plugins

diff --git a/share/templates/roundcubemail/config.inc.php.tpl b/share/templates/roundcubemail/config.inc.php.tpl
index 74b75ff..68e5a64 100644
--- a/share/templates/roundcubemail/config.inc.php.tpl
+++ b/share/templates/roundcubemail/config.inc.php.tpl
@@ -45,13 +45,13 @@
 
     // Plugins
     \$config['plugins'] = array(
+            'kolab_auth',
             'acl',
             'archive',
             'calendar',
             'jqueryui',
             'kolab_activesync',
             'kolab_addressbook',
-            'kolab_auth',
             'kolab_config',
             'kolab_files',
             'kolab_folders',




More information about the commits mailing list