import { R as GatewayAuthConfig, ct as GatewayTailscaleMode, ft as GatewayTrustedProxyConfig, i as OpenClawConfig, st as GatewayTailscaleConfig } from "./types.openclaw-CXjMEWAQ.js"; //#region src/gateway/auth-resolve.d.ts /** Authentication modes after config, override, and credential inputs are combined. */ type ResolvedGatewayAuthMode = "none" | "token" | "password" | "trusted-proxy"; /** Records which input selected the effective Gateway auth mode. */ type ResolvedGatewayAuthModeSource = "override" | "config" | "password" | "token" | "default"; /** Fully resolved Gateway auth policy before startup validates required secrets. */ type ResolvedGatewayAuth = { mode: ResolvedGatewayAuthMode; modeSource?: ResolvedGatewayAuthModeSource; token?: string; password?: string; allowTailscale: boolean; trustedProxy?: GatewayTrustedProxyConfig; }; /** Resolve Gateway auth mode, credentials, trusted-proxy policy, and Tailscale allowance. */ declare function resolveGatewayAuth(params: { authConfig?: GatewayAuthConfig | null; authOverride?: GatewayAuthConfig | null; env?: NodeJS.ProcessEnv; tailscaleMode?: GatewayTailscaleMode; }): ResolvedGatewayAuth; //#endregion //#region src/gateway/startup-auth.d.ts /** Ensure startup has effective Gateway auth, generating only an ephemeral token if needed. */ declare function ensureGatewayStartupAuth(params: { cfg: OpenClawConfig; env?: NodeJS.ProcessEnv; authOverride?: GatewayAuthConfig; tailscaleOverride?: GatewayTailscaleConfig; warn?: (message: string) => void; /** * Legacy startup option retained for external callers. Startup-generated auth * is runtime-only; durable auth changes must go through explicit config tools. */ persist?: boolean; baseHash?: string; }): Promise<{ cfg: OpenClawConfig; auth: ReturnType; generatedToken?: string; persistedGeneratedToken: boolean; }>; //#endregion export { resolveGatewayAuth as n, ensureGatewayStartupAuth as t };