Skip to main content
Deno 2 is finally here ๐ŸŽ‰๏ธ
Learn more
Module

x/scrypt/lib/format.ts>ScryptParameters

๐Ÿ”‘ Deno library for hashing passwords using scrypt
Go to Latest
interface ScryptParameters
import { type ScryptParameters } from "https://deno.land/x/scrypt@v4.4.1/lib/format.ts";

Available parameters primarily influencing security (and runtime) of scrypt

Properties

optional
logN: logN

log2 of the work factor N. Must be an integer between 1 and 63. Defaults to 17 (N=131072)

optional
r: number

Block size. Defaults to 8

optional
p: number

Parralelism factor. Defaults to 1

optional
salt: string | Uint8Array

custom salt (by default it will be randomly generated)

optional
dklen: number

desired key length (in bytes).

optional
N: number

full number of iterations, if you prefer it over logN (this overrides that setting). Must be a power of 2.