windbg: version of loaded assemblies

1.7k views Asked by At

does anybody know how to figure out the assembly versions (not file versions) of loaded assemblies if I have a full memory dump? Suppose I have a full dump of the .net process and I found two assemblies with the same name loaded in one AppDomain. I need to know what versions those assemblies have. The SOS commands !dumpmodule, !dumpassembly and !dumpdomain do not provide that kind of information or I just missed something.

Thank you in advance.

1

There are 1 answers

1
Jason Evans On BEST ANSWER

You could try the !SaveModule SOS command. This takes the start address of an assembly and creates a new file (the name of which is given by you) to save the contents of the assembly. You could then use something like .NET Refletor to open the file, and it might give you the .NET version somewhere in there. This SO question has some details on that:

How to find out which version of the .NET Framework an executable needs to run?

As for the !SaveModule command, here's a blog article that describes how to use it:

http://blogs.msdn.com/b/tess/archive/2006/05/18/601002.aspx?PageIndex=2