Decompiling the .NET Framework v4.5 executable "not a .NET assembly file" in dotPeek, but the executable works fine

The client burned the bridges with his previous developer, and I'm trying to extract the source code from what remains of the payroll executable, unfortunately, as a web developer. I do not have much experience with the .NET platform.

EDIT: our client legally owns the software, but does not request the source code, the developers do not respond to our messages. My intention to ask this question on SO was not for legal advice (we have people who handle this), but for any options available for decompilation.

I successfully decompiled executables with JetBrains dotPeek, but they all ran .Net Framework v2.0/v4.5 frameworks. The payroll executable file of the client I'm working with is currently running .Net Core v4.5 , which is not recognized by dotPeek, ILSpy, or other C # decompilation software that I ran as a .NET assembly file.

After a little research, I believe that .Net Core was a recently opened source ... however, I am not sure how I can continue the decompilation process, or if this is possible even at this point. Any recommendations?

Note. I agree to answer the question "it is impossible to decompile, but did you try X, Y, Z first?" I need to tell the client whether this can be done or not, since we are doing a tight schedule.

Some clarification of what I did: Opened program.exe in dotPeek, right click properties give me this:

enter image description here

He claims that the "build file is not .NET", but I can run the executable.

EDIT: Is it possible to extract additional information from the executable so that I can narrow down another method for decompiling?

I suspect .NET decompilers will not help here.

+6
source share
3 answers

The developer asked a legitimate programming question on the development website and deserved an educated answer. Unwanted legal advice. There are many legitimate reasons for decompiling a dll.

When dotnetpeak assumes the file was developed using ".Net Core v4.5" and does not have an MVID, he would assume that the CLR header is missing from the file.

If you decompile the file back to the assembly, you will probably find the identification tokens that were created in VB6.

Find a good VB6 compiler, and you can probably decompile the program without a big problem. Unfortunately, you cannot completely decompile vb6 back to source, but you can get a pretty good idea of ​​how the application was created.

+5
source

There is nothing special about a .NET assembly that targets the .NET Core runtime. It just uses different reference assemblies. You will have to talk about this decompiler to use the correct version of mscorlib et al. Regardless of the purpose of the program, Silverlight will be the only reasonable one, given the probable age, .NETCore is too new.

But the most likely problem that you have in such a scenario is that the programmer protected his IP by confusing his builds. Payroll programs are almost always created by contract, the client only pays for the setup work and does not have legal rights to the kernel or source code.

+2
source

.net core is the open source version of .net currently working. You can see the progress every day on the public github page on microsoft corefx

I am a little confused about what .net core means in the question, but in my opinion there is not yet a final .net 4.5 kernel, and even though it is certainly useful yet incomplete, why would anyone use it in production code?

Read this blog post for more details.

0
source

Source: https://habr.com/ru/post/980463/


All Articles