@binded/verify-proof
Verify Binded blockchain proofs
Last updated 3 years ago by olalonde .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @binded/verify-proof 
SYNC missed versions from official npm registry.

verify-proof

Build Status

This is a client side library and web UI for verifying Binded issued proofs.

Proofs are composed of a merkle branch, original data and a root hash which is written on the Bitcoin blockchain, effectively timestamping the data.

The proof format is based on chainpoint proof format.

Verify a Binded proof

Install

npm install --save @binded/verify-proof

Usage

import bindedVerify from '@binded/verify-proof'
import fs from 'fs'

const proofData = JSON.parse(fs.readFileSync('./some-binded-proof.json', {
  encoding: 'utf-8',
}))

const proof = bindedVerify(proofData)

proof.analyze().then((results) => {
  console.log(results)
  /*
    {
      // optional info for nicer error messages in case
      // isValid is false
      validations: {
        isTargetHashValid: true,
        isMerkleRootValid: true,
        isDataHashValid: true,
        isTxValid: true,
      },
      confirmations: 4097,
      isValid: true, // true if valid and false if invalid
    }
  */
})

TODO: cli installed with npm install -g @binded/verify-proof

NB: Binded was formerly known as Blockai.

Current Tags

  • 0.2.2                                ...           latest (3 years ago)

3 Versions

  • 0.2.2                                ...           3 years ago
  • 0.2.1                                ...           4 years ago
  • 0.2.0                                ...           4 years ago
Downloads
Today 0
This Week 3
This Month 6
Last Day 0
Last Week 0
Last Month 1
Dependencies (2)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |