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
Add ARelaxCostRestriction parameter to Scrypt (#41)
Add ARelaxCostRestriction parameter to Scrypt to allow N >= 65536 when r = 1
The RFC 7914 constraint N < 2^(128*r/8) was confirmed by Colin Percival
(Scrypt creator and RFC co-author) to be an accidental error in the RFC.
The intended bound was N < 2^(128*r*8), which is trivially satisfied.
RFC errata 5971, 5972, 5973 have been filed.
The Ethereum Web3 Secret Storage standard uses N=262144, r=1, p=8 as its
default Scrypt parameters. These are widely used in practice (geth, web3.py,
web3.js, etc.) and accepted by the Scrypt reference implementation (Tarsnap)
and Go's x/crypto/scrypt, but were rejected by the existing validation.
A new ARelaxCostRestriction default parameter (False) is added to
ValidatePBKDF_ScryptInputs, the constructor, and CreatePBKDF_Scrypt.
When True, the erroneous cost/blocksize check is skipped. Existing
callers are unaffected.
See: golang/go#33703 (comment)
0 commit comments