From b07426f0c55f2fd2126dd2080e6a89bd334017f9 Mon Sep 17 00:00:00 2001
From: Aleksander Machniak <alec@alec.pl>
Date: Thu, 06 Jun 2013 02:58:59 -0400
Subject: [PATCH] Make LDAP cache engine configurable via ldap_cache and ldap_cache_ttl options

---
 config/main.inc.php.dist |   19 ++++++++++++++-----
 1 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/config/main.inc.php.dist b/config/main.inc.php.dist
index 709e5cd..4cf94c7 100644
--- a/config/main.inc.php.dist
+++ b/config/main.inc.php.dist
@@ -128,6 +128,9 @@
 // Enables messages cache. Only 'db' cache is supported.
 $rcmail_config['messages_cache'] = false;
 
+// lifetime of message cache
+// possible units: s, m, h, d, w
+$rcmail_config['message_cache_lifetime'] = '10d';
 
 // ----------------------------------
 // SMTP
@@ -170,11 +173,21 @@
 // SMTP HELO host 
 // Hostname to give to the remote server for SMTP 'HELO' or 'EHLO' messages 
 // Leave this blank and you will get the server variable 'server_name' or 
-// localhost if that isn't defined. 
+// localhost if that isn't defined.
 $rcmail_config['smtp_helo_host'] = '';
 
 // SMTP connection timeout, in seconds. Default: 0 (no limit)
 $rcmail_config['smtp_timeout'] = 0;
+
+// ----------------------------------
+// LDAP
+// ----------------------------------
+
+// Type of LDAP cache. Supported values: 'db', 'apc' and 'memcache'.
+$rcmail_config['ldap_cache'] = 'db';
+
+// Lifetime of LDAP cache. Possible units: s, m, h, d, w
+$rcmail_config['ldap_cache_ttl'] = '10m';
 
 // ----------------------------------
 // SYSTEM
@@ -209,10 +222,6 @@
 
 // use this folder to store temp files (must be writeable for apache user)
 $rcmail_config['temp_dir'] = 'temp/';
-
-// lifetime of message cache
-// possible units: s, m, h, d, w
-$rcmail_config['message_cache_lifetime'] = '10d';
 
 // enforce connections over https
 // with this option enabled, all non-secure connections will be redirected.

--
Gitblit v1.9.1