Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Tool to compare .dlls and disassemble the differences? [closed]

Tags:

Does anyone know a decent tool that will compare two different versions of the same dll and extract the differences?

thanks

like image 232
flesh Avatar asked Feb 26 '09 14:02

flesh


People also ask

Can we compare two dlls?

You can even compare entire directories. This is of course if you just need to know if they're the same, since it won't show you any code.

How can I compare two DLL files online?

Use . NET Reflector (Free version is all you need) to open the dlls then right-click and choose to export them to separate directories. Then use ExamDiff Pro to compare the directories (You can get a 30-Day free trial).


1 Answers

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.

like image 63
Colin Mackay Avatar answered Sep 18 '22 17:09

Colin Mackay