This article is a mirror article of machine translation, please click here to jump to the original article.

View: 24142|Reply: 0

[ASP.NET] ASP.NET MVC online decompilation of the current website source code

[Copy link]
Posted on 12/20/2020 11:13:37 AM | | | |
There are many .NET decompilation tools, such as ILSpy and dnSpy, all of which open software, select local dlls for decompilation, and view the source code.

Is there any direct decompilation of the source code of the current website online? First, the following rendering is to decompile the current source code online and view the source code:



When there are too many source code branches, each branch may be different, and it is very troublesome to copy the server's dll locally for decompilation each timeThe article takes .NET Framework 4.6.2 as an example to decompile the source code online, limited to .NET Framework dlls.

First, get the assembly that the current application is loaded with, which is all the DLLs, as shown in the image below:



Source:

By selecting the drop-down list name of the assembly as the parameter input method, you can get all types of the assembly (We need to remove the object elements that the compiler generates for us, otherwise there will be many anonymous objects), as shown in the figure below:



The source code is as follows:

Finally, the core of the article, by selecting the assembly and object type, obtain the source code, as shown in the figure below:



Using the package console, install the plugin ICSharpCode.Decompiler with the nuget command, the core of the well-known ILSpy decompiler tool is to call the plugin, the command is as follows:

We use the assembly name and object type name as parameters and pass them in the following method to view the source code.

Decompiling the dll source code

(End)





Previous:ASP.NET Core (ServiceAdmin) enables online management of Windows services
Next:.NET/C# uses FiddlerCore4 to intercept and modify HTTP requests
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com