I have clients where it uses both Python and Ruby to share the encoded strings between. Particularly ruby client will encode the string using base64_encode
and Python client has to decoded that ruby based encoded string to parse the data. But when I tried to decode using base64 in python for the ruby base64 encoded string getting some wired error,
ERROR:
'utf-8' codec can't decode byte 0x9a in position 0: invalid start byte
But still seeing the message content as below which doesn't have proper format,
b'\x04\x08{\x0b:\x0cmsgtimel+\x07\xd6wcZ:\x0erequestid"%a6cbfedf3f195714a484asdc35bdc210:\thash"%ed9efcfda14asd902416151006c87324:\rsenderid"\x10test-server1:\tbody"k\x04\x08{\x08:\x0estatusmsg"\x07OK:\x0fstatuscodei\x00:\tdata{\n:\nerror0:\x0bstdout"\x11test-server-hostname\n:\x0bstderr"\x00:\x0boutput0:\rexitcodei\x00:\x10senderagent"\nshell'
NOTE: ruby client will decode the hash formatted string and the ruby version for some client is 1.8.7 and for some client is 1.9.3.