bitcore-lib-zcash/docs/crypto.md

18 lines
1.2 KiB
Markdown
Raw Permalink Normal View History

2015-10-16 09:43:27 -07:00
# Bitcoin Crypto
2014-12-17 12:43:58 -08:00
The cryptographic primitives (ECDSA and HMAC) implementations in this package have been reviewed by the BitPay engineering team. More audits and reviews are welcomed.
2014-11-24 08:52:53 -08:00
2014-12-12 11:26:33 -08:00
## Random
The `bitcore.crypto.Random` namespace contains a single function, named `getRandomBuffer(size)` that returns a `Buffer` instance with random bytes. It may not work depending on the engine that bitcore is running on (doesn't work with IE versions lesser than 11).
2014-11-24 08:52:53 -08:00
2014-12-12 11:26:33 -08:00
## BN
2014-12-15 21:45:23 -08:00
The `bitcore.Crypto.BN` class contains a wrapper around [bn.js](https://github.com/indutny/bn.js), the bignum library used internally in bitcore.
2014-11-24 08:52:53 -08:00
2014-12-12 11:26:33 -08:00
## Point
2014-12-19 14:23:48 -08:00
The `bitcore.Crypto.Point` class contains a wrapper around the class Point of [elliptic.js](https://github.com/indutny/elliptic), the elliptic curve library used internally in bitcore.
2014-11-24 08:52:53 -08:00
2014-12-12 11:26:33 -08:00
## Hash
2014-12-15 21:45:23 -08:00
The `bitcore.Crypto.Hash` namespace contains a set of hashes and utilities. These are either the native `crypto` hash functions from `node.js` or their respective browser shims as provided by the `browserify` library.
2014-11-24 08:52:53 -08:00
2014-12-12 11:26:33 -08:00
## ECDSA
`bitcore.Crypto.ECDSA` contains a pure JavaScript implementation of the elliptic curve DSA signature scheme based on [elliptic.js](https://github.com/indutny/elliptic).