You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
currently i made a custom one in my own project using upash. If it can help:
/// <reference types="node" />declare module "upash"{typePHCstring=string;namespaceUpash{/** * Installs a compatible password hashing function. */functioninstall(name: string,algorithm: {hash(password: string,options?: {[key: string]: any}): Promise<PHCstring>;verify(phcString: PHCstring,password: string): Promise<boolean>;}): void;/** * Gets the list of the installed password hashing functions. */functionlist(): string[];/** * Uninstalls a password hashing function previously installed. */functionuninstall(name: string): void;/** * Selects manually which password hashing function to use. You can call hash and verify on the object returned. */functionuse(name: string): {hash: typeofhash;verify: typeofverify;};/** * Returns the name of the algorithm that has generated the hash string. */functionwhich(name: PHCstring): string;/** * Computes the hash string of the given password in the PHC format using argon2 package. * @returns a hash with the PHC string format (see https://github.com/P-H-C/phc-string-format/blob/master/phc-sf-spec.md) */functionhash(password: string,options?: {[key: string]: any}): Promise<PHCstring>;/** * Determines whether or not the hash stored inside the PHC formatted string matches the hash generated for the password provided. */functionverify(phcString: PHCstring,password: string): Promise<boolean>;}export=Upash;}
The text was updated successfully, but these errors were encountered:
please add typescript definition
currently i made a custom one in my own project using upash. If it can help:
The text was updated successfully, but these errors were encountered: