About dotnet-native-mcp
dotnet-native-mcp is an MCP server published by pedrosakuma in the Social category: mCP server exposing dotnet-native-mcp Core native-binary navigation primitives (PE/ELF/Mach-O, x86_64+ARM64). Supports stdio (local tool installs) and Streamable HTTP (Docker / sidecar) transports.
The repository has 1 stars and 0 forks, with the last commit a month ago. Recent commit activity is the strongest signal that reported issues will get attention.
Install
git clone https://github.com/pedrosakuma/dotnet-native-mcpThis server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.
Tools (13)
compare_native_binariesDiff two loaded images: build-id, format, arch, file/section size deltas, added/removed/size-changed symbols. When both images have a sibling `.mstat` sidecar, also emits a managed "what grew between two builds?" size diff (build-level total delta plus top grown/shrunk buckets) at a chosen grouping (assembly/namespace/type/method/category).
Parameters not published.
disassembleIced x86/x64 and AsmArm64 ARM64 disassembly with CALL/JMP/BL cross-ref hints. Default 64 instructions, capped at 2048. `resolveSource=false` (default) skips per-instruction DWARF lookup; set `true` to annotate each instruction with file:line. **Two modes:** registered-handle mode (`imageHandle` + `address`/`symbolName`) for images loaded via `load_native_binary`; or raw-bytes mode (`imagePath` + `rva` + `size`) for any PE/ELF/Mach-O — including managed PEs with R2R bodies — without a prior `load_native_binary` call.
Parameters not published.
explain_retentionRead the DGML reachability sidecar emitted by NativeAOT and return root → target retention paths — with the ILC retention reason on each edge (e.g. `call`, `Reflectable type`, `Virtual method`), each edge classified into a kind (`Reflection`, `Generics`, `VirtualDispatch`, `DirectCode`, `Structural`). Every path gets a verdict — `reflection-driven` (potentially trimmable) when any edge is reflection/metadata-driven, otherwise `structural`. With `includeSizeCost` (default on) each node is priced with the native bytes the `.mstat` sidecar attributes to it and each path reports the total bytes it keeps alive. `maxPaths>1` returns the shortest chain from each distinct root (the independent reasons a type/method stays in the binary); ambiguous queries surface under `Candidates`.
Parameters not published.
extract_stringsPaginated printable ASCII / UTF-16LE scan over `.rodata` / `.rdata` / `.data.rel.ro` / `__const` (with `.data` fallback). Returns section + offset for forensics.
Parameters not published.
find_native_callersLazily-built xref index: scan all executable sections of a loaded x86-64 or ARM64 image and return every CALL/JMP/BL instruction that targets a given symbol name or hex address. The index is cached in-process (L1) and persisted to disk under `~/.cache/dotnet-native-mcp/<build-id>.xref` (L2) so large NativeAOT binaries pay the scan cost only once across sessions. `crossImage=true` resolves call sites that branch into PLT/import/stub thunks of other loaded images (ELF PLT entries account for the architecture-specific PLT0 header — 16 bytes on x86-64, 32 on AArch64). `resolveSource=true` (default) annotates each call site with file:line; set `false` to skip PDB I/O for large binaries.
Parameters not published.
get_r2r_headerRead the ReadyToRun header of a managed PE: version, decoded `READYTORUN_FLAG_*` names, full sections table, and the `CompilerIdentifier` (type 100) / `OwnerCompositeExecutable` (type 116) strings. `includeImportSections=true` decodes the ImportSections (type 101) fixup-region metadata; `includeCompositeInfo=true` decodes the composite-image `ComponentAssemblies` (type 115) entries and `ManifestAssemblyMvids` (type 118) GUIDs; `includeMethodEntryPoints=true` decodes the `MethodDefEntryPoints` (type 103) NativeFormat array into a MethodDef RID → `RUNTIME_FUNCTION` index mapping (with a has-fixups flag), capped by `methodEntryPointsLimit`; `includeAvailableTypes=true` decodes the `AvailableTypes` (type 108) NativeFormat hashtable into TypeDef (0x02) / ExportedType (0x27) metadata tokens for handoff to `dotnet-assembly-mcp`, capped by `availableTypesLimit`; `includeInfoMaps=true` decodes the V9 RID-indexed info maps — `EnclosingTypeMap` (type 122, nested→enclosing type tokens), `MethodIsGenericMap` (type 121, generic-method tokens) and `TypeGenericInfoMap` (type 123, per-type generic arity/variance/constraints) — capped by `infoMapsLimit`; `includeManifestMetadata=true` surfaces the `ManifestMetadata` (type 112) embedded ECMA-335 blob as a handoff descriptor (file offset, RVA, size, version string and stream directory) without decoding the managed metadata itself; `includeHotColdMap=true` decodes the `HotColdMap` (type 120) section into (cold, hot) `RUNTIME_FUNCTION` index pairs (capped by `infoMapsLimit`). Returns `r2r_not_present` for pure-managed or NativeAOT binaries.
Parameters not published.
get_size_breakdownRead the `.mstat` sidecar emitted by NativeAOT and aggregate native bytes by assembly, namespace, type, method, or category. Counts method bodies (code + GC + EH info), EETypes/types, and the Blobs catch-all (dehydrated data, runtime metadata, frozen-object regions, RVA static fields, manifest resources) for complete, non-overlapping accounting, and reports the mstat format version, a per-category summary, and the deduplicated-method count.
Parameters not published.
import_native_manifestBulk handshake from a producer (typically `dotnet-diagnostics-mcp`): register a list of native binaries in one call. Accepts `entries: [{path, name?, buildId?}]` + `mode` (`lazy`\
Parameters not published.
list_native_importsPaginated import/dependency walk. `kind="functions"` lists ELF undefined `.dynsym` imports or PE Import Directory entries; `kind="libraries"` lists ELF `DT_NEEDED` or PE imported DLL names.
Parameters not published.
list_native_symbolsPaginated symbol table. Source priority: `.map` sidecar → ELF `.symtab`/`.dynsym` → PE export table. Includes raw + demangled names.
Parameters not published.
Show all 13 tools
list_r2r_runtime_functionsPaginated `RUNTIME_FUNCTION` entries from the RuntimeFunctions section (type 102), or — with `rva` — a binary-search lookup of the single covering entry. x64 + ARM64; other arches return `r2r_arch_unsupported`.
Parameters not published.
load_native_binaryOpen a PE/ELF/Mach-O, verify it's a managed-flavored native build, return a handle. Accepts `path` + optional `buildId`.
Parameters not published.
resolve_symbolsBatch address ↔ symbol lookup with ILC demangling. Accepts up to 200 hex (`0x`-prefixed or bare) or decimal address strings against a single image. An optional `loadBase` rebases absolute runtime VAs (`rva = address - loadBase`) so ASLR'd position-independent (PIE) NativeAOT frames resolve. Per-address failures are reported inline without failing the whole batch. Replaces the former single-address `resolve_symbol` and multi-frame `symbolicate_stack` tools.
Parameters not published.
Ask AI
Ask AI about dotnet-native-mcp
Powered by Claude · Grounded in docs
Security checks
6 checks have not been run yet.