veriform
v0.0.0
Published
Protobuf-like security-oriented serialization format with cryptographic authentication/signature support
Downloads
4
Maintainers
Readme
veriform.js
TypeScript implementation of Veriform: a cryptographically verifiable data serialization format inspired by Protocol Buffers, useful for things like credentials, transparency logs, and "blockchain" applications.
For more information, see the toplevel README.md.
Help and Discussion
Have questions? Want to suggest a feature or change?
- Gitter: web-based chat about zcred projects including veriform
- Google Group: join via web or email ([email protected])
Requirements
veriform.js is presently targeting ES2017. This is because we soon plan on making use of the TC39 BigInt type when it becomes available, and want to make sure users of this library can handle modern ECMAScript versions.
Please make sure your JS runtime is ES2017 compliant, or use a transpiler like babel support older versions of ECMAScript.
Installation
Via npm:
npm install veriform
Via Yarn:
yarn install veriform
Import veriform into your project with:
import Veriform from "veriform";
API
Veriform.parse()
The Veriform.parse()
method parses a Uint8Array
containing a serialized
veriform message into a corresponding self-describing object representation.
Parameters
- message: The
Uint8Array
containing a veriform message to parse
Example
let message = new Uint8Array([0x15, 0x07, 0x02, 0x03, 0x55]);
Veriform.parse(message);
// Object { 1: Object { 24: 42 } }
Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/zcred/veriform
Copyright
Copyright (c) 2017 The Zcred Developers. See LICENSE.txt for further details.