Delay-load dbghelp.dll in bindiff_similarity (Fix #1860) - #8452
Open
xusheng6 wants to merge 1 commit into
Open
Conversation
bindiff_similarity links bindiff/binexport, which pull in Abseil's Win32 symbolizer and its static import of dbghelp.dll. Plugin init therefore maps C:\Windows\System32\dbghelp.dll into the process before the debugger gets a chance to load the WinDbg copy it needs by full path. PE imports resolve by base name, so the already-mapped System32 module wins and dbgeng.dll fails to load with ERROR_PROC_NOT_FOUND -- WinDbg 10.0.29547's dbgeng needs SymGetSymbolsNegativeAuthCache, which System32 dbghelp 10.0.26100 does not export. The result is "Failed to load DbgEng DLLs, the DbgEng adapter cannot work properly" whenever bindiff_similarity is present. /DELAYLOAD:dbghelp.dll defers the bind until the symbolizer is actually used, matching what binaryninjacore, crashreporter, debuggercore and the upstream bindiff/binexport plugin targets already do. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015SdEhA6Lo2qAi7YjarCxQY
xusheng6
force-pushed
the
test_1860_bindiff_dbghelp_delayload
branch
from
August 22, 2026 00:21
cf287c6 to
750bc42
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
bindiff_similaritylinks bindiff/binexport, which pull in Abseil's Win32 symbolizer and its static import ofdbghelp.dll. Plugin init therefore maps System32's dbghelp before the debugger can load the WinDbg copy by full path. PE imports resolve by base name, sodbgeng.dllbinds against the wrong one and fails withERROR_PROC_NOT_FOUND(WinDbg 29547 needsSymGetSymbolsNegativeAuthCache, absent from System32 dbghelp 26100)./DELAYLOAD:dbghelp.dlldefers the bind until the symbolizer is actually used. Same treatmentbinaryninjacore,crashreporter,debuggercoreand the upstream bindiff/binexport plugin targets already have.Vector35/binaryninja#1860