How to cryptographically hash a JSON object?

The problem is a common one when computing hashes for any data format where flexibility is allowed. To solve this, you need to canonicalize the representation. For example, the OAuth1.0a protocol, which is used by Twitter and other services for authentication, requires a secure hash of the request message. To compute the hash, OAuth1.0a says … Read more