Gitlab CSE Unil

Commit ad10d99f authored by M. Chardon's avatar M. Chardon
Browse files

pb encodage

parent 20a087a3
......@@ -35,7 +35,8 @@ def get_attp_message(attp_msg64, attp_hash):
msg_data = None
try:
msg_str = b64decode(attp_msg64)
msg = json.loads(msg_str)
msg_str_decode = msg_str.decode('utf8').replace("'", '"')
msg = json.loads(msg_str_decode)
except (TypeError, ValueError, IndexError):
# malformed massage
# TODO: log malformed message error
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment