Is there a library available that can help make sure that JSON objects being sent back and forth between a server running Python and a Javascript client have not been corrupted?
I'm thinking it would probably work by creating a hash of the object to be sent a long with the object. Then the receiver of the object could re-hash the object ans make sure that it matches the hash that it received.
Is this something that I should even be concerned about, or is this something that browsers and clients normally have taken care of behind the scenes anyway?
Thanks!
TCP has built-in error checking, and so do most link layer network protocols. So there's both per-link and end-to-end checks taking place. The only thing this doesn't protect against is intentional modification of the data, e.g. by a firewall, proxy, or network hacker. However, they can modify the hash as well as the JSON, so adding a hash doesn't protect against them. If you need real, secure protection you need to use cryptography, e.g. SSL.
Python-Javascript Hash library to make sure that a JSON object did not get corrupted in transit