feat(dotnet): verify managed native boundaries

Add the verify_managed_native_boundaries workflow for comparing authenticated inspect_managed_native_boundaries Evidence with supplied native export or function Evidence. The workflow verifies only P/Invoke declaration names against observed native symbols, keeps verified, inferred, contradicted, unresolved, and unsupported-native states explicit, and does not translate managed metadata tokens or RVAs into native addresses.

Expose schema-identical MCP and CLI surfaces, update managed workflow contracts, product catalog facts, TypeDoc output, README/localized docs, ADR status, package verification, and the REA analysis skill metadata for the 90-tool/50-command inventory.

Verification: npx vitest run tests/managedNativeVerification.test.ts --coverage=false; npm run typecheck; npm run docs:generate; npm run check (first run hit a load-sensitive sessionMcp timeout, isolated rerun passed); npx vitest run tests/sessionMcp.test.ts --coverage=false; npm run check; npm run knip; npm run jscpd; npm run scan:todos; npm run verify:managed; CXX=/usr/bin/g++-13 CC=/usr/bin/gcc-13 npm run verify:package.
This commit is contained in:
N0zoM1z0
2026-07-16 21:26:38 +09:00
committed by N0zoM1z0
parent cc1e47c615
commit 8cbc125b93
97 changed files with 1857 additions and 160 deletions
+20
View File
@@ -11,6 +11,7 @@ import { AnalysisProviderRegistry } from "../src/application/AnalysisProviderReg
import { BinarySession } from "../src/application/BinarySession.js";
import { createPermissionAuthority } from "../src/application/PermissionAuthority.js";
import { SessionProviderRouter } from "../src/application/SessionProviderRouter.js";
import { MANAGED_NATIVE_VERIFICATION_EXAMPLE } from "../src/contracts/managedWorkflowExamples.js";
import type { PermissionCeiling } from "../src/domain/permissionPolicy.js";
import { ManagedStaticProvider } from "../src/dotnet/ManagedStaticProvider.js";
import { createServer } from "../src/server/createServer.js";
@@ -92,9 +93,28 @@ describe("managed artifact MCP tools", () => {
expect(tools.tools.map(({ name }) => name)).toContain(
"import_managed_reconstruction",
);
expect(tools.tools.map(({ name }) => name)).toContain(
"verify_managed_native_boundaries",
);
expect(tools.tools.map(({ name }) => name)).toContain(
"plan_managed_runtime_correlation",
);
const verifiedNative = structured(
await client.callTool({
name: "verify_managed_native_boundaries",
arguments: MANAGED_NATIVE_VERIFICATION_EXAMPLE,
}),
);
expect(verifiedNative).toMatchObject({
operation: "verify_managed_native_boundaries",
provider: { id: "rea-dotnet-workflows" },
confidence: "inferred",
normalized_result: {
summary: { verified: 1 },
algorithm: { token_to_address_mapping: "not-inferred" },
},
});
await client.callTool({
name: "open_binary",