When your .NET project is compiled Visual Studio generates an Assembly containing Microsoft Intermediate Language (MSIL) instructions, managed resources and meta data describing the types, methods, properties, fields and events in your assembly.
Obfuscation is the process of renaming this meta-data in an Assembly so that it is no longer useful to a hacker but remains usable to the machine for executing the intended operations. It does not modify the actual instructions or mask them from observation by a hacker.
These samples demonstrates only the most basic obfuscation and code encryption. Imagine instead a large class library with many methods and properties sharing the name 'A'. It would be difficult for a hacker to determine which method is actually being called or what that method does. CodeVeil uses many more advanced techniques to maximize the confusion added by obfuscation and to thwart hackers form even observing the obfuscated code in any sort of offline browsing tool like Reflector or ILDASM.
Zero Width Strings uses a special name encoding to collapse all names into a string that renders zero pixels wide. This is the most difficult code to read.
|Cryptographically hashed names use a simple name transform using the cryptographic hash of the original name to generate the new obfuscated name.|
|Simple ASCII renames members by selecting sequentially available ASCII characters.|
CodeVeil uses a powerful rule and analysis system to determine what meta-data is safe for renaming. When the default rules do not satisfy your needs you can specify your own custom rules.
DeployLX CodeVeil does a very good job at applying the obfuscation rules while enforcing intrinsic expectations of the .NET runtime. Sometimes however CodeVeil cannot identify all the conditions or dependencies of a class or resource and obfuscation can introduce unexpected errors. See the Troubleshooting Obfuscation Problems topic for details on resolving such issues.