Windbg 如何检查未显示在图像列表中但显示在中的.NET程序集的版本!转储域输出?
鉴于: (有很多) 关键是Windbg 如何检查未显示在图像列表中但显示在中的.NET程序集的版本!转储域输出?,windbg,Windbg,鉴于: (有很多) 关键是!DumpDomain识别Dayforce.Common.dll程序集的存在,但lm不识别 我依靠lmvm获取程序集的版本。但在这里我感到困惑: 首先,为什么lm没有看到加载的程序集 在这种情况下,如何获取程序集的版本 请注意,检查托管堆栈可确认已加载程序集,只是映像列表中缺少这些程序集。TLDR:。imgscan/l扫描MZ标头并加载模块信息。然后再试一次 在我的应用程序中,我可以看到,lm没有列出我的程序集。这似乎是一种默认行为,因为我对应用程序中的这些程序集不做
!DumpDomain
识别Dayforce.Common.dll程序集的存在,但lm不识别
我依靠lmvm
获取程序集的版本。但在这里我感到困惑:
lm
没有看到加载的程序集请注意,检查托管堆栈可确认已加载程序集,只是映像列表中缺少这些程序集。TLDR:
。imgscan/l
扫描MZ标头并加载模块信息。然后再试一次
在我的应用程序中,我可以看到,
lm
没有列出我的程序集。这似乎是一种默认行为,因为我对应用程序中的这些程序集不做任何特殊的处理。尝试查找特定的失败:
0:000> lmm *day*
start end module name
0:000> .shell -i- -ci "!DumpDomain" findstr /i "day"
Assembly: 0000005fa3efdbe0 [C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\mobilewebservice\390f679a\951c08b4\assembly\dl3\95cd4f84\7081b1ad_ccc8d101\Dayforce.Common.dll]
00007ff7b82c8ff8 C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\mobilewebservice\390f679a\951c08b4\assembly\dl3\95cd4f84\7081b1ad_ccc8d101\Dayforce.Common.dll
...
但是,执行!DumpDomain
列出了它:
0:009> .symfix d:\debug\symbols
0:009> .reload
Reloading current modules
......................................
0:009> lm m Test*
start end module name
使用.imgscan/l
我能够找到DLL的MZ头并加载模块信息:
0:009> !DumpDomain
[...]
Assembly: 00737f20 [C:\Program Files (x86)\...\TestAdore.dll]
ClassLoader: 0071dd98
SecurityDescriptor: 00729ba8
Module Name
00377440 C:\Program Files (x86)\...\TestAdore.dll
之后,模块出现在lm
列表中:
0:009> .imgscan /l
[...]
MZ at 003a0000, prot 00000002, type 01000000 - size e000
Name: TestAdore.dll
Loaded TestAdore.dll module
并且可以查询版本信息
0:009> lm m Test*
start end module name
003a0000 003ae000 TestAdore (deferred)
程序集的加载方式通常是-.NET运行时加载程序集。这种情况很奇怪,因为这些程序集在图像列表中总是可见的。@ThomasWeller-
。imgscan/l
成功了!它识别.NET模块并加载其模块信息。请将其添加为答案。请注意,程序集版本可能与文件版本不同。在IIRC中,.NET加载程序只考虑前者,而lm
只报告后者。
0:009> lm vm TestAdore
start end module name
003a0000 003ae000 TestAdore (deferred)
Image path: TestAdore.dll
Image name: TestAdore.dll
Has CLR image header, track-debug-data flag not set
Timestamp: Sun Jul 26 23:13:53 2015 (55B54D91)
File version: 1.0.0.0
[...]