Reflector is a necessary decompilation tool in. NET development. Even if it is not used in the decompilation field, it is often used to checkProgramSet naming rules, whether the namespace is reasonable, and whether the organization type method needs to be improved. For example, you can view the complete name of an assembly.
The name here is the complete identifier of an assembly. When multiple versions of the Assembly exist in GAC, this name is a unique recognition name.
However, reflector has switched to paid software for a long time and requires a license. Friends who are ashamed of using pirated files often give up. Some friends said that reflector did not add more aggressive features, but switched to charging, which is confusing. Let's take a look at the. NET decompilation software on the market, which was defeated by reflector.
When talking about reflector and. Net decompilation, reflector is often the default preferred tool.
The monopoly of Visual Studio is mentioned here. Visual Studio occupies the absolute monopoly of the. NET development tool series. In the. NET 1. x era, there are also C # builder and Delphi. Net to use and experience. But later ,. net framwork is updated frequently, and changes are made at the compiler level and language level, which makes third-party software development tool vendors very worried. These tools are also gradually removed from the market, almost no third-party software developers are willing to develop.. NET development tools and Visual Studio. Without competition, the progress will be much slower. Visual Studio 2008 is almost a substitute for Visual Studio 2005 + sp. At the tool level, Visual Studio 2005 SP1 is added with web application, that is, Visual Studio 2008. Although the language layer has improved a lot ,. net 3.0 ,. net 3.5, LINQ, and framework Methods Added: WCF, WPF, and WF. However, I have always known that from 2005 to 2008, there is no progress in the tool layer.
Sharpdevelop is the only. Net open tool available in addition to Visual Studio and is open-source. It provides quite good functions, almost just rewriting Visual Studio. In the latest version, support for Visual Studio's solution file and project file is directly added. Ilspy is The Decompilation tool of sharpdevelop group and is also openSource codeToday, we will introduce its debugger and anti-compiler, so that the reflector out with no overhead function is provided.
The interface of ilspy is similar to that of reflector. The tree control on the left shows the dataset and its type, and the corresponding source is on the right.Code. The basic decompilation function is not inferior to reflector. Sometimes, reflector cannot be used to decompile (because of encryption) the Assembly. ilspy can be used to decompile the assembly.
Decompiler anti-Compiler
The basic type decompilation function is available. Currently, only the source code can be decompiled into C # And il languages, and VB is not supported.
When you need to find an assembly that is A. NET Framework, you can directly open the Assembly from the menu file-open from GAC to view the source code.
The Code saving function is also good. When you click a type, selecting File> Save code will decompile the current type and save it to the specified file. When you select an assembly, save code is saved as a project (csproj) file, and all its types are added to this project.
Debugger
The debugger here is not the source code-level debugger of Visual Studio, but the debugger of the Assembly. Reflector has an addin that can be directly attached to Visual Studio to debug a third-party Type Library, without the need to decompile a third-party Type Library and add it to the project in the form of source code.
Ilspy also provides this function to debug third-party Assembly directly. There are two options:
If the third-party library is an executable program (exe), you can use DEBUG an executable to start this program.
If the third-party type library is an assembly (DLL), attach to running application to start assembly debugging.
The above two figures show its usage, which is the same as debugging source code. Set the breakpoint where you want to monitor the value of a variable. When the program runs, you can monitor the value of a variable through the form. From the status bar of ilspy, we can see that the first figure above is in the debugging status, and the second figure is ready for debugging.
The difference between the two is that during debugging by attach to a running application, if the code is optimized by the compiler, the monitor cannot get its value.
The value of the variable num being debugged cannot be displayed because the code has been optimized. The recommended method is debug an executable.
And debug in Visual Studio.. net source code is the same. You can step into, step over, and continue. At the same time, the status bar will be displayed as stand by, running, and debugging ).
In addition to debugging the C #/VB code of the assembly, you can also debug the code in the form of IL code, as shown in
From this point of view, this is a very good tool for debugging il code. Tools can promote the learning effect. After learning and understanding, tools can be promoted. This is an endless development of knowledge.
The debugger of ilspy exists as a plug-in. Ensure that the plug-in contains ilspy. debugger.
According to our understanding, debugging A. Net Assembly requires a PDB file. However, ilspy does not generate a PDB file (No PDB files are generated), and it cannot debug ASP. NET web applications and Web services.
The principle is not clear. Compiler/debugger has always been my favorite technical topic, but it is superficial and cannot be shared.
Reflector detects that the system time has exceeded its preset time. If it is not upgraded, it will take the initiative to delete itself and remove it from your computer. If you are worried about this, let it go out. You can have another option. Try ilspy, which may bring a little surprise.