diff options
author | Petr Viktorin <pviktori@redhat.com> | 2013-01-28 12:12:04 -0500 |
---|---|---|
committer | Martin Kosek <mkosek@redhat.com> | 2013-03-01 16:59:46 +0100 |
commit | f9f6cd6e3a907f3bb205f5121727f4f94acfeaef (patch) | |
tree | 1b4aa321eafcef4b73ca11f3ba1b112a3d19f9b7 /ipaserver/ipaldap.py | |
parent | 8f44811a9570e2a0dbc821b6ca48748a5d6eace7 (diff) | |
download | freeipa-f9f6cd6e3a907f3bb205f5121727f4f94acfeaef.tar.gz freeipa-f9f6cd6e3a907f3bb205f5121727f4f94acfeaef.tar.xz freeipa-f9f6cd6e3a907f3bb205f5121727f4f94acfeaef.zip |
Replace IPAdmin.start_tls_s by an __init__ argument
Part of the work for: https://fedorahosted.org/freeipa/ticket/2660
Diffstat (limited to 'ipaserver/ipaldap.py')
-rw-r--r-- | ipaserver/ipaldap.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ipaserver/ipaldap.py b/ipaserver/ipaldap.py index 9e1266bf5..5fed6f3ac 100644 --- a/ipaserver/ipaldap.py +++ b/ipaserver/ipaldap.py @@ -1561,7 +1561,8 @@ class IPAdmin(LDAPClient): return 'ldap' def __init__(self, host='', port=389, cacert=None, debug=None, ldapi=False, - realm=None, protocol=None, force_schema_updates=True): + realm=None, protocol=None, force_schema_updates=True, + start_tls=False): self.conn = None log_mgr.get_logger(self, True) if debug and debug.lower() == "on": @@ -1582,6 +1583,9 @@ class IPAdmin(LDAPClient): self.conn = IPASimpleLDAPObject(ldap_uri, force_schema_updates=True) + if start_tls: + self.conn.start_tls_s() + def __str__(self): return self.host + ":" + str(self.port) @@ -1724,10 +1728,6 @@ class IPAdmin(LDAPClient): # FIXME: for backwards compatibility only return self.conn.unbind(*args, **kwargs) - def start_tls_s(self, *args, **kwargs): - # FIXME: for backwards compatibility only - return self.conn.start_tls_s(*args, **kwargs) - # FIXME: Some installer tools depend on ipaldap importing plugins.ldap2. # The proper plugins should rather be imported explicitly. |