* fix(test): honor Ghidra startup budgets in file-offset verification * fix(test): preserve selected startup budgets in direct Ghidra verification * test(ghidra): cover verifier timeout budgets * fix(test): preserve Ghidra MCP request budgets
34 lines
990 B
TypeScript
34 lines
990 B
TypeScript
export interface GhidraVerifierTimeouts {
|
|
readonly clientOptions: {
|
|
readonly startupTimeoutMs: number;
|
|
};
|
|
readonly requestOptions: {
|
|
readonly timeout: number;
|
|
};
|
|
}
|
|
|
|
/** Resolve one verifier-owned timeout policy before target I/O or allocation. */
|
|
export function resolveGhidraVerifierTimeouts(
|
|
environment: Readonly<Record<string, string | undefined>>,
|
|
): GhidraVerifierTimeouts;
|
|
|
|
export interface GhidraVerifierMcpClient {
|
|
connect(
|
|
transport: unknown,
|
|
options: GhidraVerifierTimeouts["requestOptions"],
|
|
): Promise<void>;
|
|
callTool(
|
|
request: unknown,
|
|
options: GhidraVerifierTimeouts["requestOptions"],
|
|
): Promise<unknown>;
|
|
}
|
|
|
|
/** Bind every verifier MCP operation to the same owned request budget. */
|
|
export function createGhidraVerifierMcpOperations(
|
|
client: GhidraVerifierMcpClient,
|
|
requestOptions: GhidraVerifierTimeouts["requestOptions"],
|
|
): {
|
|
connect(transport: unknown): Promise<void>;
|
|
callTool(request: unknown): Promise<unknown>;
|
|
};
|