English 中文(简体)
Practices for hiding the executable code of compiled applications
原标题:

It s a standard practice to decompile and reverse engineer .net assemblies.

I d like to release some plugin assemblies that will add to existing applications, but I don t want them to be utilized by others.

What are some ways I can hide the source of these assemblies?

最佳回答

It s theoretically impossible to achieve 100% protection unless you control the target hardware. If the CPU is able to execute it, given enough time and knowledge, a human being can read it too. This is not even limited to C# (although it s usually easier to do in managed languages). You can use an obfuscator like Dotfuscator or XenoCode to make it harder to understand the decompiled code. If you re really concerned, you should move to a server-based application.

问题回答

You can use an obfuscator tool, it will help but reverse engineering will still be very possible.

Your users computer needs to know what it needs to do, so you have to tell it. The owner of the computer has total control over it, and can therefore know himself what you told the computer to do, and he can tell it to do something else.

There is a way to hide the data, its called steganography. There s an author of a number of articles covered on CodeProject, who wrote a framework for doing exactly this. The title of the articles were Steganography in a series from 1 up to 12 I think. This is the website that is affiliated with the author.

There is a also a obfuscator called Phoenix Protector , found here, which can obfuscate the .NET code, personally, I have not tried it but it sounds good.

Hope this helps, Best regards, Tom.

It s software; anything is possible. You can encrypt your binaries, and then decrypt all or part of them into your application at runtime. It s not foolproof, but it s up to you to decide how draconian you want to be.

You can write an app that will host CLR using the CLR COM api, that way you can first load and decode the assembly at the native code level. If you reinforce the native loader using several anti-reverse engeneering techniques, you can achieve good enough security.

At the very least, you should obfuscate your dlls to prevent hackers & competitors from viewing and making sense of your code. Obfuscation is not 100% foolproof, but it presents a big enough obstacle in their path.

Some obfuscators such as Crypto Obfuscator have a feature of embedding all dlls in the main exe so your dlls are not explicitly visible and available on disk to open in reverse-engineering tools such as Reflector.





相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

NSArray s, Primitive types and Boxing Oh My!

I m pretty new to the Objective-C world and I have a long history with .net/C# so naturally I m inclined to use my C# wits. Now here s the question: I feel really inclined to create some type of ...

C# Marshal / Pinvoke CBitmap?

I cannot figure out how to marshal a C++ CBitmap to a C# Bitmap or Image class. My import looks like this: [DllImport(@"test.dll", CharSet = CharSet.Unicode)] public static extern IntPtr ...

How to Use Ghostscript DLL to convert PDF to PDF/A

How to user GhostScript DLL to convert PDF to PDF/A. I know I kind of have to call the exported function of gsdll32.dll whose name is gsapi_init_with_args, but how do i pass the right arguments? BTW, ...

Linqy no matchy

Maybe it s something I m doing wrong. I m just learning Linq because I m bored. And so far so good. I made a little program and it basically just outputs all matches (foreach) into a label control. ...

热门标签