canonical-json

Canonical JSON for signing and hashing JSON values

https://github.com/well-typed/canonical-json

Latest on Hackage:0.6.0.1@rev:1

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

BSD-3-Clause licensed by Duncan Coutts, Edsko de Vries

An implementation of Canonical JSON.

http://wiki.laptop.org/go/Canonical_JSON

The "canonical JSON" format is designed to provide repeatable hashes of JSON-encoded data. It is designed for applications that need to hash, sign or authenitcate JSON data structures, including embedded signatures.

Canonical JSON is parsable with any full JSON parser, and it allows whitespace for pretty-printed human readable presentation, but it can be put into a canonical form which then has a stable serialised representation and thus a stable hash.