import { scrypt as _scrypt , scryptAsync as _scryptAsync } from "@noble/hashes/scrypt" ; import { assertBytes } from "./utils" ; export async function scrypt ( password , salt , n , p , r , dklen ) { assertBytes ( password ) ; assertBytes ( salt ) ; return _scryptAsync ( password , salt , { N : n , r , p , dkLen : dklen } ) ; } export function scryptSync ( password , salt , n , p , r , dklen ) { assertBytes ( password ) ; assertBytes ( salt ) ; return _scrypt ( password , salt , { N : n , r , p , dkLen : dklen } ) ; }