Ghidra, BSim and ghidriff integration

Verified against commit 942a18727c (2026-09-26). Re-verify with: git grep -n "AddGhidra(" -- src ':!src/__Obsoleted' ':!src/BinaryIndex' (no match means no host registers the integration) and pwsh tools/scripts/test-targeted-xunit.ps1 -Project src/BinaryIndex/__Tests/StellaOps.BinaryIndex.Ghidra.Tests/StellaOps.BinaryIndex.Ghidra.Tests.csproj -BuildProjectReferences -Restore.

Status

src/BinaryIndex/__Libraries/StellaOps.BinaryIndex.Ghidra/ is a retained shared analysis library. No shipped host registers it. AddGhidra has no caller outside the library and its tests. The result:

Installing Ghidra, a BSim database or ghidriff therefore has no effect on a Stella Ops installation at the verified commit.

Library components

TypeBehavior
GhidraHeadlessManager, GhidraService (IGhidraService)Run analyzeHeadless from GhidraHome as a local process
GhidriffBridge (IGhidriffBridge)Run the ghidriff Python module as a local process
VersionTrackingService (IVersionTrackingService)Ghidra version-tracking comparisons through the headless manager
BSimService (IBSimService)Queries return empty results; ingestion throws NotImplementedException. There is no BSim database client
GhidraDisassemblyPlugin (IDisassemblyPlugin)Returns function boundaries from Ghidra analysis with synthesized placeholder instructions (mnemonic GHIDRA), not real disassembly

Configuration

AddGhidra(IConfiguration) binds three sections. The options are validated on start; Ghidra:GhidraHome is required.

SectionKeyDefault
GhidraGhidraHomenone (required)
JavaHomesystem JAVA_HOME
WorkDir<temp>/stellaops-ghidra
ScriptsDirnone
MaxMemory4G
MaxCpuprocessor count
DefaultTimeoutSeconds300
CleanupTempProjectstrue
MaxConcurrentInstances1
Enabledtrue
BSimConnectionString or Host, Port, Database, Username, Passwordlocalhost, 5432, bsim, bsim
DefaultMinSimilarity, DefaultMaxResults0.7, 10
Enabledfalse
GhidriffPythonPathpython on Windows, python3 elsewhere, resolved from PATH
GhidriffModulePathnone
DefaultIncludeDecompilation, DefaultIncludeDisassemblytrue, true
DefaultTimeoutSeconds600
WorkDir<temp>/stellaops-ghidriff
Enabledtrue

Runtime assets

History

The earlier deployment guide and BSim setup guide, which described these components as a production deployment, are archived unchanged under docs-archive/modules/binary-index/ (ghidra-deployment.md, bsim-setup.md).