From c2c72981c1fe2b8e36c61915d6eecb3fdb174cae Mon Sep 17 00:00:00 2001 From: John Gaunt Date: Tue, 2 Nov 2021 09:49:34 -0400 Subject: [PATCH] updated variable name --- seafile-ldap.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/seafile-ldap.py b/seafile-ldap.py index 27b2298..13d9574 100644 --- a/seafile-ldap.py +++ b/seafile-ldap.py @@ -101,20 +101,20 @@ dbCharset = config['Database']['CONNECTION_CHARSET'] logger.debug("DB Engine: {0}, DB Host: {1}, DB Port: {2}, DB User: {3}, DB Name: {4}, DB Connection Charset: {5}".format(dbEngine, dbHost, dbPort, dbUser, dbName, dbCharset)) # ldap Config -ldapServer = config['LDAP']['HOST'] +ldapHost = config['LDAP']['HOST'] #ldapPort = config['LDAP SERVER'].getint('port') #ldapSSL = config['LDAP SERVER'].getboolean('ssl') ldapBase = config['LDAP']['BASE'] ldapUserDN = config['LDAP']['USER_DN'] ldapUserPassword = config['LDAP']['PASSWORD'] ldapFilter = config['LDAP']['FILTER'] -logger.debug("LDAP Server: {0}, LDAP Base: {1}, LDAP User DN: {2}, LDAP Filter: {3}".format(ldapServer, ldapBase, ldapUserDN, ldapFilter)) +logger.debug("LDAP Host: {0}, LDAP Base: {1}, LDAP User DN: {2}, LDAP Filter: {3}".format(ldapHost, ldapBase, ldapUserDN, ldapFilter)) logger.debug("Finished reading the config.") # setup the server -server = Server(serverDNS, port=serverPort, use_ssl=serverSSL) -logger.debug("Setup server connection uri: {0}".format(server)) +ldapServer = Server(ldapHost) +logger.debug("Setup server connection uri: {0}".format(ldapServer)) try: ldap = Connection(server, bindAccount, bindPassword, auto_bind=True) except core.exceptions.LDAPBindError as e: