summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Cholasta <jcholast@redhat.com>2013-12-05 14:43:19 +0100
committerPetr Viktorin <pviktori@redhat.com>2013-12-10 15:34:45 +0100
commit36502a6367fd4ab041d4d4d3ac42da244a1c7c22 (patch)
tree181d4bb7ebc3a94fabfae638a4e09eaeaa42ab44
parent1e0405880fb1855563cb9b58a39213e1d3b4a2c6 (diff)
downloadfreeipa-36502a6367fd4ab041d4d4d3ac42da244a1c7c22.tar.gz
freeipa-36502a6367fd4ab041d4d4d3ac42da244a1c7c22.tar.xz
freeipa-36502a6367fd4ab041d4d4d3ac42da244a1c7c22.zip
Fix internal error in the user-status command.
https://fedorahosted.org/freeipa/ticket/4066
-rw-r--r--ipalib/plugins/user.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/ipalib/plugins/user.py b/ipalib/plugins/user.py
index c8551453..ae927b64 100644
--- a/ipalib/plugins/user.py
+++ b/ipalib/plugins/user.py
@@ -922,14 +922,14 @@ class user_status(LDAPQuery):
other_ldap.connect(ccache=os.environ['KRB5CCNAME'])
except Exception, e:
self.error("user_status: Connecting to %s failed with %s" % (host, str(e)))
- newresult = ldap.make_entry(dn)
+ newresult = {'dn': dn}
newresult['server'] = _("%(host)s failed: %(error)s") % dict(host=host, error=str(e))
entries.append(newresult)
count += 1
continue
try:
entry = other_ldap.get_entry(dn, attr_list)
- newresult = ldap.make_entry(dn)
+ newresult = {'dn': dn}
for attr in ['krblastsuccessfulauth', 'krblastfailedauth']:
newresult[attr] = entry[1].get(attr, [u'N/A'])
newresult['krbloginfailedcount'] = entry[1].get('krbloginfailedcount', u'0')
@@ -958,7 +958,7 @@ class user_status(LDAPQuery):
self.obj.handle_not_found(*keys)
except Exception, e:
self.error("user_status: Retrieving status for %s failed with %s" % (dn, str(e)))
- newresult = ldap.make_entry(dn)
+ newresult = {'dn': dn}
newresult['server'] = _("%(host)s failed") % dict(host=host)
entries.append(newresult)
count += 1