Tool to compare .dlls and disassemble the differences?
Check http://www.red-gate.com/products/reflector/
dotPeek from JetBrains can also be used. It is also free.
- Open the assembly up in dotPeek
- Select the assembly
- File --> Export to project
- Choose a location on disk
Repeat the above for the assembly you want to compare, then open the two folders in a diff tool. I used WinMerge.
You'll notice that the vast majority of files have differences. This is because the files have a comment at the top like this
// MVID: {some guid here}
or
// Assembly location: {some path here}
You can create a filter in WinMerge to ignore it
- Tools --> Filter...
- Goto the "Line Filters" tab
- Add the following filter
^// MVID:
- Add the following filter (optional)
^// Assembly location:
- Check the checkbox next to your new Regular Expression
- Check the "Enable Line Filters" checkbox
When you okay the changes, it will rescan the folders and ignore any line that starts with that comment. Now you should see just the changes you're interested in.
Why not disassemble first and then compare?
Reflector has a Diff tool. Note: Reflector is now paid software.
Note: the Diff tool is not available anymore. You can still download it via Softpedia and use it with older versions of Reflector (from around 2010). On later versions it doesn't work anymore.