Skip to content

Releases: MetaMask/key-tree

6.2.1

23 Jan 10:57
7b6becf
Compare
Choose a tag to compare

Fixed

  • Add missing curve parameter (#110)
    • This fixes a bug introduced in 6.2.0, when using the ed25519 curve.

6.2.0

18 Jan 11:21
0001644
Compare
Choose a tag to compare

Added

  • Accept BIP-39 secret recovery phrase as Uint8Array (#107)
    • Secret recovery phrases are now accepted both as a string in the bip39:... format, and as Uint8Array in the format used by @metamask/scure-bip39, in all functions that accept secret recovery phrases.

6.1.0

10 Jan 15:41
176e322
Compare
Choose a tag to compare

Changed

  • Update BIP-39 implementation from @scure/bip39 to MetaMask fork version @metamask/scure-bip39 (#101)
  • The @metamask/scure-bip39 fork accepts secret recovery phrases in Uint8Array format making it possible to use more secure patterns of passing secret recovery phrases around. This change is non-breaking however, as the mnemonicToSeed function used in this package still accepts secret recovery phrases in string format.

6.0.0

04 Nov 12:30
b06251f
Compare
Choose a tag to compare

Changed

  • BREAKING: Rename all occurrences of Buffer with Bytes or Uint8Array (#84)
    • All [...]Buffer fields have been replaced with [...]Bytes, e.g., BIP44Node.privateKeyBuffer is now BIP44Node.privateKeyBytes.
    • This change does not affect the string fields, like BIP44Node.privateKey.
  • BREAKING: Swap out Buffer with browser-compatible Uint8Array (#83)
    • All functions returning Buffers now return Uint8Arrays instead.
  • Bump @metamask/utils to 3.3.0 (#85)

5.0.2

20 Sep 09:34
5647789
Compare
Choose a tag to compare

Fixed

  • Export Buffer from buffer package explicitly (#76)
  • Fix fingerprint derivation (#78)

5.0.1

16 Sep 11:53
367b685
Compare
Choose a tag to compare

Fixed

  • Replace postinstall script with Yarn plugin (#74)

5.0.0

12 Sep 09:58
d1e8549
Compare
Choose a tag to compare

Added

  • Add convenience field for getting the compressed public key (#71)
  • Add master fingerprint field to SLIP10Node (#68)

Changed

  • BREAKING: Bump minimum Node version to 16 and migrate to Yarn 3 (#70)
  • Allow a depth larger than 5 for SLIP-10 nodes (#69)

4.0.0

11 May 19:47
4067de8
Compare
Choose a tag to compare

Added

  • NOTE: This version is a significant rewrite of this package, and virtually all existing usage will break upon migrating from a previous major version.
    All pre-existing functionality is supported through different means, and various new features have been added.
  • Add extended public (xpub) and private (xprv) keys (#58)
  • Add support for public key derivation (#56)
  • Add support for non-secp256k1 curves via SLIP10Node class (#43, #37, #53)
    • Add support for ed25519 curve.
    • With this and other changes in this release, this package offers full SLIP-10 support for all curves except nist256p1.
    • These changes were made possible using the @noble/* suite of cryptography packages.
  • Add extended key to BIP-44 coin type node (#59)
  • Add convenience methods to get public keys and addresses (#50)
  • Enable deriving hardened change and address_index using BIP44CoinTypeNode (#37)

Changed

  • BREAKING: Change key representation format (#58, #54)
    • Encode string keys in hexadecimal instead of Base64.
    • Always return a SLIP10Node (or child class) object from derivation functions.
  • BREAKING: Separate private keys and chain code into separate fields (#54)
  • BREAKING: Use named arguments instead of positional arguments in various functions (#56)
  • BREAKING: Make all derivation functions async (#43, #54)
    • All key derivation functions are now async, and node objects are initialized via a static, async .from(...) method. This is because some cryptographic dependencies are async.
  • Update documentation to match new implementation (#60, #49)

Fixed

  • Remove obsolete Jest snapshots (#41)
  • Replace node symbol with private field (#42)

3.0.1

01 Nov 18:43
e809fc2
Compare
Choose a tag to compare

Changed

  • Update cryptography dependencies (#29, #30, #31)
    • This results in an overall ~4x speedup in Node.js for operations with this package. Browser performance gains, if any, are not known at this time.
    • Individual pull requests:
      • bip39@3.0.4 (#29)
      • secp256k1@4.0.2 (#30)
      • keccak@3.0.2 (#31)

3.0.0

01 Nov 17:42
ad121b4
Compare
Choose a tag to compare

Changed

  • BREAKING: Refactor package API (#25)
    • The new API is designed to make it harder to derive incorrect keys.
    • The previous exports of this package can no longer be accessed from the main entry file.
    • For the new API, please see the README.
  • BREAKING: Bump minimum Node.js version to >=12.0.0 (#20)

Security