import type { RequestHandler } from "express";
export declare const DAEMON_PASSWORD_BCRYPT_COST = 12;
export interface DaemonAuthConfig {
    password?: string;
}
export interface BearerAuthRejectContext {
    path: string;
    method: string;
    hasToken: boolean;
}
interface BearerValidationInput {
    password: string | undefined;
    token: string | null;
}
export declare function isBearerTokenValid(input: BearerValidationInput): boolean;
export declare function isBearerTokenValidAsync(input: BearerValidationInput): Promise<boolean>;
export declare function isBearerTokenValidSync(input: BearerValidationInput): boolean;
export declare function hashDaemonPassword(password: string): string;
export declare function extractHttpBearerToken(value: string | undefined): string | null;
export declare function extractWsBearerProtocol(value: string | undefined): string | null;
export declare function extractWsBearerToken(protocol: string | null): string | null;
export declare function createRequireBearerMiddleware(auth: DaemonAuthConfig | undefined, onReject?: (context: BearerAuthRejectContext) => void): RequestHandler;
export declare function shouldBypassBearerAuth(method: string, path: string): boolean;
export {};
//# sourceMappingURL=auth.d.ts.map