summaryrefslogtreecommitdiffstats
path: root/ipalib/cli.py
diff options
context:
space:
mode:
authorJan Cholasta <jcholast@redhat.com>2012-01-23 09:50:41 -0500
committerRob Crittenden <rcritten@redhat.com>2012-02-13 22:21:50 -0500
commitca3f3041106dbaa8462aeb78c35b640b169d694a (patch)
tree4821672b66a83847e39e2cbc48e90c5ee536c130 /ipalib/cli.py
parentc00bf9e38afa4867f4ec397b260f2e467163096d (diff)
downloadfreeipa-ca3f3041106dbaa8462aeb78c35b640b169d694a.tar.gz
freeipa-ca3f3041106dbaa8462aeb78c35b640b169d694a.tar.xz
freeipa-ca3f3041106dbaa8462aeb78c35b640b169d694a.zip
Base64-decode unicode values in Bytes parameters.
Fix wrong handling of strings in --setattr/--addattr/--delattr. These changes make it possible to use Bytes in --setattr/--addattr/ --delattr without errors. Fixes managing SSH keys on command-line https://fedorahosted.org/freeipa/ticket/754
Diffstat (limited to 'ipalib/cli.py')
-rw-r--r--ipalib/cli.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/ipalib/cli.py b/ipalib/cli.py
index 5d07cb1b5..169d3e005 100644
--- a/ipalib/cli.py
+++ b/ipalib/cli.py
@@ -1054,11 +1054,7 @@ class cli(backend.Executioner):
Decode param values if appropriate.
"""
for (key, value) in kw.iteritems():
- param = cmd.params[key]
- if isinstance(param, Bytes):
- yield (key, value)
- else:
- yield (key, self.Backend.textui.decode(value))
+ yield (key, self.Backend.textui.decode(value))
def build_parser(self, cmd):
parser = CLIOptionParser(