sqliteAuthenticationHandler.d.ts 881 B

12345678910111213141516
  1. import { IAuthenticationHandler } from "./index.js";
  2. export interface AccountInformation {
  3. username: string;
  4. passwordEncoded: string;
  5. totpSecret: string | null;
  6. }
  7. export type GetAccountInformationFunction = ((username: string) => Promise<AccountInformation | null>);
  8. export type EncodePasswordFunction = ((password: string) => string);
  9. export declare class SqliteAuthenticationHandler implements IAuthenticationHandler {
  10. passwordEncoder: EncodePasswordFunction;
  11. getAccountInformation: GetAccountInformationFunction;
  12. constructor(getAccountInformationFunction: GetAccountInformationFunction, passwordEncoder: EncodePasswordFunction);
  13. needTotp(username: string, _password: string): Promise<boolean | null>;
  14. tryLogin(username: string, password: string, totp?: string): Promise<boolean | null>;
  15. }
  16. //# sourceMappingURL=sqliteAuthenticationHandler.d.ts.map