MrDEV
MrDEV

Reputation: 3760

How to obfuscate a class which is referenced in Manifest file using Dexguard?

I am using Dexguard in my app and I want to obfuscate a class which extends Activity class, I get to know that it is hard because it is referenced in Manifest file. My question is: is there any way to obfuscate a class which it is referenced in Manifest file?

Upvotes: 3

Views: 2203

Answers (3)

Dexguard will not obfuscate a activity class if in manifest it have intent filter and exported true. if you want to obfuscate class use make your class exported false.

Upvotes: 0

TinyButMighty
TinyButMighty

Reputation: 1

You can obfuscate a class which is referenced in Manifest file by using this tool: Bg+ Anti Decompiler (JAVA) It's free to use.

Upvotes: 0

Eric Lafortune
Eric Lafortune

Reputation: 45676

Wherever possible, DexGuard obfuscates the names of classes, fields, methods, resources, resource files, asset files, and native libraries, and it adapts their occurrences in the code, the manifest, and other resources. More specifically, DexGuard indeed obfuscates the names of activity classes and updates the manifest accordingly. However, it won't obfuscate the names of activities that are exported, either explicitly (exported="true") or implicitly (with an intent filter). The Android runtime treats these names as public API, e.g. visible to other apps, so they need to be preserved.

Upvotes: 2

Related Questions