{"name":"ed25519-hd-key","version":"2.0.0","type":"module","description":"BIP-0032 like derivation for ed25519 curve","main":"dist/index.js","types":"dist/index.d.ts","repository":{"type":"git","url":"git://github.com/alepop/ed25519-hd-key.git"},"bugs":{"url":"https://github.com/alepop/ed25519-hd-key/issues"},"homepage":"https://github.com/alepop/ed25519-hd-key","scripts":{"prepublish":"npm run build","build":"tsc -p ./","test":"NODE_OPTIONS='--experimental-vm-modules' jest","format":"prettier --write 'src/**/*.{js,ts}'"},"keywords":["ed25519","bip32","slip-0010","crypto","trezor","hierarchical","deterministic","hd key"],"author":{"name":"Aleksey Popov"},"license":"MIT","dependencies":{"@noble/ed25519":"3.1.0","@noble/hashes":"2.2.0"},"devDependencies":{"@types/jest":"30.0.0","@types/node":"25.6.0","jest":"30.3.0","jest-cli":"30.3.0","ts-jest":"29.4.9","typescript":"6.0.3","prettier":"3.8.3"},"_id":"ed25519-hd-key@2.0.0","gitHead":"4f5661dda2a7b08731434bb2df9091e9a7e2cce6","_nodeVersion":"22.21.1","_npmVersion":"10.9.4","dist":{"integrity":"sha512-xWAbQeTHA2DkyirTUYOaOaizcNY/CVNYwprMrnKn0GO1O4LKRXby1nUcj+blr2bT5z44IcyNpA1QPvzLVqHCsA==","shasum":"fd39226fd369d9d80d7ff7fb5bec1c54e2e3e33a","tarball":"http://registry-npm.ywwl.com/ed25519-hd-key/download/ed25519-hd-key-2.0.0.tgz","fileCount":7,"unpackedSize":6839,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCICC9KiuSO0B+Xl5q0KtUt2gdwgN01FQ6gVmxSdwtm90lAiAbHLv4mQ6FA2TId2DhXvVZLAQn//PJ2bqleI5uBXAHog=="}],"size":3235,"noattachment":false,"key":"/ed25519-hd-key/-/ed25519-hd-key-2.0.0.tgz"},"_npmUser":{"name":"alepop","email":"alepooop@gmail.com"},"directories":{},"maintainers":[{"name":"alepop","email":"alepooop@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/ed25519-hd-key_2.0.0_1777814575409_0.22367551459274582"},"_hasShrinkwrap":false,"readme":"[![BuyMeACoffee](https://raw.githubusercontent.com/pachadotdev/buymeacoffee-badges/main/bmc-yellow.svg)](https://www.buymeacoffee.com/alepop)\n[![codecov](https://codecov.io/gh/alepop/ed25519-hd-key/branch/master/graph/badge.svg)](https://codecov.io/gh/alepop/ed25519-hd-key)\n\ned25519 HD Key\n=====\n\nVersion 2.0.0\n------------\n\nI've rebuilt the library from the ground up for version 2.0.0. It now uses `@noble/ed25519` and `@noble/hashes`. These libraries are faster, audited, and cleaner.\n\nIf you need to use `tweetnacl`, you can stick with version 1.3.0.\n\nKey Derivation for `ed25519`\n------------\n\n\n[SLIP-0010](https://github.com/satoshilabs/slips/blob/master/slip-0010.md) - Specification\n\nInstallation\n------------\n\n    npm i --save ed25519-hd-key\n\n\nUsage\n-----\n\n**example:**\n\n```js\nconst { derivePath, getMasterKeyFromSeed, getPublicKey } = require('ed25519-hd-key')\nconst hexSeed = 'fffcf9f6f3f0edeae7e4e1dedbd8d5d2cfccc9c6c3c0bdbab7b4b1aeaba8a5a29f9c999693908d8a8784817e7b7875726f6c696663605d5a5754514e4b484542';\n\nconst { key, chainCode } = getMasterKeyFromSeed(hexSeed);\nconsole.log(key.toString('hex'))\n// => 2b4be7f19ee27bbf30c667b642d5f4aa69fd169872f8fc3059c08ebae2eb19e7\nconsole.log(chainCode.toString('hex'));\n// => 90046a93de5380a72b5e45010748567d5ea02bbf6522f979e05c0d8d8ca9fffb\n\nconst { key, chainCode} = derivePath(\"m/0'/2147483647'\", hexSeed);\n\nconsole.log(key.toString('hex'))\n// => ea4f5bfe8694d8bb74b7b59404632fd5968b774ed545e810de9c32a4fb4192f4\nconsole.log(chainCode.toString('hex'));\n// => 138f0b2551bcafeca6ff2aa88ba8ed0ed8de070841f0c4ef0165df8181eaad7f\n\nconsole.log(getPublicKey(key).toString('hex'))\n// => 005ba3b9ac6e90e83effcd25ac4e58a1365a9e35a3d3ae5eb07b9e4d90bcf7506d\n```\nTests\n-----\n```\nnpm test\n```\n\nReferences\n----------\n[SLIP-0010](https://github.com/satoshilabs/slips/blob/master/slip-0010.md)\n\n[BIP-0032](https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki)\n\n[BIP-0044](https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki)\n","publish_time":1777814575560,"_cnpm_publish_time":1777814575560,"dist-tags":{"latest":"2.0.0"}}