Reputation: 15344
On opening my executable file in MSIL disassembler it shows information of my application(like literals, function, properties, resources,...) even after I assigned them private.
How can I hide these information from disassembler.
Upvotes: 0
Views: 895
Reputation: 2828
Generally speaking you can't. Your best bet if you are worried about someone reverse engineering your code is to consider the following techniques:
The last option pretty much defeats the purpose of .NET assemblies however it will be much harder to reverse engineer from the native assembly to C# code than from MSIL to C#. The reality is though that if someone has your DLL(s) then given enough effort and/or time the original (or fairly close) source can be developed.
Upvotes: 0
Reputation: 9083
An obfuscater. The information will still be there but the names will be nonsense designed to be as confusing as possible.
Upvotes: 1
Reputation: 8521
You want to look for an obfuscation solution. Remember that while private members cannot be accessed by other code, they still do exist. However, obfuscation can make it more difficult to discern what your code is doing.
Upvotes: 4