summaryrefslogtreecommitdiffstats
path: root/ipa-python/ipaclient.py
diff options
context:
space:
mode:
authorKarl MacMillan <kmacmillan@mentalrootkit.com>2007-08-28 09:58:10 -0400
committerKarl MacMillan <kmacmillan@mentalrootkit.com>2007-08-28 09:58:10 -0400
commit6eea6664e079d187c3b0420b4283af35205d3b03 (patch)
treec579e484bd63dfc8d9d5db1369b36554ddb06531 /ipa-python/ipaclient.py
parente31b526c8174e7c55f69b1fdf31a6ee78197e8bc (diff)
downloadfreeipa-6eea6664e079d187c3b0420b4283af35205d3b03.tar.gz
freeipa-6eea6664e079d187c3b0420b4283af35205d3b03.tar.xz
freeipa-6eea6664e079d187c3b0420b4283af35205d3b03.zip
This patch wraps binary data in an xmlrpclib Binary object. This
removes the need for LDIF conversion. It will make TurboGears direct code faster, but should keep xmlrpc about the same speed. The patch also swaps out ldap.cidict for the IPA CIDict class. IPA code should only use the CIDict class now.
Diffstat (limited to 'ipa-python/ipaclient.py')
-rw-r--r--ipa-python/ipaclient.py14
1 files changed, 3 insertions, 11 deletions
diff --git a/ipa-python/ipaclient.py b/ipa-python/ipaclient.py
index 28573acad..71def70fd 100644
--- a/ipa-python/ipaclient.py
+++ b/ipa-python/ipaclient.py
@@ -30,14 +30,6 @@ import group
import ipa
import config
-def cidict_to_dict(cid):
- """Convert a cidict to a standard dict for sending across the wire"""
- newdict = {}
- kindex = cid.keys()
- for dkey in kindex:
- newdict[dkey] = cid[dkey]
- return newdict
-
class IPAClient:
def __init__(self,local=None):
@@ -89,7 +81,7 @@ class IPAClient:
result = self.transport.get_all_users()
all_users = []
- for (attrs) in result:
+ for attrs in result:
if attrs is not None:
all_users.append(user.User(attrs))
@@ -107,7 +99,7 @@ class IPAClient:
result = self.transport.find_users(criteria, sattrs)
users = []
- for (attrs) in result:
+ for attrs in result:
if attrs is not None:
users.append(user.User(attrs))
@@ -165,7 +157,7 @@ class IPAClient:
result = self.transport.find_groups(criteria, sattrs)
groups = []
- for (attrs) in result:
+ for attrs in result:
if attrs is not None:
groups.append(group.Group(attrs))