DEP0009: 没有摘要的 crypto.pbkdf2
类型: 运行时
在 Node.js 6.0 中,不指定摘要的 crypto.pbkdf2() API 已弃用,因为该方法默认使用非推荐的 'SHA1' 摘要。
以前,打印过弃用警告。
从 Node.js 8.0.0 开始,在 digest 设置为 undefined 的情况下调用 crypto.pbkdf2() 或 crypto.pbkdf2Sync() 将抛出 TypeError。
Type: Runtime
Use of the crypto.pbkdf2() API without specifying a digest was deprecated
in Node.js 6.0 because the method defaulted to using the non-recommended
'SHA1' digest. Previously, a deprecation warning was printed. Starting in
Node.js 8.0.0, calling crypto.pbkdf2() or crypto.pbkdf2Sync() with
digest set to undefined will throw a TypeError.
Beginning in Node.js v11.0.0, calling these functions with digest set to
null will print a deprecation warning to align with the behavior when digest
is undefined.