http://tools.ietf.org/html/draft-hallambaker-jsonbcd-00
The big problem I have found with using JSON for crypto is the lack of a binary encoding for data. This means that binary blobs have to be encoded as Base64 which is not too bad in itself except that when using nested structures the base64 overhead expands the data by 33% each time it is wrapped. JSON-B is basically just a scheme that adds in a run-length encoding for strings and binary data to JSON encoding. It is a superset of JSON and it is very easy to adapt a JSON parser or encoder to add in support for JSON-B. Unlike other binary encodings for JSON (BJSON etc), there is no need to distinguish the binary form from the regular. A JSON-B decoder will accept either form. This simplifies protocol negotiation as the only concern is ensuring that the sender emits a form that the receiver can understand. JSON-B also provides binary encodings for integers (including bignums up to (2^23) bits long) and doubles. The last being important in scientific applications as converting to and from decimal form results in precision loss. There is also a JSON-C (Compact) and JSON-D (Data) defined. The practical benefit of using this with JOSE is that it can be used to frame the crypto data in the same way that ASN.1 is used in CMS but with the same simplicity as using traditional JSON. -- Website: http://hallambaker.com/
_______________________________________________ jose mailing list [email protected] https://www.ietf.org/mailman/listinfo/jose
