summaryrefslogtreecommitdiff
path: root/plugins/LdapAuthentication
diff options
context:
space:
mode:
authorCraig Andrews <candrews@integralblue.com>2009-11-18 12:57:37 -0500
committerCraig Andrews <candrews@integralblue.com>2009-11-18 12:57:37 -0500
commit1d6bacc681eca89b7c20bb96fbacf5bcb8434d88 (patch)
treecb0bd06169d475ad1c8f8e1e3ad7b6aba9af0b86 /plugins/LdapAuthentication
parentad627ac45137cb11c9f5d961ac93cd192a2fc423 (diff)
Improved parameter checking
Diffstat (limited to 'plugins/LdapAuthentication')
-rw-r--r--plugins/LdapAuthentication/LdapAuthenticationPlugin.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/LdapAuthentication/LdapAuthenticationPlugin.php b/plugins/LdapAuthentication/LdapAuthenticationPlugin.php
index ad5dd3a02..664529497 100644
--- a/plugins/LdapAuthentication/LdapAuthenticationPlugin.php
+++ b/plugins/LdapAuthentication/LdapAuthenticationPlugin.php
@@ -63,6 +63,8 @@ class LdapAuthenticationPlugin extends AuthenticationPlugin
if(!isset($this->attributes['username'])){
throw new Exception("must specify a username attribute");
}
+ if($this->password_changeable && (! isset($this->attributes['password']) || !isset($this->password_encoding))){
+ throw new Exception("if password_changeable is set, the password attribute and password_encoding must also be specified");
}
//---interface implementation---//