diff --git a/doc/api/crypto.md b/doc/api/crypto.md index 4c55bcaa9cab81..96dcac7f2c460e 100644 --- a/doc/api/crypto.md +++ b/doc/api/crypto.md @@ -3822,10 +3822,13 @@ added: v10.0.0 Enables the FIPS compliant crypto provider in a FIPS-enabled Node.js build. Throws an error if FIPS mode is not available. -### `crypto.sign(algorithm, data, key)` +### `crypto.sign(algorithm, data, key[, callback])` Calculates and returns the signature for `data` using the given private key and @@ -3864,6 +3870,8 @@ additional properties can be passed: size, `crypto.constants.RSA_PSS_SALTLEN_MAX_SIGN` (default) sets it to the maximum permissible value. +If the `callback` function is provided this function uses libuv's threadpool. + ### `crypto.timingSafeEqual(a, b)` Verifies the given signature for `data` using the given key and algorithm. If @@ -3945,6 +3961,8 @@ The `signature` argument is the previously calculated signature for the `data`. Because public keys can be derived from private keys, a private key or a public key may be passed for `key`. +If the `callback` function is provided this function uses libuv's threadpool. + ### `crypto.webcrypto`