diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/password/config.inc.php.dist | 6 | ||||
-rw-r--r-- | plugins/password/package.xml | 34 | ||||
-rw-r--r-- | plugins/password/password.php | 12 |
3 files changed, 41 insertions, 11 deletions
diff --git a/plugins/password/config.inc.php.dist b/plugins/password/config.inc.php.dist index 8d7b433af..e960bbe00 100644 --- a/plugins/password/config.inc.php.dist +++ b/plugins/password/config.inc.php.dist @@ -25,6 +25,12 @@ $rcmail_config['password_log'] = false; // will be not available (no Password tab in Settings) $rcmail_config['password_login_exceptions'] = null; +// Array of hosts that support password changing. Default is NULL. +// Listed hosts will feature a Password option in Settings; others will not. +// Example: +//$rcmail_config['password_hosts'] = array('mail.example.com', 'mail2.example.org'); +$rcmail_config['password_hosts'] = null; + // SQL Driver options // ------------------ diff --git a/plugins/password/package.xml b/plugins/password/package.xml index 29d222409..9a056dec6 100644 --- a/plugins/password/package.xml +++ b/plugins/password/package.xml @@ -15,9 +15,9 @@ <email>alec@alec.pl</email> <active>yes</active> </lead> - <date>2012-03-07</date> + <date>2012-11-15</date> <version> - <release>3.1</release> + <release>3.2</release> <api>2.0</api> </version> <stability> @@ -26,13 +26,8 @@ </stability> <license uri="http://www.gnu.org/licenses/gpl-2.0.html">GNU GPLv2</license> <notes> -- Added pw_usermod driver (#1487826) -- Added option password_login_exceptions (#1487826) -- Added domainfactory driver (#1487882) -- Added DBMail driver (#1488281) -- Helper files moved to helpers/ directory from drivers/ -- Added Expect driver (#1488363) -- Added Samba password (#1488364) +- Fix wrong (non-specific) error message on crypt or connection error (#1488808) +- Added option to define IMAP hosts that support password changes - password_hosts </notes> <contents> <dir baseinstalldir="/" name="/"> @@ -331,5 +326,26 @@ - Fixed drivers namespace issues </notes> </release> + <release> + <date>2012-03-07</date> + <version> + <release>3.1</release> + <api>2.0</api> + </version> + <stability> + <release>stable</release> + <api>stable</api> + </stability> + <license uri="http://www.gnu.org/licenses/gpl-2.0.html">GNU GPLv2</license> + <notes> +- Added pw_usermod driver (#1487826) +- Added option password_login_exceptions (#1487826) +- Added domainfactory driver (#1487882) +- Added DBMail driver (#1488281) +- Helper files moved to helpers/ directory from drivers/ +- Added Expect driver (#1488363) +- Added Samba password (#1488364) + </notes> + </release> </changelog> </package> diff --git a/plugins/password/password.php b/plugins/password/password.php index 58b6f8cd9..028a58d3e 100644 --- a/plugins/password/password.php +++ b/plugins/password/password.php @@ -3,7 +3,7 @@ /* +-------------------------------------------------------------------------+ | Password Plugin for Roundcube | - | @version @package_version@ | + | @version @package_version@ | | | | Copyright (C) 2009-2010, Roundcube Dev. | | | @@ -56,7 +56,13 @@ class password extends rcube_plugin $this->load_config(); - // Exceptions list + // Host exceptions + $hosts = $rcmail->config->get('password_hosts'); + if (!empty($hosts) && !in_array($_SESSION['storage_host'], $hosts)) { + return; + } + + // Login exceptions if ($exceptions = $rcmail->config->get('password_login_exceptions')) { $exceptions = array_map('trim', (array) $exceptions); $exceptions = array_filter($exceptions); @@ -274,8 +280,10 @@ class password extends rcube_plugin return; case PASSWORD_CRYPT_ERROR; $reason = $this->gettext('crypterror'); + break; case PASSWORD_CONNECT_ERROR; $reason = $this->gettext('connecterror'); + break; case PASSWORD_ERROR: default: $reason = $this->gettext('internalerror'); |