First reference implementation of Hashlink library (node.js) released

Hi all,

The first reference implementation of the Hashlink library (for node.js)
has been released:

https://www.npmjs.com/package/hashlink

This software is important because it's what enables us to trust
content (content integrity protection) that is linked to from Verifiable
Credentials, DID Documents, and other decentralized data documents.

Summary
-------

When using a hyperlink to fetch a resource from the Internet, it is
often useful to know if the resource has changed since the data was
published. Cryptographic hashes, such as SHA-256, are often used to
determine if published data has changed in unexpected ways.

Due to the nature of most hyperlinks, the cryptographic hash is often
published separately from the link itself. The Hashlink specification
describes a data model and serialization formats for expressing
cryptographically protected hyperlinks. The mechanisms described in the
Hashlink specification enables a system to publish a hyperlink in a way
that empowers a consuming application to determine if the resource
associated with the hyperlink has changed in unexpected ways.

-------

The latest specification is available here:

https://tools.ietf.org/html/draft-sporny-hashlink

You can read more about how you can use the library here:

https://github.com/digitalbazaar/hashlink/blob/master/README.md

This is the first release, so expect bugs and functionality to be fairly
basic. There is a command line utility that enables you to:

* Create a hashlink from a data file
* Verify a hashlink given a data file
* Annotate where that file will be published
* Create legacy hashlink URLs, for use w/ regular https://... URLs
* Use SHA-2 (256-bit output) and Blake2b (64-bit output) for the hashes
* Use base58btc encoding for the base-encoding mechanism

In the future, the library will add the following features:

* Parsing hashlink URLs so human beings can read CBOR metadata
* Loading data from URLs (instead of from data files)
* URL resolvers that support http, ipfs, dat, etc.
* Arbitrary data transform codecs to support canonization and
  conversion to/from JSON-LD/CBOR/Preserves/YAML and other data
  formats
* A portable test suite that can test other implementations
* Isomorphic Javascript so it works in the browser too... there are zero
  correctly implemented CBOR libraries that work in the browser :)

Perhaps we can hack on this library to add the features above during
RWoT 9. :)

-- manu

-- 
Manu Sporny (skype: msporny, twitter: manusporny)
Founder/CEO - Digital Bazaar, Inc.
blog: Veres One Decentralized Identifier Blockchain Launches
https://tinyurl.com/veres-one-launches

Received on Tuesday, 20 August 2019 21:51:59 UTC