Attribute-Based Obfuscation

Sometimes you might feel the urge to apply specific protections to special parts of your code, attribute based obfuscation (also known as declarative obfuscation) allows you to choose which features to apply on a given type or method.

For example, your application might be formed by two main components, one linked with the authentication and copy protection of your software, and another one which is the core of your application itself. In those scenarios, it makes perfect sense to use a lightweight obfuscation in the whole assembly and more aggressive protection on the anti-piracy part.

Simultaneously, you might find yourself looking to add exceptions or special rules to certain methods or types, all that and more is possible with our SDK.

Legacy tools tended to rely on the Obfuscation Attribute shipped within .NET itself. This attribute works well until more complex scenarios and sub-settings of obfuscation technologies appear. For this reason, ever since our first public release, we recommend using our SDK instead of the classical Obfuscation Attribute.

Our SDK allows you to place rules in the most human-friendly manner, we achieve this by making a separated attribute for each one of our protections.

Suppose that there is a method that you want to protect more than others. You can achieve this by using the proper protection attributes.

[Virtualization()]
public static void MyImportantMethod()
{
// Your code goes in here
}

Simultaneously, you can stack multiple protections on the same method.

[ControlFlow()]
[Virtualization()]
public static void MyImportantMethod()
{
// Your code goes in here
}

Suppose there is a class that you want to protect more than others. You can do this by using the proper protection attributes.

[Virtualization()]
public class MyClass {
// Class code
}

Simultaneously, you can stack multiple protections on the class.

[ControlFlow()]
[Virtualization()]
public class MyClass {
// Class code
}

Last updated