aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArthur Schiwon <blizzz@owncloud.com>2013-05-25 11:03:58 +0200
committerArthur Schiwon <blizzz@owncloud.com>2013-05-25 11:03:58 +0200
commit86d72b9a61f5e8a9b57c6f0bb431eb6722aa12a3 (patch)
tree71b3acdebbd8ad880fe3e3ceac96d302211e52fd
parentbfa715768a22430273db956a14ed1a3cb964c743 (diff)
downloadnextcloud-server-86d72b9a61f5e8a9b57c6f0bb431eb6722aa12a3.tar.gz
nextcloud-server-86d72b9a61f5e8a9b57c6f0bb431eb6722aa12a3.zip
LDAP: fix possible recursion
-rw-r--r--apps/user_ldap/lib/connection.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/apps/user_ldap/lib/connection.php b/apps/user_ldap/lib/connection.php
index 8a61775a6f2..409f3758792 100644
--- a/apps/user_ldap/lib/connection.php
+++ b/apps/user_ldap/lib/connection.php
@@ -635,10 +635,17 @@ class Connection {
* Binds to LDAP
*/
public function bind() {
+ static $getConnectionResourceAttempt = false;
if(!$this->config['ldapConfigurationActive']) {
return false;
}
+ if($getConnectionResourceAttempt) {
+ $getConnectionResourceAttempt = false;
+ return false;
+ }
+ $getConnectionResourceAttempt = true;
$cr = $this->getConnectionResource();
+ $getConnectionResourceAttempt = false;
if(!is_resource($cr)) {
return false;
}