Question

I am trying to use the retrace tool that comes with dexguard to debug an exception in obfuscated code. The obfuscated identifiers use non-ASCII characters, at least that is what it looks like in the mapping file that is produced, for example:

boolean areEqual(char[],char[]) -> ËŠ

This is causing me problems when I try to export the stack trace from the device in order to feed it into retrace. Is something wrong with my obfuscation settings, or is it normal for dexguard to use non-ASCII characters? If so, how should I export the stack trace from the device to preserve them?

Edit: I have since discovered a workaround in the form of adb logcat -B which outputs the log in binary. This results in a log file that is a little hard to read but that does have the correct non-ASCII characters in the stack trace. The original question about dexguard remains though.

Was it helpful?

Solution

DexGuard may indeed obfuscate with non-ASCII UTF-8 characters, depending on the obfuscation library. Its ReTrace tool can handle them fine, but you need to make sure that your environment doesn't mangle the stack traces when you copy them around: console, text editor, windowing system, etc.

OTHER TIPS

When you create the trace file for the retrace tool, ensure to encode the contents in UTF-8 format. For example, you can control the encoding in notepad++ using the menu option - Encoding

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top