Skip to content

Instantly share code, notes, and snippets.

@franz-isx
Created June 11, 2012 11:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save franz-isx/2909645 to your computer and use it in GitHub Desktop.
Save franz-isx/2909645 to your computer and use it in GitHub Desktop.
TeamCal LDAP v3 login bugfix
Index: includes/tclogin.class.php
===================================================================
--- includes/tclogin.class.php (Revision 129)
+++ includes/tclogin.class.php (Arbeitskopie)
@@ -258,9 +258,8 @@
if (!$uidpass) { return 91; } // Force Fail on NULL password
$ds=ldap_connect($host,$port); // Is always a ressource even if no connection possible (patch by Franz Gregor)
- if (!@ldap_bind($ds)) return 93; // Test anonymous bind => Unable to connect to LDAP server (patch by Franz Gregor)
-
ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3); // Use v3 when possible
+ if (!@ldap_bind($ds)) return 93; // Test anonymous bind => Unable to connect to LDAP server (patch by Franz Gregor)
if ($ldaptls && !ldap_start_tls($ds)) return 94;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment