Removed hardcoding of URI. libpam-csc-1.1
authorDavid Bartley <dtbartle@csclub.uwaterloo.ca>
Mon, 23 Jul 2007 20:16:05 +0000 (16:16 -0400)
committerDavid Bartley <dtbartle@csclub.uwaterloo.ca>
Mon, 23 Jul 2007 20:16:05 +0000 (16:16 -0400)
debian/changelog
pam_csc.c

index b0bbc94..82eff95 100644 (file)
@@ -1,3 +1,9 @@
+libpam-csc (1.1) unstable; urgency=low
+
+  * Removed hardcoding of URI.
+
+ -- David Bartley <dtbartle@csclub.uwaterloo.ca>  Fri, 27 Jul 2007 08:40:21 -0400
+
 libpam-csc (1.0) unstable; urgency=low
 
   * Initial Release.
 libpam-csc (1.0) unstable; urgency=low
 
   * Initial Release.
index 79dd69d..d0c026e 100644 (file)
--- a/pam_csc.c
+++ b/pam_csc.c
@@ -12,8 +12,6 @@
 #include <syslog.h>
 #include <pwd.h>
 
 #include <syslog.h>
 #include <pwd.h>
 
-#define PAM_CSC_LDAP_URI \
-    "ldap://caffeine.csclub.uwaterloo.ca ldap://perpugilliam.csclub.uwaterloo.ca"
 #define PAM_CSC_LDAP_USER_BASE_DN       "ou=People,dc=csclub,dc=uwaterloo,dc=ca"
 #define PAM_CSC_LDAP_GROUP_BASE_DN      "ou=Group,dc=csclub,dc=uwaterloo,dc=ca"
 #define PAM_CSC_LDAP_TIMEOUT            5
 #define PAM_CSC_LDAP_USER_BASE_DN       "ou=People,dc=csclub,dc=uwaterloo,dc=ca"
 #define PAM_CSC_LDAP_GROUP_BASE_DN      "ou=Group,dc=csclub,dc=uwaterloo,dc=ca"
 #define PAM_CSC_LDAP_TIMEOUT            5
@@ -105,7 +103,7 @@ int check_user(const char* username, enum check_user_type_t checkType)
     }
 
     /* connect and bind */
     }
 
     /* connect and bind */
-    WARN_LDAP( ldap_initialize(&ld, PAM_CSC_LDAP_URI) )
+    WARN_LDAP( ldap_create(&ld) )
     WARN_NEG1( ldap_simple_bind(ld, NULL, NULL) )
 
     WARN_ZERO( usernameEscaped = escape_ldap_string(username) );
     WARN_NEG1( ldap_simple_bind(ld, NULL, NULL) )
 
     WARN_ZERO( usernameEscaped = escape_ldap_string(username) );