{"name":"noise-curve-ed","version":"2.1.0","description":"Ed25519 elliptic curve operations for [`noise-handshake`](https://github.com/chm-diederichs/noise-handshake)","main":"index.js","scripts":{"test":"npx standard && tape test.js"},"repository":{"type":"git","url":"git+https://github.com/chm-diederichs/noise-curve-ed.git"},"keywords":[],"author":"","license":"ISC","bugs":{"url":"https://github.com/chm-diederichs/noise-curve-ed/issues"},"homepage":"https://github.com/chm-diederichs/noise-curve-ed#readme","dependencies":{"b4a":"^1.1.0","nanoassert":"^2.0.0","sodium-universal":"^5.0.0"},"devDependencies":{"noise-handshake":"^3.0.0","standard":"^16.0.3","tape":"^5.2.2"},"_id":"noise-curve-ed@2.1.0","gitHead":"759e631531bb64e32428b5684fc615758ae806f5","_nodeVersion":"22.12.0","_npmVersion":"10.9.0","dist":{"integrity":"sha512-zAzJx+VwZM3w6EA1hTmDhJfvAnCeBQn/1FAeZ0LtGxCcCtlAK/uJXQVF/eDVUOaAZ286lHlx77WJ+qj9SmsRRg==","shasum":"38ab0748439baa0f21d49c78d7b8be3d5bb94f42","tarball":"http://registry-npm.ywwl.com/noise-curve-ed/download/noise-curve-ed-2.1.0.tgz","fileCount":4,"unpackedSize":3684,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCID3+Z5WU/K0G9fJmz8rcR7p4AD4hEPphj0R2hJwtm5F3AiEAo69Snkv+4J3B6IrzgqSvoeR8klg/a43IcvHFaNmY6/o="}],"size":1522,"noattachment":false,"key":"/noise-curve-ed/-/noise-curve-ed-2.1.0.tgz"},"_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"directories":{},"maintainers":[{"name":"mafintosh","email":"mathiasbuus@gmail.com"},{"name":"chm-diederichs","email":"chm-diederichs@protonmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/noise-curve-ed_2.1.0_1744483505062_0.22043949680694852"},"_hasShrinkwrap":false,"readme":"# noise-curve-ed\n\nEd25519 elliptic curve operations for [`noise-handshake`](https://github.com/chm-diederichs/noise-handshake)\n\n## Usage\n```js\nconst curve = require('noise-curve-ed')\nconst Noise = require('noise-handshake')\n\nconst handshake = new Noise(pattern, initiator, staticKeyPair, { curve })\n```\n\n## API\n\n#### constants\n\n`DHLEN` = 32\n`PKLEN` = 32\n`SCALARLEN` = 32\n`SKLEN` = 64\n`ALG` = 'Ed25519'\n\n#### `generateKeyPair([privKey])`\n\nGenerate a new keypair, optionally pass in a preexisting `privKey`. Return value is of the form:\n\n```\n{\n  publicKey,\n  secretKey,\n}\n```\n\n#### `dh(publicKey, { secretKey, scalar })`\n\nPerform DH between `publicKey` and `secretKey`/`scalar` and return the result.\n","publish_time":1744483505247,"_cnpm_publish_time":1744483505247,"dist-tags":{"latest":"2.1.0"}}