Obfuscating .NET code so as to hide implementation details from public view (using BabelObfuscator)


/ Published in: C#
Save to your folder(s)

If you weren't already aware, you can use a product like [Reflector.NET](http://www.red-gate.com/products/reflector/) to see all of the source code (that's right, the code) of a .NET assembly (DLL, EXE, etc). This is a real problem when your code is proprietary, especially when you might have security implementations in the code. Thus, there is often a need to hide the implementation details - enter obfucation.

There is a [article on and list of obfuscators from C# 411](http://www.csharp411.com/net-obfuscators/) which explains the situation better. From my research, I decided to settle on the free and open source [Babel Obfuscator](http://code.google.com/p/babelobfuscator/). Part of the decision process was seeing it in action, which is especially easy when you install the [Babel add-in for Reflector](http://www.jasonhaley.com/blog/post/2009/08/18/ReflectorBabel-Addin.aspx).

Once you've decided that Babel is for you, the code below automates the process when added to the post-build event of your assembly. The parameters and settings are up to you, but this baseline should do everything you'll need.


Copy this code and paste it in your HTML
  1. "c:\Program Files\Babel\babel.exe" --types --events --methods --properties --fields --stringencrypt $(TargetPath)

URL: http://www.csharp411.com/net-obfuscators/

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.