mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Remove IPAdmin.simple_bind_s
Part of the work for: https://fedorahosted.org/freeipa/ticket/2660
This commit is contained in:
committed by
Martin Kosek
parent
1ee66ffe03
commit
f7a4cceb97
@@ -375,7 +375,7 @@ class CADSInstance(service.Service):
|
||||
|
||||
def enable_ssl(self):
|
||||
conn = ipaldap.IPAdmin(self.fqdn, port=DEFAULT_DSPORT)
|
||||
conn.simple_bind_s(DN(('cn', 'directory manager')), self.dm_password)
|
||||
conn.do_simple_bind(DN(('cn', 'directory manager')), self.dm_password)
|
||||
|
||||
mod = [(ldap.MOD_REPLACE, "nsSSLClientAuth", "allowed"),
|
||||
(ldap.MOD_REPLACE, "nsSSL3Ciphers",
|
||||
@@ -1055,7 +1055,7 @@ class CAInstance(service.Service):
|
||||
# the appropriate groups so it can issue certificates without
|
||||
# manual intervention.
|
||||
conn = ipaldap.IPAdmin(self.fqdn, self.ds_port)
|
||||
conn.simple_bind_s(DN(('cn', 'Directory Manager')), self.dm_password)
|
||||
conn.do_simple_bind(DN(('cn', 'Directory Manager')), self.dm_password)
|
||||
|
||||
decoded = base64.b64decode(self.ra_cert)
|
||||
|
||||
|
||||
@@ -463,7 +463,8 @@ class DsInstance(service.Service):
|
||||
root_logger.debug("Waiting for memberof task to complete.")
|
||||
conn = ipaldap.IPAdmin(self.fqdn)
|
||||
if self.dm_password:
|
||||
conn.simple_bind_s(DN(('cn', 'directory manager')), self.dm_password)
|
||||
conn.do_simple_bind(
|
||||
DN(('cn', 'directory manager')), self.dm_password)
|
||||
else:
|
||||
conn.do_sasl_gssapi_bind()
|
||||
replication.wait_for_task(conn, dn)
|
||||
@@ -557,7 +558,7 @@ class DsInstance(service.Service):
|
||||
dsdb.create_pin_file()
|
||||
|
||||
conn = ipaldap.IPAdmin(self.fqdn)
|
||||
conn.simple_bind_s(DN(('cn', 'directory manager')), self.dm_password)
|
||||
conn.do_simple_bind(DN(('cn', 'directory manager')), self.dm_password)
|
||||
|
||||
mod = [(ldap.MOD_REPLACE, "nsSSLClientAuth", "allowed"),
|
||||
(ldap.MOD_REPLACE, "nsSSL3Ciphers",
|
||||
|
||||
@@ -1613,7 +1613,7 @@ class IPAdmin(LDAPClient):
|
||||
|
||||
def do_simple_bind(self, binddn=DN(('cn', 'directory manager')), bindpw="",
|
||||
timeout=DEFAULT_TIMEOUT):
|
||||
self.__bind_with_wait(self.simple_bind_s, timeout, binddn, bindpw)
|
||||
self.__bind_with_wait(self.conn.simple_bind_s, timeout, binddn, bindpw)
|
||||
|
||||
def do_sasl_gssapi_bind(self, timeout=DEFAULT_TIMEOUT):
|
||||
self.__bind_with_wait(
|
||||
@@ -1716,10 +1716,6 @@ class IPAdmin(LDAPClient):
|
||||
# FIXME: for backwards compatibility only
|
||||
return self.conn.encode(*args, **kwargs)
|
||||
|
||||
def simple_bind_s(self, *args, **kwargs):
|
||||
# FIXME: for backwards compatibility only
|
||||
return self.conn.simple_bind_s(*args, **kwargs)
|
||||
|
||||
def unbind(self, *args, **kwargs):
|
||||
# FIXME: for backwards compatibility only
|
||||
return self.conn.unbind(*args, **kwargs)
|
||||
|
||||
Reference in New Issue
Block a user