t_wの輪郭

Feedlyでフォローするボタン

err

2022/4/20 16:54:00

errorの短縮系として用いられる。
変数名として用いられることがある。

crypto.pbkdf2の概要

2022/4/20 17:03:00

Provides an asynchronous Password-Based Key Derivation Function 2 (PBKDF2) implementation. A selected HMAC digest algorithm specified by digest is applied to derive a key of the requested byte length (keylen) from the password, salt and iterations.

The supplied callback function is called with two arguments: err and derivedKey. If an error occurs while deriving the key, err will be set; otherwise err will be null. By default, the successfully generated derivedKey will be passed to the callback as a Buffer. An error will be thrown if any of the input arguments specify invalid values or types.

DeepL訳:
非同期のPassword-Based Key Derivation Function 2 (PBKDF2) の実装を提供する。digest で指定された HMAC ダイジェストアルゴリズムが適用され、 password, salt および iterations から要求されたバイト長 (keylen) の鍵を導出する。

与えられた callback 関数はerrderivedKey の2つの引数で呼び出されます。鍵の導出中にエラーが発生した場合は err がセットされ、それ以外の場合は errnull となる。デフォルトでは、正常に生成された derivedKeyBuffer としてコールバックに渡される。入力引数に無効な値や型が指定された場合は、エラーがスローされます。