From cac7357ebdd7c7218f1d847ca7374735d7e411cd Mon Sep 17 00:00:00 2001 From: Fraser Tweedale Date: Aug 29 2017 11:01:31 +0000 Subject: cert: fix application of 'str' to bytes when formatting otherName Part of: https://pagure.io/freeipa/issue/4985 Reviewed-By: Stanislav Laznicka --- diff --git a/ipaserver/plugins/cert.py b/ipaserver/plugins/cert.py index ad8bea6..41cb675 100644 --- a/ipaserver/plugins/cert.py +++ b/ipaserver/plugins/cert.py @@ -560,7 +560,7 @@ def _format_othername(on): """Format a python-cryptography OtherName for display.""" return u'{}:{}'.format( on.type_id.dotted_string, - base64.b64encode(on.value) + base64.b64encode(on.value).decode('ascii') )