Reverse engineer anything with agents, from app behavior down to native binaries.
TypeScript agent-skillsai-agentsbinary-analysisclaude-codeclicodexcordisdecompilerdeveloper-toolsdshdsh-pluginghidrahopperllmmcpmodel-context-protocolreareverse-engineeringstatic-analysistouhou
Implementation plan
- Add
src/application/environment/environmentSource.tsto authenticate the two Evidence files, require the manifest view kind and the capture operation, refuse a parent mismatch, and reduce every cited record to its request line, status, content type and retained response text through the slice-1 request-line reader, so the server holds only what replay returns. - Add
environmentTools.tsto map manifest tools to MCP tool definitions with one hand-built JSON Schema per tool that bothregisterTool(through the SDK'sfromJsonSchema) and the card consume, and to build the card in the echo example's key order. - Add
environmentReplay.tsto score cited records by path-segment matches, then query matches, keep manifest order on ties, and shape the replay result with JSON-like parsing, UTF-8-safe truncation and the replay provenance block; export the slice-1 JSON-like predicate instead of restating it. - Add
src/server/environment/serveEnvironment.tsto build theMcpServerwhose handlers attach REA's target-content_meta, the card and/agentenvroutes (the latter reading its body through the SDK's bounded reader), and to serve them through the slice-2serveStreamableHttpwith itsroutesandonerrorseams; addsrc/config/environmentName.tsforENVIRONMENT_NAME. - Add
src/cli/environmentCommands.tsregisteringenvironment-servethroughwithCommandCancellationandlogCliCommand, resolving host and port with the slice-2 endpoint parser, reading files throughparseCliJsonInput, importing the listener lazily, awaiting the cancellation signal or a listener failure and returning onestoppeddocument or a typed error; register the name inCLI_COMMANDSand the lazy module in the startup import probe. - Share the fixture pair through
tests/fixtures/environmentServe.tsand the listener spawn through a generalisedstartListeningProcess; add services, adapters, mcp-boundary, cli-boundary and process-boundary tests. - Document the command in
docs/cli.md, adddocs/agent-environments.mdwith its sidebar and index entries, and record the spec.
No new dependency is introduced. REA's tool contracts, catalog digests and the stdio transport are unchanged; the CLI inventory gains one command.