hyperledger / indy-plenum

Plenum Byzantine Fault Tolerant Protocol
https://wiki.hyperledger.org/display/indy
Apache License 2.0
215 stars 370 forks source link

View change with large number #940

Open dastardlychimp opened 6 years ago

dastardlychimp commented 6 years ago

When there is an integer in the request that is larger than a 64 bit integer (9223372036854775807), the ujson package throws an uncaught value error which results in a view change.

Stacktrace:

Traceback (most recent call last):
  File "/usr/local/lib/python3.5/dist-packages/stp_zmq/zstack.py", line 565, in processReceived
    msg = self.deserializeMsg(msg)
  File "/usr/local/lib/python3.5/dist-packages/stp_zmq/zstack.py", line 835, in deserializeMsg
    msg = json.loads(msg)
ValueError: Value is too big

zstack.py

    @staticmethod
    def deserializeMsg(msg):
        if isinstance(msg, bytes):
            msg = msg.decode()
>>      msg = json.loads(msg)
        return msg
esplinr commented 6 years ago

We will track this as: https://jira.hyperledger.org/browse/INDY-1760