bitcoinjs/wif

Name: wif

Owner: BitcoinJS

Description: Bitcoin Wallet Import Format JS encoding/decoding module

Created: 2015-08-20 09:56:08.0

Updated: 2018-05-11 22:20:14.0

Pushed: 2017-12-04 05:50:58.0

Homepage:

Size: 27

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

WIF

TRAVIS NPM

js-standard-style

Bitcoin Wallet Import Format encoding/decoding module.

Example
wif = require('wif')
privateKey = new Buffer('0000000000000000000000000000000000000000000000000000000000000001', 'hex')
key = wif.encode(128, privateKey, true)
> KwDiBf89QgGbjEhKnhXJuH7LrciVrZi3qYjgd9M7rFU73sVHnoWn

obj = wif.decode(key)
> {
version: 128,
privateKey: <Buffer 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01>,
compressed: true


decode(key, 0x09)
> Error: Invalid network version

lternative syntax
encode(obj)
> KwDiBf89QgGbjEhKnhXJuH7LrciVrZi3qYjgd9M7rFU73sVHnoWn
LICENSE MIT

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.