You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suggest to switch to developed and audited projects:
bn.js can be dropped, in favor of native bigints, which have been supported everywhere for a long time
brorand can be dropped in favor of a simple 5-lines-of-code file
hash.js can be replaced by @noble/hashes, which has been independently audited, and supports tree shaking
hmac-drbg and secp256k1 implementation can be replaced by @noble/secp256k1, which has been independently audited, uses native bigints, and is getting more and more popular. There is also an optional compatibility layer with old api
inherits does not seem that useful at this point, since the intro of es6 classes
minimalistic-assert, minimalistic-crypto-utils can be kept, I suggest to set their versions to a fixed value instead of range
This solution is much faster than current elliptic impl.
Elliptic is 130KB of minified code right now, which is huge. It can be tiny, a fraction of that.
The text was updated successfully, but these errors were encountered:
Except that I would also suggest to remove minimalistic-assert and minimalistic-crypto-utils from the dependencies too.
Those packages are respectively 10 and 58 lines of code who haven't been updated for 4 and 6 years, just copy them in code's project. No need to add a dependency to an external package for that :) This would definitely reduce the attack surface for a supply chain attack.
elliptic/package.json
Lines 47 to 55 in 43ac7f2
I suggest to switch to developed and audited projects:
bn.js
can be dropped, in favor of native bigints, which have been supported everywhere for a long timebrorand
can be dropped in favor of a simple 5-lines-of-code filehash.js
can be replaced by @noble/hashes, which has been independently audited, and supports tree shakinghmac-drbg
andsecp256k1
implementation can be replaced by @noble/secp256k1, which has been independently audited, uses native bigints, and is getting more and more popular. There is also an optional compatibility layer with old apiinherits
does not seem that useful at this point, since the intro of es6 classesminimalistic-assert
,minimalistic-crypto-utils
can be kept, I suggest to set their versions to a fixed value instead of rangeThe text was updated successfully, but these errors were encountered: