mkaring / ConfuserEx

An open-source, free protector for .NET applications
https://mkaring.github.io/ConfuserEx/
MIT License
2.31k stars 353 forks source link

Feature Idea: Overloading for renamer #230

Open ElektroKill opened 3 years ago

ElektroKill commented 3 years ago

Hello, I suggest adding a signature overloading renaming option. I have seen numerous other obfuscators do this and having ConfuserEx do this would be very cool.

An example: If there are two methods: TestMethod(string text) and Tester(). Currently, they would get different names. With overloading, the methods would be renamed to for example a(string text) and a().

In my opinion, this would help increase the obscurity of the code.

KvanTTT commented 3 years ago

The opposite feature is also cool: rename overloaded methods to different names. For the following code:

public class Program {
    public int OverloadMethod(int param) => param;
    public string OverloadMethod(string param) => param;
}

Renamed methods would be different.

Moreover, it makes sense to make this feature included.

KvanTTT commented 3 years ago

I've decided to extract my idea to the separated issue: #293

KvanTTT commented 3 years ago

If this feature is used it will be not possible to correctly deobfuscate exception stack traces because of identifiers ambiguity.