[Freeipa-devel] [PATCH] 0003 Fix JSON binary encode and decode errors (rebase)

Rob Crittenden rcritten at redhat.com
Thu Mar 4 20:08:07 UTC 2010


John Dennis wrote:
> [Note: same patch as earlier but rebased]
> 
> Traverse the objects passed to JSON for encoding and decoding.
> When binary data is seen during encode replace the binary
> data with a dict {'__base64__' : base64_encoding_of_binary_value}.
> 
> On decode if a dict is seen whose single key is '__base64__' replace
> that dict with the base64 decoded value of the key's value.

This works in that the UI no longer crashes but the certificate is show 
thusly in the UI:

Certificate	[object Object]

I know we talked about moving to storing certs as PEM which should fix 
this problem at some point but is this an acceptable interim solution? 
Or do we want to just leave base64-encoded objects encoded?

rob




More information about the Freeipa-devel mailing list