import type { AddressInfo } from "node:net"; import { ChainJournal } from "./audit/ChainJournal.js"; import type { ExecutionJournal } from "./journal/ExecutionJournal.js"; import type { HaltSwitch } from "./incident/HaltSwitch.js"; import { HashChain } from "./audit/HashChain.js"; import type { ExecutorConfig } from "./config/ExecutorConfig.js"; import type { HandlerRegistration } from "./handlers/HandlerRegistration.js"; import { Authenticator } from "./identity/Authenticator.js"; import type { PrincipalRegistry } from "./identity/PrincipalRegistry.js"; import { RateLimiter } from "./identity/RateLimiter.js"; import { type ExecutorMetrics } from "./incident/Metrics.js"; import { HostPosture, type PostureReport } from "./posture/HostPosture.js"; import type { SecretStore } from "./secrets/SecretStore.js"; import { TrustedExecutorService, type ServiceDependencies } from "./service/TrustedExecutorService.js"; export interface TrustedExecutorDependencies extends Omit { /** The posture to verify and follow; the real host unless a fixture is given. */ readonly posture?: HostPosture; /** Where chain heads persist; built from the configuration when absent, none when null. */ readonly chainJournal?: ChainJournal | null; /** Where attempts are journaled; the configured directory unless one is given. */ readonly attempts?: ExecutionJournal; /** The stop; built from the configuration unless a test hands in its own. */ readonly halt?: HaltSwitch; readonly metrics?: ExecutorMetrics; /** The windows and locks the door keeps; a fresh one unless a test injects a clock through its own. */ readonly limits?: RateLimiter; } export interface TrustedExecutorOptions { /** `ExecutorConfigLoader.load(env)`, or a configuration built by trusted startup code. */ readonly config: ExecutorConfig; /** Every secret the configuration names; the executor owns the store from here on. */ readonly secrets: SecretStore; /** The seam: what this process can run. Defaults to the reference forwarding handler. */ readonly handlers?: HandlerRegistration; readonly dependencies?: TrustedExecutorDependencies; } export interface TrustedExecutor { readonly service: TrustedExecutorService; /** The attempt journal this process writes to; the file journal unless one was given. */ readonly attempts: ExecutionJournal; /** The stop, for a test or an embedding process that halts without HTTP. */ readonly halt: HaltSwitch; /** What was verified at start, and what development posture waived. */ readonly posture: PostureReport; readonly metrics: ExecutorMetrics; /** Who may call, as loaded at start. */ readonly principals: PrincipalRegistry; /** The one chokepoint the door calls; exposed so a test can drive it directly. */ readonly authenticator: Authenticator; /** The evidence chain's head: the sequence and hash of the last line written. */ readonly evidence: HashChain; /** Binds the listener and starts following posture drift; the configured port and address unless overridden. */ listen(port?: number, address?: string): Promise; close(): Promise; } /** * The trusted executor, assembled: the host posture verified first, then the * evidence chains restored from the journal, the service behind its one * listener with the adopter's handlers registered and the registry sealed, * every outbound connection through the guarded fetch, every credential * read through the store. Nothing listens until `listen()` is called, and * nothing here reads the process environment except to write lines; that * is `serve()`. */ export declare function createTrustedExecutor(options: TrustedExecutorOptions): Promise; //# sourceMappingURL=TrustedExecutor.d.ts.map