1
Answer

NetReactor Obfuscator

Hello

I'm using NetReactor to obfuscate a C# Project ( Windows Service )

There's a method that I don't want to obfuscate 

I' m using Declarative Protection a feature of NetReactor that allow me to use Obfuscate Attribute to exclude some parte of the code

This is What I'm doing 

using System.Reflection;

public class MyClass
{
    // Exclude this method from obfuscation
    [Obfuscation(Feature = "renaming", Exclude = true)]
    public void ProblematicMethod()
    {
        // Method implementation
    }
}

I tried diferents ways but dosen't work

[ObfuscationAttribute(Exclude=true, Feature="default",StripAfterObfuscation=false)]

[ObfuscationAttribute(Exclude=true, Feature="obfuscation",StripAfterObfuscation=false)]

[ObfuscationAttribute()]

I don't know What I'm doing wrong

Anyone know What could be mistake.

Thanks 

Answers (1)
0
Sangeetha S

Sangeetha S

261 7.3k 315.4k 1w

Ensure Declarative Protection is Enabled: Make sure that your assembly has the declarative protection feature enabled. You can do this by adding the following attribute at the assembly level:

[assembly: Obfuscation(Feature = "DECLARATIVEPROTECTION", Exclude = false)]