@helixnetwork/schnorr
TypeScript icon, indicating that this package has built-in type declarations

1.0.0-alpha.7 • Public • Published

@helixnetwork/schnorr

IOTA schnorr Scheme

Installation

Install using npm:

npm install @helixnetwork/schnorr

or using yarn:

yarn add @helixnetwork/schnorr

API Reference

schnorr~subseed

Compute subseed based on the seed with an additional index(seed, index)

Param Type Description
seed Int8Array Seed txBits
index number Private key index

Returns: Int8Array - subseed txBits

schnorr~key

Split seed in fragments and hashed them then generate from each fragment a schnore private key;(subseed, securityLevel)

Param Type Description
subseed Int8Array Subseed txBits
securityLevel number Private key length

Returns: Int8Array - Private key bytes

schnorr~digests(key)

Param Type Description
key Uint8Array Private key txBits

schnorr~address(digests)

Param Type Description
digests Int8Array Digests txBits

Returns: Int8Array - Address txBits

schnorr~digest(normalizedBundleFragment, signatureFragment)

Param Type Description
normalizedBundleFragment array Normalized bundle fragment
signatureFragment Int8Array Signature fragment txBits

Returns: Int8Array - Digest txBits

schnorr~signatureFragment(normalizeBundleFragment, keyFragment)

Param Type Description
normalizeBundleFragment array normalized bundle fragment
keyFragment keyFragment key fragment txBits

Returns: Uint8Array - Signature Fragment txBits

schnorr~validateSignatures(expectedAddress, signatureFragments, bundleHash)

Param Type Description
expectedAddress string Expected address txs
signatureFragments array Array of signatureFragments txs
bundleHash string Bundle hash txs

schnorr~normalizedBundleHash(bundlehash)

Param Type Description
bundlehash Hash Bundle hash txs

Normalizes the bundle hash, with resulting digits summing to zero.

Returns: Int8Array - Normalized bundle hash

Package Sidebar

Install

npm i @helixnetwork/schnorr

Weekly Downloads

2

Version

1.0.0-alpha.7

License

MIT

Unpacked Size

161 kB

Total Files

50

Last publish

Collaborators

  • dzlzv
  • dad1x
  • fsbbn
  • dnck
  • dt93
  • ofo42